Forcing Interesting Repositioning
My first ever game for a school assignment was a Space Invaders inspired game called Cosmos Intruders. I gave the player 2D movement, but quickly realized that being able to move vertically didn't mean much if all the enemies stayed in front of them.
Hazards
I designed environmental hazards that would appear throughout each round, forcing the player to constantly reconsider where they were standing.
Asteroids, solar rays and supernovas could come from different directions, meaning that staying in one position was never safe for long.
I made asteroids appear first because they move the slowest and are the easiest hazard to understand. As the player progressed, more dangerous hazards were introduced.
I also designed dark matter clouds that would travel downwards and obscure the player's vision. The visual-blocking part was never finished, but the idea was to create another reason for the player to reposition in a way where they would suffer the least from these clouds.
Regaining Ammo
I wanted the player's position to affect how they manage their ammo.
The player regenerates ammo while staying close to enemies and their projectiles. The longer they remain nearby, the more ammo they regain.
This meant that moving away from danger was not always the best option. Sometimes the player has to deliberately stay close to enemies to recover resources, while still being ready to reposition when the surrounding hazards make their position unsafe.
Enemy Eyeballs Movement
I designed the eyeball enemies' to be cowards which position themselves in the safest possible manner to avoid conflict with the player for as long as possible.
Eyeballs are high-priority targets, but because of this behaviour where they try to stay behind meatshield enemies, it prevents the player from abusing the 2D movement and moving upwards to try and immediately kill these threats. Additionally, I made them consider the positions of other nearby eyeballs, which prevented them from stacking on top of each other.
When there were no meatshields left, the eyeballs would rush towards the player. I am less satisfied with this behaviour today. If I were to redesign it, I would have them scatter and continue flying away from the player when they get too close, keeping their non-confrontational behaviour consistent.