I want to upload a file containing questions and options and i want to readd it using scrpt and render the questions on 2D screen. Can i do it on playcanvas? If yes, then how?
https://playcanvas.com/editor/scene/1072109
Hi @mortal_phoenix,
What format is your quiz file?
Usually a good format is JSON, so you can prepare arrays of objects, and each objects holds a set of question & answers.
From there you can load that file in a script of yours, loop through the array and do something with the data.
You can prepare a template entity that includes UI elements for the question and answers, and on each loop iteration instantiate (clone) it and set the text accordingly.
3 Likes