Skip to content

A server side Fabric mod that posts quizzes at set intervals with item rewards

License

Notifications You must be signed in to change notification settings

SerpentesNL/Trivia-Carbon

 
 

Repository files navigation

Trivia - A Fabric 1.20.1 Question & Reward Plugin

This fork makes Trivia work with the Carbon Chat mod

Originally created for the Roanoke Cobblemon Server to make Cobblemon items more obtainable

On first run, the plugin will generate a Trivia folder with both questions & rewards JSON files.

Questions/Rewards are added under "pools", which could be treated as categories or "difficulty ranges".

A quiz question will be put in chat every 10 minutes, and will time out if not answered in 2 minutes.

If a player's inventory is full, or inserting the item goes wrong for some other reason, it is dropped in front of them.

img.png

Upcoming Features

  • Configuration - chat formatting will be made configurable /w MiniMessage & Placeholder support
  • Probability - probabilities will be configurable both on pools & individual questions/rewards
  • Cobblemon Integration - use Cobblemon API to auto generate questions like "What type is this Pokemon", "What's the ability from this description" etc
  • Command Rewards - with player name placeholders, so crates/pokemon/claim blocks can be given as rewards
  • Commands

  • /trivia reload [trivia.reload] - reload questions & rewards files
  • /trivia interval (seconds) [trivia.interval] - set the amount of time that should pass between questions
  • /trivia timeout (seconds) [trivia.timeout] - after this many seconds, the question is "timed out" and not answerable
  • /trivia start [trivia.startt] - force start a quiz, useful for testing questions/rewards
  • Questions & Rewards Files

    On first run, these should be generated automatically, you can change them under /config/Trivia/

    Both questions & rewards are under "pools", think of these as categories or difficulty types. Questions under the "easy" pool will give rewards from the "easy" pool, but the same could be done for Pokemon vs Minecraft trivia.

    Example questions.json

    ```json { "easy": [ { "question": "What type is Bulbasaur?", "answers": [ "Grass", "Poison" ] } ], "medium": [ { "question": "What ability does Bulbasaur have?", "answers": [ "Overgrow", "Chlorophyll" ] }, { "question": "What ability does Ivysaur have?", "answers": [ "Overgrow", "Chlorophyll" ] } ] } ```

    Example rewards.json

    ```json { "easy": [ { "item_name": "cobblemon:dawn_stone", "display_name": "Dawn Stone", "quantity": 1 } ], "medium": [ { "item_name": "cobblemon:link_cable", "display_name": "Link Cable", "quantity": 1 }, { "item_name": "cobblemon:dragon_scale", "display_name": "Dragon Scale", "quantity": 1 } ] } ```

    About

    A server side Fabric mod that posts quizzes at set intervals with item rewards

    Resources

    License

    Stars

    Watchers

    Forks

    Releases

    No releases published

    Packages

    No packages published

    Languages

    • Java 100.0%