hello, im a newbie in gdevelop5 and im currently creating a quiz game
I’m having a trouble in my game where when the character collided to a object it will be sent to a scene where i place a question and upon answering it they will go back to the previous scene.
currently i have 10 scenes and i want them to randomly appear in the screen upon collision with an object.
the Scenes i have ;
the scene for game
and the 10 scenes for the question
So what are you after, with what are you having trouble?
im having a trouble on the scene, it won’t appear randomly if i use
Change to “Scene_” +ToString(Variable (Scene))
my scenes are named “Scene 1” , “Scene 2”,and so on
help me ,what should i use in this case?
Change to scene "Scene_" + ToString(Random(1,10)).
Make sure the scene name before the number is correct. You’ve given “Scene_”, but you write the scene names are Scene 1, Scene 2, etc, with a space in the name.
Also, you can use VariableString(…) instead of ToString(Variable(…))
this is also my scene names
My bad, it should be
Change to scene "Scene " + ToString(RandomInRange(1,10)) (note the space in the string "Scene ")
Thank You very much, you really saved my ass. Thank you very much.