KaosLib.k

  • by Netdroid9
  • little changes by august0815
  • comment august0815
Summary
KaosLib.k
Functions
selectCameraSCAM cam , part
selectMainCameraSCAM
moveCameraCMRA
moveCamera
moveCameraCenterCMRP x,y,pan
moveCamera1
cameraXCMRX
cameraYCMRY
moveCameraToMetaroomMETA moveCameraToMetaroom
cameraBackgroundBKGD
cameraBackgroundBKGD returning
takeSnapshotSNAP
snapshotExistsSNAX
killSnapshotSNAX
clickActionsCLAC
clickActionsCLAC
mouseXMOPX
mouseYMOPY
mouseXVelocityMOVX
mouseYVelocityMOVY
Constants
IMSK_RAWKEYDOWN
IMSK_RAWKEYUP
IMSK_RAWMOUSEMOVE
IMSK_RAWMOUSEDOWN
IMSK_RAWMOUSEUP
IMSK_RAWMOUSEWHEEL
IMSK_RAWTRANSLATEDCHAR
Functions
isKeyDownKEYD
accelerationACCG returning
angularDampingADMP returning
aerodynamicsAERO returning
angularVelocityAVEL returning
elasticityELAS returning
isFallingFALL
forwardDampingFDMP returning
frictionFRIC returning
forwardVelocityFEVL returning
movementStatusMOVS
sideDampingSDMP returning
sideVelocitySVEL returning
velocityVELO
XVelocityVELX
YVelocityVELY
Constants
JECT_REMOVESCRIPT
JECT_EVENTSCRIPTS
JECT_INSTALLSCRIPT
JECT_ALLSCRIPTS
Functions
injectScriptJECT
injectScript
waitWAIT
callEventCALL
saySEZZ
VoiceVOIS
setVoiceToCreatureVoiceVOIC
playSoundSNDE
playSoundWithDelaySNQ
playControlledSoundSNDC
playLoopedControlledSoundSNDL
fadeControlledSoundFADE
stopControlledSoundSTPC
setVolumeVOLM
getVolumeVOLM returning
getAbsoluteABSV returning
getArccosACOS returning
getArcsinASIN returning
getArctanATAN returning
getCosineCOS_ returning
getSineSIN_ returning
getTangentTAN_ returning
floatToIntFTOI returning
IntToFloatITOF returning
StrToFloatSTOF returning
StrToIntSTOI returning
NumToStrVTOS returning
getInverseNEGV returning
getRandomRAND
getCharCHAR returning
setCharCAHR
toUpperUPPA returning
toLowerLOWA returning
findSubstringSINS returning
getSubstringSUBS returning
getSystemInfoUFOS returning
getMajorVersionVMJR returning
getMinorVersionVMNR returning
loadWorldLOAD
saveWorldSAVE
quitINST SAVE QUIT
createWorldWRLD
deleteWorldDELW
getNumberOfWorldsNWLD returning
getCurrentWorldNameWNAM returning
getWorldIndexWNIT returning
getWorldNameWLRD returning
setNextWorldPasswordPSWD
getPasswordPSWD returning
heldByCARR returning
holdingHELD returning
dropDROP
baseIndexBASE returning
spriteGalleryGALL returning
mirrorMIRA returning
isVisibleVISI
genusGNUS returning
familyFMLY returning
speciesSPC returning
sendMessageMESG WRT+
sendMessage
sendMessage
ageCAGE
ageInTicksTAGE returning
sleepingASLP returning
dreamingDREA returning
unconsciousUNCS returning
hatchBORN
mateMATE
dieDEAD
isDeadDEAD returning
driveLevelDRIV returning
highestDriveDRV! 
bloodConcentrationCHEM returning
canThinkMIND returning
isZombieZMD returning
organDataFloatORGF returning
organDataIntORGI returning
numberOfOrgansORGN returning
injureINJR
isCreatureCREA returning
moveFeetMVFT

Functions

selectCamera

define selectCamera(agent camera,
numeric partNumber)

SCAM cam , part

