Read-only variables list
Bots can access some read-only variables for retrieving information on their state, the environnement, etc ..
These variables are used like standard variables, except that you can't change their value (If you try, you'll get a runtime error and a cycles penalty - see processor description)
For example : mov eax, bPosX copy in eax the current X position of the bot
bXxxx refered to bot states, rXxxxx to simulation rules, mXxxxx to map infos.
Variable | Values | Unit | Description |
bId | [0..N] | Bot Id within its team | |
bDamage | [0..100] | % | Current bot damage |
bPosX | [0..1000] | m | Current bot X position |
bPosY | [0..1000] | m | Current bot Y position |
bRealSpeed | [0..100] | m/s | Current bot speed |
bWantedSpeed | [0..100] | m/s | Requested bot speed May be different from bRealSpeed |
bRealDirection | [0..360[ | degree | Current bot direction |
bWantedDirection | [0..360[ | degree | Requested bot direction May be different from bRealDirection |
bTime | [0..X] | ms | Bot living time It's the time elasped since the match started |
bFireTime | [0..X] | ms | Last time the bot fired |
bFireDirection | [0..360[ | degree | Last fire direction |
bFireRange | [0..700] | m | Last fire range |
bTileX | [0..31] | Current X position in the map coordinate | |
bTileY | [0..31] | Current Y position in the map coordinate | |
bTile | [0..3] | Current ground under the bot. See mXXXXXTile | |
rArenaMinX | 0 | m | Arena min X |
rArenaMaxX | 1000 | m | Arena max X |
rArenaMinY | 0 | m | Arena min Y |
rArenaMaxY | 1000 | m | Arena min X |
rBotMinSpeed | 0 | m/s | Min bot speed |
rBotMaxSpeed | 50 | m/s | Max bot speed |
rBotSpeedAccel | 10 | m/s² | Bot acceleration Bot accelerates or deccelerates at 10m/s² until wanted speed is reached |
rBotDirSpeedMinCoef | the turning peed is given by (deg/s) = (rBotDirSpeedMaxCoef / ( bRealSpeed + rBotDirSpeedMinCoef ) ) | ||
rBotDirSpeedMaxCoef | the turning peed is given by (deg/s) = (rBotDirSpeedMaxCoef / ( bRealSpeed + rBotDirSpeedMinCoef ) ) | ||
rMissileReloadTime | 1000 | ms | Bot reload time Bot can't fire again if reload time isn't elapsed |
rMissileSpeed | 300 | m/s | Missile speed |
rMissileMinRange | 0 | m | Min range for firing missile |
rMissileMaxRange | 700 | m | Max range for firing missile |
rMissileRadius1 | 5 | m | First damage radius when a missile explode |
rMissileDamage1 | 10 | % | First damage when a missile explode |
rMissileRadius2 | 20 | m | Second damage radius when a missile explode |
rMissileDamage2 | 5 | % | Second damage when a missile explode |
rMissileRadius3 | 40 | m | Third damage radius when a missile explode |
rMissileDamage3 | 3 | % | Third damage when a missile explode |
rWallDamageCoef | 0.1 | Damage taken by a bot when hitting a wall is given by the formula : bRealSpeed x rWallDamageCoef | |
rBotMaxDamage | 100 | % | Max damage taken by a bot, if damage is upper then the bot die |
rScanMaxRange | 900 | m | Max range of the scanner Bots beyond max range are not detected |
rScanMaxPrecision | 20 | degree | Max precision of the scanner |
rMatchTimeLimit | 300000 | ms | Time limit of matches |
mGroundTile | 0 | Tile representing a simple ground | |
mWaterTile | 1 | Tile representing water | |
mHoleTile | 2 | Tile representing a hole | |
mWallTile | 3 | Tile representing a wall | |
mTileX | 32 | m | X size of a tile |
mTileY | 32 | m | Y Size of the tile |
mNbX | 32 | Nb tiles composing the map | mNbY | 32 | Nb tiles composing the map | mData | Array | Array of mNbX * mNbY values containing the map. Acces to X,Y coordinate with mData[var] where var = X + Y*mNbX |