Sysvar

From WikiManual
Revision as of 04:54, 30 January 2006 by Ollj (talk | contribs)
Jump to: navigation, search

System variables you're likely to see in Robot DNA:

Sysvars

Movement:

.aimsx 6 .aimdx 5
.up 1
.sx 3 Veggietransparent.gif .dx 4
.dn 2
.aim 18 .setaim 19
.maxvel 11
.setboy 314 .rdboy 315

Forwards compatibility note:

aimdx is the old name for aimright

aimsx is the old name for aimleft

Shooting:

.shoot 7 .shootval 8
.kills 220
.backshot 900 .aimshoot 901
  • robage/9 - returns how many cycles old a bot is, with a maximum value of 32000
  • mass/10 - returns how massive a bot is. Mass is primarily based on body levels
  • maxvel/11
  • velscalar/196
  • velsx/197
  • veldx/198
  • veldn/199
  • velup/200
  • vel/200

Gains & Losses:

.bodgain 194 .bodloss 195
.pain 203 .pleas 204

Template:Hit

Shot:

.shflav 202
.shang 209 .shup 210
.shsx 213 Veggietransparent.gif .shdx 212
.shdn 211


  • .edge 214 set to 1 if the bot has hit the edge of the screen.
  • fixed/215 - A value of 0 means the robot can move freely. A value of 1 means it is fixed in place (like a blocked alga)
  • fixpos/216 - Set this to any non-zero number to anchor your bot in place. Set it to zero to allow your bot to move freely.
  • xpos/219 - Reads back a bot's horizontal position with the left side representing zero
  • ypos/217 - Reads back a bot's vertical position with the top representing zero. ypos shares the same memloc as depth. These are completely interchangable.
  • depth/217 - Reads back a bot's vertical position with the top representing zero. ypos shares the same memloc as depth. These are completely interchangable.
  • daytime/218 - Why have a day / night cycle if the robots can't tell when they change. Reads back 1 for day and 0 for night.
  • kills/220 - Returns the number of bots your bot has killed.

Reproducing:

.robage 9
.mass 10
.timer 12
.repro 300
.mrepro 301
.sexrepro 302
.fertilized 303

Energy, Body, and Waste

  • Body
    • body/311
    • fdbody/312
    • strbody/313
  • setboy/314 - Allows a bot to set it's buoyancy to a specified level
  • rdboy/315 - Returns a bot's buoyancy level
  • Waste
    • waste/828
    • pwaste/829


Viruses:

.mkvirus 335 .thisgene 341
.dnalen 336
.vtimer 337 .vshoot 338
.genes 339
.delgene 340

Ties

  • Ties
    • tie/330
    • numties/466
    • tiepres/454
    • tienum/455
    • readtie/471
    • deltie/467
    • tieloc/452
    • tieval/453
    • tieang/450
    • tielen/451
    • multi/470
    • fixang/468
    • fixlen/469
    • stifftie/331

Sharing

  • MB Sharing
    • sharenrg/830
    • sharewaste/831
    • shareshell/832
    • shareslime/833

Tieports1-4

Tieports1-4

  • tieang1/480 , tieang2/481 , tieang3/482 , tieang4/483
  • tielen1/484 , tielen2/485 , tielen3/486 , tielen4/487

Defense

Defense

  • mkslime/820
  • slime/821
  • mkshell/822
  • shell/823
  • strvenom/824
  • venom/825
  • strpoison/826
  • poison/827
  • ploc/834
  • vloc/835
  • venval/836
  • poisoned/838

Eyes

  • Eyes
    • eye1/501 , eye2/502 , eye3/503 , eye4/504 , eye5/505 , eye6/506 , eye7/507 , eye8/508 , eye9/509

In and Out

  • In and Out
    • out1/800 , out2/801 , out3/802 , out4/803 , out5/804
    • in1/810 , in2/811 , in3/812 , in4/813 , in5/814

Memloc and Memval

RefVars

  • RefVars
    • refmulti/686
    • refshell/687
    • refbody/688
    • refxpos/689
    • refypos/690
    • refvelscalar/695
    • refvelsx/696
    • refveldx/697
    • refveldn/698
    • refvel/699
    • refvelup/699
    • refnrg/709
    • refage/710
    • refaim/711
    • refpoison/713
    • refvenom/714
    • refkills/715
    • reffixed/477
    • refup/701
    • refdn/702
    • refsx/703
    • refdx/704
    • refaimdx/705
    • refaimsx/706
    • refshoot/707
    • refeye/708
    • reftie/712

MyVars

  • MyVars
    • myup/721
    • mydn/722
    • mysx/723
    • mydx/724
    • myaimdx/725
    • myaimsx/726
    • myshoot/727
    • myeye/728
    • myties/729
    • mypoison/730
    • myvenom/731

TrefVars

  • TrefVars
    • trefbody/437
    • trefxpos/438
    • trefypos/439
    • trefvelmysx/440 , trefvelmydx/441 , trefvelmydn/442 , trefvelmyup/443
    • trefvelscalar/444
    • trefvelyoursx/445 , trefvelyourdx/446 , trefvelyourdn/447 , trefvelyourup/448
    • trefshell/449
    • trefup/456 , trefdn/457 , trefsx/458 , trefdx/459
    • trefaimdx/460 , trefaimsx/461
    • trefshoot/462
    • trefeye/463
    • trefnrg/464
    • trefage/465
    • treffixed/478
    • trefbody/472
    • trefaim/479

Algorithms are listed as Operators.