Tutorial - Formatting questions and rewards

What can you find here

On this page, you can find how to:

  • Format your questions
  • Format rewards

Formatting questions

Questions are set up in config.yml. In default config.yml, your questions should look like this:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
Questions:
  1:
    Question: '&6What is 1+1?'
    Answers:
    - 2
  2:
    Question: '&6Who created Minecraft?'
    Answers:
    - Notch
    - notch
    - Markus Persson
    - markus persson

As you can see, questions have their own sections, numbered from 1 to n (where n is less than or equal to 2,147,483,639).
If you want to create a question, which asks 'Who created music for Minecraft' in dark red and answers are 'C418' and 'c418', put this under existing answers:

1
2
3
4
5
  3:
    Question: '&4Who created music for Minecraft?'
    Answers:
    - C418
    - c418

Or replace any existing questions. Your questions should then look like this:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
Questions:
  1:
    Question: '&6What is 1+1?'
    Answers:
    - 2
  2:
    Question: '&6Who created Minecraft?'
    Answers:
    - Notch
    - notch
    - Markus Persson
    - markus persson
  3:
    Question: '&4Who created music for minecraft?'
    Answers:
    - C418
    - c418

or like this:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
Questions:
  1:
    Question: '&6What is 1+1?'
    Answers:
    - 2
  2:
    Question: '&6Who created music for Minecraft?'
    Answers:
    - C418
    - c418


Note: All questions should be enclosed in single quotes

Formatting rewards

Rewards are also set up in config.yml. In default config.yml, your rewards should look like this:

1
2
3
4
5
6
7
8
9
# Rewards
# Format of rewards:
# money:<amount>
# item:<item type>,<amount>,enchant:<enchant>-<level>;<enchant>-<level>,name:<name>,lore:<lore>/<second line>
Rewards:
- money:1
- item:DIAMOND_SWORD,1,enchant:DAMAGE_ALL-1;FIRE_ASPECT-2,name:A_Sword,lore:First_line/Second_line
- money:2 item:DIRT,1
- money:50 item:DIRT,1 item:STONE,5

As you can see, there are already some guidelines on how to format rewards, but I'll explain it here a bit more. So let's start!

Money

Let's look on how to add monetary rewards! It is very simple. Just add this one line to rewards section:

1
- money:<value>

And instead of <value>, you can set (almost) any number you want!
Note: Negative values and values above 1 trillion can have unexpected behaviour

Items

Now let's look on how to add item rewards! It is also quite simple.

Basic

Basic item reward:

1
2
Rewards:
- item:DIRT,1

Note: As you may see, there is only material name (All material names can be found here) and amount of said item.

Items with one enchantment

Items with one enchantment are done like this:

1
2
Rewards:
- item:DIAMOND_SWORD,1,enchant:DAMAGE_ALL-1

Note: Overlevelling enchantments can have unexpected behaviour. Support of overlevelled enchantments will be added in future versions.
Note: All enchantment names can be found here

Items with more enchantments

Items with more enchantments are done like this:

1
2
Rewards:
- item:DIAMOND_SWORD,1,enchant:DAMAGE_ALL-1;FIRE_ASPECT-2

Note: You may see enchantments are separated by semicolon.

Items with custom name and/or lore

Note: Do not put any spaces in name or lore, use underscores instead. All underscores will be replaced by spaces when rewards are given to players.
Items with only name are done like this:

1
2
Rewards:
- item:DIAMOND_SWORD,1,name:A_sword_from_reward


Items with only lore are done like this:

1
2
Rewards:
- item:DIAMOND_SWORD,1,lore:Some_lore_for_item


Items with multiple-line lores are done like this:

1
2
Rewards:
- item:DIAMOND_SWORD,1,lore:First_line_of_lore/Second_line_of_lore

Note: As you may see, lines are separated by '/'. This may change in future versions.
Items with name and lore (single line or multiple lines) are done like this:

1
2
3
Rewards:
- item:DIAMOND_SWORD,1,name:A_Sword,lore:Some_item_lore
- item:DIAMOND_SWORD,1,name:A_Sword,lore:First_line_of_lore/Second_line_of_lore
Items with everything

Items with multiple enchantments, name and lore are done like this:

1
2
3
Rewards:
- item:DIAMOND_SWORD,1,enchant:DAMAGE_ALL-1;FIRE_ASPECT-2,name:A_Sword,lore:First_line/Second_line
- item:DIAMOND_PICKAXE,1,enchant:DIG_SPEED-3;LOOT_BONUS_BLOCKS-1,name:Some_random_pickaxe,lore:This_is_a_pickaxe/with_multi-lined_lore

Note: As you may see, different properties of items are separated by a comma. It doesn't matter if you put enchantments first, then name and then lore, or name first, enchantments second and lore third. Only thing that matters - they have to be separated by a comma

Money and items in one reward

If you want to give your players money and items in one reward, it is also quite simple! Just do it like this:

1
2
3
4
5
6
Rewards:
- money:1
- item:DIAMOND_SWORD,1,enchant:DAMAGE_ALL-1;FIRE_ASPECT-2,name:A_Sword,lore:First_line/Second_line
- money:2 item:DIRT,1
- money:50 item:DIRT,1 item:STONE,5
- money:30 item:GOLD_PICKAXE,1 item:WOOD_SWORD,1,enchant:DAMAGE_ALL-2,name:Useless_sword

If you still don't get it, just post a comment or send me a PM and I will try to explain it a bit more for you!


Comments

Posts Quoted:
Reply
Clear All Quotes