Camera selection

selectMainCamera

define selectMainCamera()

SCAM

moveCamera

define moveCamera(numeric x,
numeric y,
numeric pan)

CMRA

moveCamera

define moveCamera(numeric x,
numeric y)

moveCameraCenter

define moveCameraCenter(numeric x,
numeric y,
numeric pan)

CMRP x,y,pan

moveCamera1

define moveCamera1(numeric x,
numeric y)

cameraX

define cameraX()

CMRX

cameraY

define cameraY()

CMRY

moveCameraToMetaroom

define moveCameraToMetaroom(numeric metaroomID,
numeric x,
numeric y,
numeric transition)

META moveCameraToMetaroom

Transition can be

0no transition
1flip horizontally
2burst

cameraBackground

define cameraBackground(numeric metaroomID,
string background,
numeric transition)

BKGD

cameraBackgroundTransition is same as in moveCameraToMetaroom

cameraBackground

define cameraBackground()

BKGD returning

takeSnapshot

define takeSnapshot(string filename,
numeric x,
numeric y,
numeric width,
numeric height,
numeric zoomFactor)

SNAP

takeSnapshotZoom is a percentage, 100 is the normal size

snapshotExists

define snapshotExists(string filename)

SNAX

snapshotExistsReturns 1 if the specified file exists

killSnapshot

define killSnapshot(string filename)

SNAX

killSnapshotReturns 1 if the snapshot is in use in a gallery and therefore fails

clickActions

define clickActions(agent a,
numeric message1,
numeric message2,
numeric message3)

CLAC

clickActions

define clickActions(agent a,
numeric message1,
numeric message2)

CLAC

mouseX

define mouseX()

MOPX

mouseY

define mouseY()

MOPY

mouseXVelocity

define mouseXVelocity()

MOVX

mouseYVelocity

define mouseYVelocity()

MOVY

Constants

IMSK_RAWKEYDOWN

define numeric IMSK_RAWKEYDOWN

IMSK_RAWKEYUP

define numeric IMSK_RAWKEYUP

IMSK_RAWMOUSEMOVE

define numeric IMSK_RAWMOUSEMOVE

IMSK_RAWMOUSEDOWN

define numeric IMSK_RAWMOUSEDOWN

IMSK_RAWMOUSEUP

define numeric IMSK_RAWMOUSEUP

IMSK_RAWMOUSEWHEEL

define numeric IMSK_RAWMOUSEWHEEL

IMSK_RAWTRANSLATEDCHAR

define numeric IMSK_RAWTRANSLATEDCHAR

Functions

isKeyDown

define isKeyDown(numeric KEYCODE)

KEYD

acceleration

define acceleration(agent a)

ACCG returning

angularDamping

define angularDamping(agent a)

ADMP returning

aerodynamics

define aerodynamics(agent a)

AERO returning

angularVelocity

define angularVelocity(agent a)

AVEL returning

elasticity

define elasticity(agent a)

ELAS returning

isFalling

define isFalling(agent a)

FALL

forwardDamping

define forwardDamping(agent a)

FDMP returning

friction

define friction(agent a)

FRIC returning

forwardVelocity

define forwardVelocity(agent a)

FEVL returning

movementStatus

define movementStatus(agent a)

MOVS

sideDamping

define sideDamping(agent a)

SDMP returning

sideVelocity

define sideVelocity(agent a)

SVEL returning

velocity

define velocity(agent a,
numeric x,
numeric y)

VELO

XVelocity

define XVelocity(agent a)

VELX

YVelocity

define YVelocity(agent a)

VELY

Constants

JECT_REMOVESCRIPT

define numeric JECT_REMOVESCRIPT

JECT_EVENTSCRIPTS

define numeric JECT_EVENTSCRIPTS

JECT_INSTALLSCRIPT

define numeric JECT_INSTALLSCRIPT

JECT_ALLSCRIPTS

define numeric JECT_ALLSCRIPTS

Functions

injectScript

define injectScript(string cosfile,
numeric flags)

JECT

injectScript

