
Learning Stencyl 3.x Game Development: Beginner's Guide
By :

The game file to import and load for this session is 5961_07_03.stencyl
.
Download Stencyl Book Pickup Effect from StencylForge, and then close the tabs for the sound effect and StencylForge.
In the Sound Management behavior, add a new custom event called Pickup SFX
.
Configure the new Pickup SFX event as shown in the following screenshot:
Open the Manage Player Collisions actor behavior, and ensure that the Collides with Collectibles event is selected.
Add a trigger for the
PickupSFX event as highlighted in the following screenshot, which shows an extract from the Collides with Collectibles
event:
Test the game and collect some fruit!
We now have a second sound effect in our game: a pickup sound effect is played as each piece of fruit is collected.
After downloading the sound effect from StencylForge, the process to make the sound play took only a few changes.
We have created a Pickup SFX
event in the Sound Management
behavior...
Change the font size
Change margin width
Change background colour