Cy Gerber, Cyber Burglar postmortem
Apparently I forgot to write a post-mortem for this one at the time, so I’m backfilling this from memory. Another action game, but without any of the goofy gimmicks of the previous couple. It uses the collision detection stuff I learned in making Nebula Jalopy, and I think it does so in an extremely inefficient way, which makes its performance really bad on certain browser/OS combinations. I need to learn how to use the Javascript profiler in Chrome. I’m certain I could make the code more efficient, I just don’t know which code is the actual problem.
EDIT: Chris Moyer taught me some basic stuff about the profiler, and I learned that the performance problems were not collision related, but more or less entirely due to drawing the walls every frame. This is apparently mostly due to having shadow blur applied to them, which is also the thing that makes them look hella cool. This is way worse on other peoples’ computers than it is on mine -- probably a video card issue. I might revisit this and try to figure out a way to make it work better, but it’s gonna be tricky if I can’t actually get it to perform badly. Maybe my old laptop.
EDIT EDIT: I patched it, and now it performs way better.
The jam theme was “Stealth.” I liked the idea of spotlights as enemies for scope and laziness reasons, because they don’t have to be constrained by walls, and they don’t really need to consist of anything other than a shape. If you get caught by one, it starts a sweep of red static that wipes out the screen, and you have to escape before it catches up with you. This is stolen from a part of Tron 2.0 I really liked, where you were in a system that was being formatted, and the deletion of your environment was presented as a red wall that ate the level.
I’m pleased with the way the procedural level generation turned out. I tried a slightly different approach than I usually use -- instead of an algorithm that guarantees a traversable level, this one makes a much more random level and then checks whether or not it’s traversable. If it finds that the exit is blocked, it tries again. It also ensures that the levels have a certain amount of space blocked off. Putting all the treasures in those inaccessible spaces serves the whole key/wall destruction mechanic.
Incidentally, walls are destroyed with keys instead of bombs because the jam’s last-minute limitation was “no violence,” and I wasn’t sure if bombs counted as violence or not.
I found this one pretty fun to play. Again, I think the combination of a score chase and procedural scenarios is what made the difference there. It’s probably too easy for younger people with better reflexes, but I found that it was tuned well for me. It felt challenging but not impossible to get the maximum score on a run.
Cy Gerber, Cyber Burglar
Cy hacks the mainframe and burgles its treasure. Made for MiniJam #55.
Status | Released |
Author | ZapJackson |
Genre | Action |
More posts
- Performance patchJun 30, 2020