Not sure, but one thing you can move down a bit in the tight map loop is the array lookup in @capas. You don't have to do that if the coordinates are off-screen. If the map is really the problem then you might want to calculate the correct start indices for x and y so you don't have to loop all over the invisible tiles :)
That's assuming the map is really the problem, I haven't used a profiler on it. It was fun shooting the zombies anyway, good luck in the contest :)
-Title -Game Over -Music (temporal maybe O.o) -Some bugs fixed. -------------------------------------------------------- new version :D -Fixed the lag of the maps Was fault of the map drawing, bigger maps = bigger loop = more lag so i restringed the loop to the tiles in the screen.
Lag can appear with a lot of zombies in screen or a lot of bullets. Suggestions for the game are welcome ;D
from ./Tilemap.rb:67:in load_map' from ./Tilemap.rb:13:in initialize' from ./Map.rb:25:in new' from ./Map.rb:25:in initialize' from ./Title.rb:38:in new' from ./Title.rb:38:in update' from ./Window.rb:32:in update' from Main.rb:29:in `show' from Main.rb:29
I downloaded the win build and I have a small bug I could show you. Here's how you reproduce it: - press enter when the screen appears - let the zombies kill you - press enter again like you would start a new game
I get an error that it cannot resolve the Zlib module when you try to call methods from it. I am not sure if it's just some require that's missing? I can do "require 'zlib'" to get access to the Zlib module. I will retry it with that manually fixed :)