How to Manage Knowledge Quizzes Using Variables

Enhancing Quizzes with Variables

Aryel
Written by AryelLast update 3 days ago

Variables are fantastic elements when you want to create dynamic and personalized experiences. In a quiz, variables allow tracking the user's progress, adapting content to their answers, and even providing personalized feedback. Here's a step-by-step guide on using variables in Aryel's quizzes.

Inserting the numeric variables

To start, you need to define the variable you intend to work with. To do this, you have to enter it in the field located at the bottom left.

In our case, we choose a numeric variable with an initial value of 0, however, depending on the goals and needs of the experience being created, this initial value can be modified.

Interacting with the variables

After defining the variable, you can change its value based on user interactions. This can be done using the "edit variable" function inside scene elements. Within this function, you can insert mathematical operations that interact with the previously created variable. For example, if you want to increase the variable by one every time the user answers a question correctly, you could insert an operation like "add 1".

Based on the choices the user will make, this variable can then take on different values according to the scores given by each answer. In our case, incorrect answers do not modify the variable, so it is not necessary to insert the related interaction.

Defining the transitions between scenes using conditions

Once you have decided how and when to modify the variable, you can decide what action to take based on its value. This is particularly useful to guide the user through different scenes or sections of the quiz depending on their answers.

For example, if the variable reaches a certain value indicating that the user has answered all the questions correctly, you could insert an interaction that sends the user to a congratulations scene based on the conditions. In this case we decided to award titles based on correct answers.

So, based on the ranges set within the conditions, the user will be directed to the final scene related to their achieved score.

Score display

To make the experience more engaging and provide feedback to the user, you can display the variable's value directly within the quiz content.

To do this, just insert the variable's name in curly brackets in any text field. For example, if the variable is called "score", entering "{score}" in a text field will display the variable's current value, allowing the user to see their score.

In conclusion, using variables in Aryel offers a level of flexibility and dynamism that can make the quiz experience much more interactive and personalized. With a bit of practice, you can create an engaging and feedback-rich learning experience for users.

Did this answer your question?