define injectScript(string cosfile)

wait

define wait(numeric ticks)

WAIT

callEvent

define callEvent(numeric eventNumber,
void param1,
void param2)

CALL

say

define say(string text,
agent a)

SEZZ

Voice

define Voice(string voiceName,
agent a)

VOIS

setVoiceToCreatureVoice

define setVoiceToCreatureVoice(agent a,
numeric genus,
numeric gender,
numeric age)

VOIC

playSound

define playSound(string soundFile,
agent a)

SNDE

playSoundWithDelay

define playSoundWithDelay(agent a,
string soundFile,
numeric delay)

SNQ

playControlledSound

define playControlledSound(string soundFile,
agent a)

SNDC

playLoopedControlledSound

define playLoopedControlledSound(string soundFile,
agent a)

SNDL

fadeControlledSound

define fadeControlledSound(agent a)

FADE

stopControlledSound

define stopControlledSound(agent a)

STPC

setVolume

define setVolume(numeric channel,
numeric volume)

VOLM

getVolume

define getVolume(numeric channel)

VOLM returning

getAbsolute

define getAbsolute(numeric number)

ABSV returning

getArccos

define getArccos(numeric number)

ACOS returning

getArcsin

define getArcsin(numeric number)

ASIN returning

getArctan

define getArctan(numeric number)

ATAN returning

getCosine

define getCosine(numeric number)

COS_ returning

getSine

define getSine(numeric number)

SIN_ returning

getTangent

define getTangent(numeric number)

TAN_ returning

floatToInt

define floatToInt(numeric number)

FTOI returning

IntToFloat

define IntToFloat(numeric number)

ITOF returning

StrToFloat

define StrToFloat(string number)

STOF returning

StrToInt

define StrToInt(string number)

STOI returning

NumToStr

define NumToStr(numeric number)

VTOS returning

getInverse

define getInverse(numeric number)

NEGV returning

getRandom

define getRandom(numeric startValue,
numeric endValue)

RAND

getChar

define getChar(string inputString,
numeric index)

CHAR returning

setChar

define setChar(string inputString,
numeric index,
numeric character)

CAHR

toUpper

define toUpper(string input)

UPPA returning

toLower

define toLower(string input)

LOWA returning

findSubstring

define findSubstring(string input,
numeric index,
string search)

SINS returning

getSubstring

define getSubstring(string value,
numeric start,
numeric count)

SUBS returning

getSystemInfo

define getSystemInfo()

UFOS returning

getMajorVersion

define getMajorVersion()

VMJR returning

getMinorVersion

define getMinorVersion()

VMNR returning

loadWorld

define loadWorld(string worldname)

LOAD

saveWorld

define saveWorld(string worldname)

SAVE

quit

define quit(string worldname)

INST SAVE QUIT

createWorld

define createWorld(string worldname)

WRLD

deleteWorld

define deleteWorld(string worldname)

DELW

getNumberOfWorlds

define getNumberOfWorlds()

NWLD returning

getCurrentWorldName

define getCurrentWorldName()

WNAM returning

getWorldIndex

define getWorldIndex(string worldName)

WNIT returning

getWorldName

define getWorldName(numeric worldIndex)

WLRD returning

setNextWorldPassword

define setNextWorldPassword(string password)

PSWD

getPassword

define getPassword(string worldName)

PSWD returning

heldBy

define heldBy(agent a)

CARR returning

holding

define holding(agent a)

HELD returning

drop

define drop(agent a)

DROP

baseIndex

define baseIndex(agent a)

BASE returning

spriteGallery

define spriteGallery(agent a)

GALL returning

mirror

define mirror(agent a)

MIRA returning

isVisible

define isVisible(numeric checkAllCameras,
agent a)

VISI

genus

define genus(agent a)

GNUS returning

family

define family(agent a)

FMLY returning

species

define species(agent a)

SPC returning

sendMessage

define sendMessage(agent a,
numeric messageID,
void param1,
void param2,
numeric delay)

MESG WRT+

sendMessage

