Fix TNT script
authorPerttu Ahola <celeron55@gmail.com>
Sat, 26 Nov 2011 10:47:31 +0000 (12:47 +0200)
committerPerttu Ahola <celeron55@gmail.com>
Tue, 29 Nov 2011 17:13:53 +0000 (19:13 +0200)
data/mods/default/init.lua

index b9af94be6fa2e749918f747de1f215775e1ea740..88f457e290a8c16b58665c15038110b77c09894a 100644 (file)
@@ -1195,12 +1195,12 @@ function TNT:on_step(dtime)
        self.blinktimer = self.blinktimer + dtime
        if self.blinktimer > 0.5 then
                self.blinktimer = self.blinktimer - 0.5
-               if blinkstatus then
+               if self.blinkstatus then
                        self.object:settexturemod("")
                else
                        self.object:settexturemod("^[brighten")
                end
-               blinkstatus = not blinkstatus
+               self.blinkstatus = not self.blinkstatus
        end
 end