How long should powerups last?
An important element of game design is how and when powerups are provided for the player and, how long they should last.
Buffs or powerups can add an exciting twist to a game. If implemented correctly, they can provide a moment of respite in a challenging game, giving the player to sit rest on invulnerability or super powerful weapons for a short time before the onslaught continues.
They are a great way to change up the pace of a game, but how long those powerups last is an important consideration.
If they last too long, the game can be too easy and, ultimately, boring.
Too short and they may seem like a pointless addition.
Let’s see how to implement the control and then we can talk about the thought process behind determining the duration.
In my player script I have added a serialized float variable that will allow a designer to alter how long a powerup lasts once collected, in this case, 5 seconds.
I have also set up a coroutine that is called when the powerup is collected. This takes our variable and uses it for the yield time before the powerup is deactivated. A simple way to control the duration that can be tweaked inside Unity.
So how do we decide how long? Well I’ve started with 5 seconds and I will playtest the game at that duration. Other factors need to be considered, for instance rate of fire and the frequency of powerup spawns. If they spawn often then the duration should be short, but it may make for a better game experience if they spawn rarely and last a bit longer.
Playing through the game with the powerups, we get a better feel for them and can use this hands on experience to tweak our values.