LuaAPI.wiki
changeset 21 e8bcd7c1ba3c
parent 17 2893bd461cc7
child 22 af151755fd72
equal deleted inserted replaced
20:0cd14659de00 21:e8bcd7c1ba3c
     4 
     4 
     5 <blockquote><tt>LAND_WIDTH</tt>, <tt>LAND_HEIGHT</tt>
     5 <blockquote><tt>LAND_WIDTH</tt>, <tt>LAND_HEIGHT</tt>
     6 </blockquote>
     6 </blockquote>
     7 Game flags:
     7 Game flags:
     8 
     8 
     9 <blockquote><tt>gfForts, gfMultiWeapon, gfSolidLand, gfDivideTeams, gfLowGravity, gfLaserSight, gfInvulnerable, gfMines, gfVampiric, gfKarma, gfArtillery, gfOneClanMode, gfRandomOrder, gfKing, gfPlaceHog, gfSharedAmmo, gfDisableGirders, gfExplosives, gfDisableLandObjects, gfAISurvival</tt>
     9 <blockquote><tt>gfForts, gfMultiWeapon, gfSolidLand, gfDivideTeams, gfLowGravity, gfLaserSight, gfInvulnerable, gfMines, gfVampiric, gfKarma, gfArtillery, gfOneClanMode, gfRandomOrder, gfKing, gfPlaceHog, gfSharedAmmo, gfDisableGirders, gfExplosives, gfDisableLandObjects, gfAISurvival, gfInfAttack, gfResetWeps, gfPerHogAmmo, gfDisableWind</tt></blockquote>
    10 </blockquote>
       
    11 More constants at [GearTypes Gear Types] , [AmmoTypes Ammo Types], [Sounds], [States]
    10 More constants at [GearTypes Gear Types] , [AmmoTypes Ammo Types], [Sounds], [States]
    12 
    11 
    13 Additional global changing variables accessible:
    12 Additional global changing variables accessible:
    14 
    13 
    15  * <tt>!TurnTimeLeft</tt> - number of game ticks left until the current turn ends
    14  * <tt>!TurnTimeLeft</tt> - number of game ticks left until the current turn ends
    23 </blockquote>
    22 </blockquote>
    24  * <tt>Seed = 0</tt> - sets the seed of the random number generator
    23  * <tt>Seed = 0</tt> - sets the seed of the random number generator
    25  * <tt>!GameFlags = gfSolidLand + gfArtillery + …</tt> - sets the gameflags, see above for the available flags
    24  * <tt>!GameFlags = gfSolidLand + gfArtillery + …</tt> - sets the gameflags, see above for the available flags
    26  * <tt>!TurnTime = 60000</tt> - set the turntime in ms
    25  * <tt>!TurnTime = 60000</tt> - set the turntime in ms
    27  * <tt>!CaseFreq = 0</tt> - frequency of crate drops
    26  * <tt>!CaseFreq = 0</tt> - frequency of crate drops
    28  * <tt>!LandAdds = 0</tt> - number of mines being placed
    27  * <tt>HealthCaseProb = 35</tt> - chance of receiving a health crate
       
    28  * <tt>HealthCaseAmount = 25</tt> - amount of health in a health crate
       
    29  * <tt>!DamagePercent = 100</tt> - percent of damage to inforce
       
    30  * <tt>!MinesNum = 0</tt> - number of mines being placed (before 0.9.14 LandAdds)
       
    31  * <tt>!MinesTime = 3</tt> - time for a mine to explode from activated, -1 for random
       
    32  * <tt>!MineDudPercent = 0</tt> - chance of mine being a dud
    29  * <tt>Explosives = 0</tt> - number of explosives being placed
    33  * <tt>Explosives = 0</tt> - number of explosives being placed
    30  * <tt>Delay = 0</tt> - delay between each round
    34  * <tt>Delay = 0</tt> - delay between each round
    31  * <tt>!SuddenDeathTurns = 30</tt> - turns until sudden death begins
    35  * <tt>!SuddenDeathTurns = 30</tt> - turns until sudden death begins
       
    36  * <tt>WaterRise = 47</tt> - height of water rise at sudden death in pixels
       
    37  * <tt>HealthDecrease = 5</tt> - amount of health decreased on sudden death
    32  * <tt>Map = "Bamboo"</tt> - the map being played
    38  * <tt>Map = "Bamboo"</tt> - the map being played
    33  * <tt>Theme = "Bamboo"</tt> - the theme to be used
    39  * <tt>Theme = "Bamboo"</tt> - the theme to be used
    34 
    40 
    35 If you want to add teams or hogs manually you have to do it here.
    41 If you want to add teams or hogs manually you have to do it here.
    36 
    42