LuaGears.wiki
changeset 1831 365c30b4c669
parent 1825 1d2aeacbdd8e
child 1832 d975c5b3bc4c
equal deleted inserted replaced
1830:e562fccced8e 1831:365c30b4c669
     9 
     9 
    10 <wiki:toc max_depth="3"/>
    10 <wiki:toc max_depth="3"/>
    11 
    11 
    12 == Creation ==
    12 == Creation ==
    13 
    13 
    14 === `AddGear(x, y, gearType, state, dx, dy, timer)` ===
    14 === `AddXGear(x, y, gearType, state, dx, dy, timer)` ===
    15 This creates a new gear at position x,y (measured from top left) of kind `gearType` (see [GearTypes Gear Types]).
    15 This creates a new gear at position x,y (measured from top left) of kind `gearType` (see [GearTypes Gear Types]).
    16 The initial velocities are `dx` and `dy`. All arguments are numbers. The function returns the `uid` of the gear created. Gears can have multple states at once: `state` is a bitmask, the flag variables can be found in [States]. `timer` is the initial timer value of the gear. If a particular gear value does not matter, use `0`.
    16 The initial velocities are `dx` and `dy`. All arguments are numbers. The function returns the `uid` of the gear created. Gears can have multple states at once: `state` is a bitmask, the flag variables can be found in [States]. `timer` is the initial timer value of the gear. If a particular gear value does not matter, use `0`.
    17 
    17 
    18 Position, velocity, state and timer can be changed afterwards with the various setter functions.
    18 Position, velocity, state and timer can be changed afterwards with the various setter functions.
    19 
    19