LuaGears.wiki
changeset 1755 b3ce3b8bc36d
parent 1749 91756d20ce3e
child 1758 eda4a2277089
equal deleted inserted replaced
1754:33355f5010ce 1755:b3ce3b8bc36d
     1 #Summary List of gear-related functions in the Lua API
     1 #Summary List of gear-related functions in the Lua API
     2 
     2 
     3 = Lua API: Gear functions =
     3 = Lua API: Gear functions =
     4 This is a list of all functions in the [LuaAPI Lua API] that are related to gears. Refer to [LuaGuide] for an introduction into gears.
     4 This is a list of all functions in the [LuaAPI Lua API] that are related to gears. Refer to [LuaGuide] for an introduction into gears.
       
     5 
       
     6 <toc depth="3"/>
     5 
     7 
     6 == Functions for creating gears ==
     8 == Functions for creating gears ==
     7 
     9 
     8 === <tt>!AddGear(x, y, gearType, state, dx, dy, timer)</tt> ===
    10 === <tt>!AddGear(x, y, gearType, state, dx, dy, timer)</tt> ===
     9 This creates a new gear at position x,y (measured from top left) of kind `gearType` (see [GearTypes Gear Types]).  Gears are dynamic objects or events in the world that affect the gameplay, including hedgehogs, projectiles, weapons, land objects, active utilities and a few more esoteric things.
    11 This creates a new gear at position x,y (measured from top left) of kind `gearType` (see [GearTypes Gear Types]).  Gears are dynamic objects or events in the world that affect the gameplay, including hedgehogs, projectiles, weapons, land objects, active utilities and a few more esoteric things.
   621 -- This makes AI hogs stop caring about attacking uselessHog</code>
   623 -- This makes AI hogs stop caring about attacking uselessHog</code>
   622 
   624 
   623 === <tt>!SetGearPos(gearUid, value)</tt> ===
   625 === <tt>!SetGearPos(gearUid, value)</tt> ===
   624 Sets the `Pos` value (not the position!) of the specified gear to specified value. See `GetGearPos` for more information.
   626 Sets the `Pos` value (not the position!) of the specified gear to specified value. See `GetGearPos` for more information.
   625 
   627 
   626