Highlighting this fairly generic bit of code, which runs a function on every tile of the map:
on SomeEvent do
x = 0
y = 0
function = "SomeFunction"
call "MapTraversal"
end
on MapTraversal do
call function
x += 1
if x==25 then
x = 0
y += 1
end
if y!=15 then
call "MapTraversal"
end
end
Fun trying to figure out how to get by without for loops. Interested if anyone comes up with a different/better way.
This is great. I'm just jumping back into messing with Pulp since units are starting to ship. Let me tell you, my way of trying to do this was waaaaaay more complicated. I was brute forcing this with nested loops . Getting my head around these globally scoped variables has been so tricky. Very different way of coding than I'm used to.
I also love how you used the frames to help track state! Much easier I think than having four separate tiles ("alive", "dead", "willDie", "willRevive").