define sendMessage(agent a,
numeric messageID,
void param1,
void param2)

sendMessage

define sendMessage(agent a,
numeric messageID)

age

define age(agent a)

CAGE

ageInTicks

define ageInTicks(agent a)

TAGE returning

sleeping

define sleeping(agent a)

ASLP returning

dreaming

define dreaming(agent a)

DREA returning

unconscious

define unconscious(agent a)

UNCS returning

hatch

define hatch(agent a)

BORN

mate

define mate(agent a)

MATE

die

define die(agent a)

DEAD

isDead

define isDead(agent a)

DEAD returning

driveLevel

define driveLevel(numeric drive,
agent a)

DRIV returning

highestDrive

define highestDrive(agent a)

DRV! returning

bloodConcentration

define bloodConcentration(numeric chemical,
agent a)

CHEM returning

canThink

define canThink(agent a)

MIND returning

isZombie

define isZombie(agent a)

ZMD returning

organDataFloat

define organDataFloat(agent a,
numeric organNumber,
numeric data)

ORGF returning

organDataInt

define organDataInt(agent a,
numeric organNumber,
numeric data)

ORGI returning

numberOfOrgans

define numberOfOrgans(agent a)

ORGN returning

injure

define injure(agent a,
numeric organ,
numeric amount)

INJR

isCreature

define isCreature(agent a)

CREA returning

moveFeet

define moveFeet(agent a,
numeric x,
numeric y)

MVFT

