In my game i have an button to watch ads. After you click on that, and the reward video is closed. You see a animation and a sound. This only works the first time after opening the game. When you do the exact same thing the second time, the sound doesn’t play but the rest of the events does work well. How to fix this?
I have tried multiple options. Like without the trigger once, or on diffrent placements under the conditions. But always with the same outcome.
That stays the same. It should work,and i dont get why it doesnt work.
So the value of sound is always 0 in this instance. And the value of geluidextra is 0 at the start of the scene. After the ad plays the value changes to 1. So the 1st time it does that, 2st ,3st etc.
In the home of the game i change the value of geluidextra to 0. It was first in these events, but i tried many thing to make this work. So i tried to reset it in the home.
Sound doesn’t play after the 1st time of playing it.
Everytime i watch an ad the text changes to “KLIK”.
So i really dont get why the sound isn’t working. Does anybody know a fix or work around for this? This is the only thing i have to fix before i can release the game.
Outside of 1 very specific scenario (an assets subfolder) GDevelop does not natively support subfolders in projects or resources. While I realize it may frustrate some folks, you should really not move your sounds outside of the main project folder (or into a subfolder). You should try moving it back to the project folder to avoid any weird oddities.
Ensure the sound file is set as preloaded in resources.
Remove the variable checks entirely and add a key press instead.
If 1 and 2 don’t fix it, but 3 does, then it’s something going on with your variables.