Please help @ddabrahim or any Gdeveloper here.
Would it be possible to alter the Quiz game extension to be able to use it in parts across various scenes.
What I mean is the current quiz template via the Quiz game extension successfully runs on a single scene. So if it had 50 questions, I want to be able to use only the first 5 questions for a scene I call Assessment 1, maybe the next 6 for another scene called Assessment 2 and so on.
My inability to do this made me create an array for each scene that produces similar results but the problem is that it does not randomly shuffle the answers on the placeholders. If I run the quiz with this method, the questions and answers appear randomly when timer is over, but the positions of the answers remain the same all the time which is bad to test the students knowledge.
I have also tried to use the shuffle array tools using the action shuffle array “arrayname” at the beginning of scene, but it isnt working. What I noticed is that it repeats the first quiz that appears twice and continues. Not sure how it works.
(Edited) Please I am also stuck with the quiz continuing endlessly without stopping based on the tween timer settings. What can i do to stop it after the 5 questions I have put in the array.
A similar event I created based on what I found on the forum here.
Please help me. Thank you.
What’s the problem exactly? I’m getting confused, there is an extension to randomize a number if that’s what your asking about, for To. Gdevelop has a menu tutorial about tweening. https://www.google.com/url?sa=t&source=web&rct=j&url=https://www.youtube.com/watch%3Fv%3DcScpPcV9v4M&ved=2ahUKEwiRu6bWvKr_AhVhpIQIHT_WA9wQwqsBegQIDxAF&usg=AOvVaw1cTOnDUpMjyRPzhNhbeG5S is the link to the video,
I didn’t create the quiz extension and never used it. No idea how it works. I can’t help you with that.
I believe the template I made using nothing but variables, should work with multiple scenes. Have you tried that?
(Edited)
Thank you for responding and sharing the template…its a life saver.
Would you know how i can position the answers randomly across the AnswerBags such that next time when the question repeats, the answers dont sit in the the same AnswerBags as earlier.
I will appreciate your help again.
Unfortunately the template I shared was not designed to pick random answers. You need to implement this from scratch.
I don’t have time to explain in detail how to do it but you can use either an array or structure variables to store the answers for each question including the correct answer and then when you pick a random question, similar way you pick the random answers too.
If you don’t understand how the questions and answers are stored and used in the template, I recommend to look up the following topics in the documentation and watch tutorials about them:
- For each object event
For each object event - GDevelop documentation
- While event
While events - GDevelop documentation
- Variables and Arrays
Variables - GDevelop documentation
- Math, Variable and Array Expressions.
Variables: Expressions reference - GDevelop documentation
Math: Expressions reference - GDevelop documentation
Examples of expressions also included on the above pages for each topic.
You need to be familiar with these topics in order to implement random answers.
Great! I am indeed thankful. I will look at the topics and see how I can resolve the challenges currently faced. Thank you again for your time.