- Check if there was a wall collision last frame. (which would only occur if the enemy was actually drawn!) If so, reset to the "last drawn" position.
- If no collision and enemy shown, copy the current position to the "last" position
- Move the enemy
- Determine which enemies will be shown this frame. If shown, copy "last" position to "last shown" position
- Clear the collision flags
- Redraw (and capture changes to the collision flags)
I also started back into level design, which is always a nice diversion when I'm stuck. The past couple of rooms felt a little uninspired, but I'm almost to the point where I can expect the player to have a large set up powerups, so I can start designing new sorts of challenges that require quickly switching between powers. That should be fun.