How to create this kind of random movement effect?

A place for people with an interest in developing new shmups.
Post Reply
User avatar
DyingIsFun
Posts: 35
Joined: Mon May 31, 2021 7:14 am
Contact:

How to create this kind of random movement effect?

Post by DyingIsFun »

I’ve noticed in a lot 2D shmups (for example, Cho Ren Sha 68K), after enemies accelerate onto screen and arrive at their arrival point, they don’t simply sit static at their arrival position, but rather begin to gently undulate in place in what appear to be slow random movements in their immediate neighborhood.

This movement helps to give them life, as if they were really floating in space and subject to the capriciousness of their thrusters.

My question is what are some effective ways to implement this kind of movement?

I think that a lot of shmups use steering behavior methods to get their enemies to arrive on screen and move from point to point (especially for the types of enemies that need to appear and remain on screen, as opposed to popcorn that follow parameterized bezier curve splines). For example, I imagine an enemy spawns just off screen and does normal seek-with-arrival behavior to a random point on screen. (Though sometimes it looks like ships overshoot their arrival point and get pulled back a bit—also curious how to implement this kind of thing)

If this is true, and this technique is used for spawn and arrival, maybe they also use some kind of Wander() steering behavior to achieve the small random movements in the enemy’s neighborhood? Does anybody have tips or techniques here, or specific ways different games have implemented this?
Post Reply