Weapon Upgrade Tutorial
From Shoot Em Up Kit
This tutorial shows how to set a player weapon upgrade when a bonus item is collected and when a trigger is hit.
First, set up the player weapons.
On the Player General tab
- Choose the Weapon Definition for Slot 1
- Select Add Weapon to add Weapon Slot 2
- Select the Weapon Definition and Fire From Tag for the weapon
- Uncheck Enabled
- Select Add Weapon to add Weapon Slot 3
- Select the Weapon Definition and Fire From Tag for the weapon
- Uncheck Enabled
Next, create the new Upgrades
Select Upgrade on the Define menu
Select Create New
In the Upgrade window
- Name the upgrade
- Set a Duration for a time-limited upgrade or leave as 0 for a permanent upgrade
- For Type, select Enable Weapon
- For Enable Weapon Slot, select the slot of the new weapon (Slot 2)
- Add another Type and set to Disable Weapon Slot
- For Disable Weapon Slot, select the slot of the current weapon (Slot 1)
- Repeat to create a second Upgrade to upgrade from Slot 2 to Slot 3
Next, add a bonus NPC and set its properties as follows:
In the AI tab, delete all AI types so it does not move or fire
In the Collision tab, set Collision Damage to 0 so it does not damage the player when hit
In the Actions tab, click on the Upgrade (Other) value (default None) and select the first new Upgrade from the list
Next, add a trigger by selecting Add a Trigger on the Tools menu and placing it in the level.
Set the trigger to do the second weapon upgrade by clicking on the Upgrade Activator value (default None) in the trigger Properties window and selecting the second new Upgrade from the list.
Run the game and the weapon will change when the bonus item is collected then change again when the trigger is hit.