AliYousuf / hedgewars

Automatically exported from code.google.com/p/hedgewars
GNU General Public License v2.0
0 stars 0 forks source link

Construction Mode: Time-travelling while having filters on map breaks script #858

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Start a game using the script “Construction Mode”
2. Build a Support Station
3. Buy a TimeBox (Called “Tardis” in script)
4. Use the TimeBox
5. Build a filter (either weapon filter or hog filter, doesn’t matter)

What is the expected output? What do you see instead?
I expect my hog to travel in time without error.

Actually: The hog starts to travel in time. As soon as you have a hog 
travelling in time (is gone) AND have a filter anywhere on the map in place, 
the screen and console gets spammed with the following message:

LUA ERROR: Error while calling onGameTick: [string 
"//Scripts/Multiplayer/Construction_Mode.lua"]:1171: attempt to perform 
arithmetic on global 'g1X' (a nil value)

What version of the product are you using? On what operating system?
Mercurial 5ae7ba0b2849 (aka beta for 0.9.21) on GNU/Linux.

Please provide any additional information below.
The bug does not seem to happen if you time-travel without any filter on the 
map or if you have a filter on the map without a time-travelling hog.

Original issue reported on code.google.com by almikes@aol.com on 11 Dec 2014 at 8:53

GoogleCodeExporter commented 8 years ago

Original comment by sheepyluva on 13 Dec 2014 at 9:29

GoogleCodeExporter commented 8 years ago
I haven't had time to look at this in detail yet, but I issued a very lazy fix 
in 2f19ff0ded73 by just removing Tardis :D Even if I fix bug origin, I think I 
will keep Tardis removed because it just clutters up the menu and it allows 
hogs to spawn in areas outside of their base which is not really intended. I've 
also removed resurrector because it's function should be handled by the 
Respawner structure. (Same reason you already can't buy teleport crates). 
Hopefully these removals will make the menu less cluttered overall and prevent 
any major issues. 

Original comment by RedGrin...@gmail.com on 15 Dec 2014 at 3:33