Objective: Create a script that will handle all powerup behaviors in game

Our objective is to create a powerup script that will control all of our powerups instead of having 1 script per variable.

We will achieve this by using a different ID for each variable, which will trigger different parts of our code.

New Powerup ID variable

Once we null check the the player, we simply select what which script we need to run based on the ID of our powerup.

Powerup Selector

Now we have a way of using 1 script for all powerups.