Quest Manager

Quest Manager 1.0.0

Compatible API Versions
1.0.0
Plugin Description: Quest Manager
Quest Manager is a plugin designed for Minecraft servers running Nukkit. It enables server administrators to create and manage quests that players can complete for rewards. The plugin provides functionality for defining quests with specific requirements, setting cooldowns, and tracking player progress.

Features:
  • Quest Definition: Configure quests using YAML configuration files. Define the required item(s), amount, rewards, and cooldown periods.
  • Item Collection: Players must collect and have the specified amount of items in their inventory to complete a quest.
  • Rewards: Upon completing a quest, players receive rewards as defined in the configuration file.
  • Cooldown System: Quests come with a cooldown period, ensuring players cannot repeat them immediately. The cooldown is configurable and tracked per player.
  • Player Data Management: Player-specific cooldowns are saved in JSON files, allowing for persistent tracking across server restarts.
  • Form Interaction: Players can interact with quest forms to check quest availability, see cooldowns, and attempt to complete quests.
  • Database: plugins/MyPlugin/config.yml - date of rewards
  • Database: plugins/MyPlugin/MyPlugin - date of players cooldowns
Configuration:
  1. quests Section:
    • item: The ID of the item players need to complete the quest.
    • amount: The required quantity of the item.
    • reward: The ID of the reward item.
    • reward_amount: The amount of the reward.
    • cooldown: The cooldown time in seconds before the quest can be attempted again.
  2. messages Section:
    • quest_complete: Message displayed to the player upon quest completion.
    • quest_on_cooldown: Message displayed when a player attempts a quest that is on cooldown.
    • quest_not_enough_items: Message displayed if the player does not have the required items for the quest.
Commands:
  • /quest - Opens the quest form, allowing players to view and attempt quests.
Installation:
  1. Place the plugin JAR file in the plugins directory of your Nukkit server.
  2. Restart the server to load the plugin.
  3. Configure quests and messages in the config.yml file located in the plugin's directory.
  4. Ensure that your players are aware of the new quest features and commands.
Permissions:
  • The plugin does not require specific permissions for players to access quests, but server administrators may set permissions for advanced features or management.
If you have any questions or would like to get the source code, feel free to write in the discussion or contact me on Discord @maxoneryt.

Code:
quests:
- item: "minecraft:diamond" # Item ID
amount: 10 # Required amount of items
reward: "minecraft:emerald" # Reward ID
reward_amount: 6 # Amount of reward
cooldown: 36000 # Cooldown in seconds (e.g., 36000 seconds = 10 hours)

- item: "minecraft:iron_ingot"
amount: 20
reward: "minecraft:gold_ingot"
reward_amount: 12
cooldown: 7200 # Cooldown in seconds (e.g., 7200 seconds = 2 hours)

# Example messages
messages:
quest_complete: "Congratulations! You have completed the quest and received %amount% %reward%!"
quest_on_cooldown: "You must wait to complete this quest again. Time remaining: %time%"
quest_not_enough_items: "You have not completed this quest yet. You need %amount% %item%."
1726856263286.png
Author
maxoneryt
Downloads
48
Views
304
First release
Last update
Rating
0.00 star(s) 0 ratings

More resources from maxoneryt

Top