Comment on page
Create a Trigger
In this how-to guide, we are going to create a Trigger for our game that grants XP whenever the player enters a new area in our game's world. This guide will walk you through implementing Progression in both LootLocker and in-game.
To start, let's navigate to the Triggers menu by clicking
Triggersin the Game Systems side bar menu.
To create a new Trigger, click the
Add Triggerbutton in the top right corner, and name your trigger. Since we plan to have many areas in our game world, we are going to use a naming system that is easy to expand on. This trigger will be called
zoneA_area1as that is what the area will be called in the game editor. Once you have named your Trigger, click
Saveto save it.
Now that the Trigger has been created, I want to add an XP reward. To do that, click
Add Rewardto bring up the select Asset model. Instead of selecting an Asset as normal, I will use the
Set a Scorefield to enter the XP I would like to grant to the player when the Trigger is triggered. Once you have entered the amount, click
Save Score Onlyto save and continue.
You should now see the XP added as a reward.
Finally, we want to make sure that the player can only trigger this reward once by selecting
Trigger Timessection, and entering
1into the field. This will make sure that the Trigger can only be triggered once.
You have now set up a Trigger in LootLocker and are ready to implement it in-game.