# HG changeset patch # User RedGrinner # Date 1291646116 0 # Node ID 3c5d26c1562a48c5e0975d943bc81754ddd2d744 # Parent adf440f87f1e4dd5772225e29731d701ef2523f6 Edited wiki page LuaAPI through web user interface. diff -r adf440f87f1e -r 3c5d26c1562a LuaAPI.wiki --- a/LuaAPI.wiki Mon Dec 06 14:20:34 2010 +0000 +++ b/LuaAPI.wiki Mon Dec 06 14:35:16 2010 +0000 @@ -249,17 +249,18 @@
Sets the health of the specified gear.
-=== !SetEffect(gearUid, effect, true/false) (0.9.14) === +=== !SetEffect(gearUid, effect, true/false) (0.9.14 / dev) ===
Enables (true) or disables (false) one of the effects heInvulnerable, heResurrectable, hePoisoned for the specified hedgehog gear.
Example: (sets all bots poisoned) function onGearAdd(gear) - if (!GetGearType(gear) === gtHedgehog) and (!GetBotLevel(gear) > 0) then + if (!GetGearType(gear) == gtHedgehog) and (!GetBotLevel(gear) > 0) then !SetEffect(gear, hePoisoned, true) end end +Notice: In 0.9.14 this function takes 0 or 1 instead of true/false. === CopyPV(gearUid, gearUid) ===
This sets the position and velocity of the second gear to the first one.