Trivia Scores

Calculates rank based on score and user names, loops through collected information

When to use?

Only available in trivia package

How to use:

  1. Make sure you've got an indexed array containing player names and their scores
  2. In the players field enter name of the the array, like this: ${players}
  3. In the Status variable name enter the name under which you'll be able to access player name, score, rank etc., for example: item
  4. In the Name field enter the name of the name field in the players array, for example: name
  5. In the Score field enter the name of the score field in the players array, for example: score
  6. The element has three containers - single, multiple and all
  7. You can put any amount of elements in both of them
  8. The single container will trigger when players have a unique score/rank
  9. The multiple container will trigger when players share a score/rank
  10. The all container will trigger when all players have the same score/rank (there has to be multiple users)
  11. You can access player names in the multiple/all container by using status variable name(in this example it's 'item') and an array key called 'names', like this:${item.names}
  12. You can access player name in the the single container like this:${item.name}
  13. To access player/s rank use this:${item.rank}
  14. You can access player/s score like this:${item.score}
  15. To check for the first place player/s use this:${item.first}
  16. To check for the last place player/s use this:${item.last}

Example of usage

We created a two-dimensional array in this format: players[index]["name"], players[index]["score"]