hedgewars/uScript.pas
changeset 4411 79fbc444584c
parent 4403 0dfe26f48ec1
child 4443 d393b9ccd328
--- a/hedgewars/uScript.pas	Mon Nov 22 00:34:53 2010 +0100
+++ b/hedgewars/uScript.pas	Mon Nov 22 10:04:08 2010 +0100
@@ -574,7 +574,7 @@
     else begin
         gear := GearByUID(lua_tointeger(L, 1));
         if gear <> nil then
-            gear^.Hedgehog^.Effects[THogEffect(lua_tointeger(L, 2))]:= lua_tointeger(L, 3) <> 0;
+            gear^.Hedgehog^.Effects[THogEffect(lua_tointeger(L, 2))]:= lua_toboolean(L, 3);
     end;
     lc_seteffect := 0;
 end;