define selectCamera(agent camera,
numeric partNumber)
SCAM cam , part
define selectMainCamera()
SCAM
define moveCamera(numeric x,
numeric y,
numeric pan)
CMRA
define moveCameraCenter(numeric x,
numeric y,
numeric pan)
CMRP x,y,pan
define moveCamera1(numeric x,
numeric y)
define cameraX()
CMRX
define cameraY()
CMRY
define moveCameraToMetaroom(numeric metaroomID,
numeric x,
numeric y,
numeric transition)
META moveCameraToMetaroom
define cameraBackground(numeric metaroomID,
string background,
numeric transition)
BKGD
define takeSnapshot(string filename,
numeric x,
numeric y,
numeric width,
numeric height,
numeric zoomFactor)
SNAP
define snapshotExists(string filename)
SNAX
define killSnapshot(string filename)
SNAX
define clickActions(agent a,
numeric message1,
numeric message2,
numeric message3)
CLAC
define mouseX()
MOPX
define mouseY()
MOPY
define mouseXVelocity()
MOVX
define mouseYVelocity()
MOVY
define numeric IMSK_RAWKEYDOWN
define numeric IMSK_RAWKEYUP
define numeric IMSK_RAWMOUSEMOVE
define numeric IMSK_RAWMOUSEDOWN
define numeric IMSK_RAWMOUSEUP
define numeric IMSK_RAWMOUSEWHEEL
define numeric IMSK_RAWTRANSLATEDCHAR
define isKeyDown(numeric KEYCODE)
KEYD
define acceleration(agent a)
ACCG returning
define angularDamping(agent a)
ADMP returning
define aerodynamics(agent a)
AERO returning
define angularVelocity(agent a)
AVEL returning
define elasticity(agent a)
ELAS returning
define isFalling(agent a)
FALL
define forwardDamping(agent a)
FDMP returning
define friction(agent a)
FRIC returning
define forwardVelocity(agent a)
FEVL returning
define movementStatus(agent a)
MOVS
define sideDamping(agent a)
SDMP returning
define sideVelocity(agent a)
SVEL returning
define velocity(agent a,
numeric x,
numeric y)
VELO
define XVelocity(agent a)
VELX
define YVelocity(agent a)
VELY
define numeric JECT_REMOVESCRIPT
define numeric JECT_EVENTSCRIPTS
define numeric JECT_INSTALLSCRIPT
define numeric JECT_ALLSCRIPTS
define injectScript(string cosfile,
numeric flags)
JECT
define wait(numeric ticks)
WAIT
define callEvent(numeric eventNumber,
void param1,
void param2)
CALL
define say(string text,
agent a)
SEZZ
define Voice(string voiceName,
agent a)
VOIS
define setVoiceToCreatureVoice(agent a,
numeric genus,
numeric gender,
numeric age)
VOIC
define playSound(string soundFile,
agent a)
SNDE
define playSoundWithDelay(agent a,
string soundFile,
numeric delay)
SNQ
define playControlledSound(string soundFile,
agent a)
SNDC
define playLoopedControlledSound(string soundFile,
agent a)
SNDL
define fadeControlledSound(agent a)
FADE
define stopControlledSound(agent a)
STPC
define setVolume(numeric channel,
numeric volume)
VOLM
define getVolume(numeric channel)
VOLM returning
define getAbsolute(numeric number)
ABSV returning
define getArccos(numeric number)
ACOS returning
define getArcsin(numeric number)
ASIN returning
define getArctan(numeric number)
ATAN returning
define getCosine(numeric number)
COS_ returning
define getSine(numeric number)
SIN_ returning
define getTangent(numeric number)
TAN_ returning
define floatToInt(numeric number)
FTOI returning
define IntToFloat(numeric number)
ITOF returning
define StrToFloat(string number)
STOF returning
define StrToInt(string number)
STOI returning
define NumToStr(numeric number)
VTOS returning
define getInverse(numeric number)
NEGV returning
define getRandom(numeric startValue,
numeric endValue)
RAND
define getChar(string inputString,
numeric index)
CHAR returning
define setChar(string inputString,
numeric index,
numeric character)
CAHR
define toUpper(string input)
UPPA returning
define toLower(string input)
LOWA returning
define findSubstring(string input,
numeric index,
string search)
SINS returning
define getSubstring(string value,
numeric start,
numeric count)
SUBS returning
define getSystemInfo()
UFOS returning
define getMajorVersion()
VMJR returning
define getMinorVersion()
VMNR returning
define loadWorld(string worldname)
LOAD
define saveWorld(string worldname)
SAVE
define quit(string worldname)
INST SAVE QUIT
define createWorld(string worldname)
WRLD
define deleteWorld(string worldname)
DELW
define getNumberOfWorlds()
NWLD returning
define getCurrentWorldName()
WNAM returning
define getWorldIndex(string worldName)
WNIT returning
define getWorldName(numeric worldIndex)
WLRD returning
define setNextWorldPassword(string password)
PSWD
define getPassword(string worldName)
PSWD returning
define heldBy(agent a)
CARR returning
define holding(agent a)
HELD returning
define drop(agent a)
DROP
define baseIndex(agent a)
BASE returning
define spriteGallery(agent a)
GALL returning
define mirror(agent a)
MIRA returning
define isVisible(numeric checkAllCameras,
agent a)
VISI
define genus(agent a)
GNUS returning
define family(agent a)
FMLY returning
define species(agent a)
SPC returning
define sendMessage(agent a,
numeric messageID,
void param1,
void param2,
numeric delay)
MESG WRT+
define age(agent a)
CAGE
define ageInTicks(agent a)
TAGE returning
define sleeping(agent a)
ASLP returning
define dreaming(agent a)
DREA returning
define unconscious(agent a)
UNCS returning
define hatch(agent a)
BORN
define mate(agent a)
MATE
define die(agent a)
DEAD
define isDead(agent a)
DEAD returning
define driveLevel(numeric drive,
agent a)
DRIV returning
define highestDrive(agent a)
DRV! 
define bloodConcentration(numeric chemical,
agent a)
CHEM returning
define canThink(agent a)
MIND returning
define isZombie(agent a)
ZMD returning
define organDataFloat(agent a,
numeric organNumber,
numeric data)
ORGF returning
define organDataInt(agent a,
numeric organNumber,
numeric data)
ORGI returning
define numberOfOrgans(agent a)
ORGN returning
define injure(agent a,
numeric organ,
numeric amount)
INJR
define isCreature(agent a)
CREA returning
define moveFeet(agent a,
numeric x,
numeric y)
MVFT
Close