TownyAdvanced / TownyResources

Adds value to towns, by giving each one a unique set of automatically-generated resources.
Other
33 stars 17 forks source link

Error occurred while enabling TownyResources v0.1.0 (Is it up to date?) #41

Closed noisereactz1 closed 3 years ago

noisereactz1 commented 3 years ago

I got a new error :( the resource offer categories are now loading..

[16:09:39 INFO]: [TownyResources] Towny version 0.97.1.0 found. [16:09:39 INFO]: [TownyResources] SiegeWar Integration Not Enabled [16:09:39 INFO]: [TownyResources] DynmapTowny Integration Enabled [16:09:39 INFO]: [TownyResources] Slimefun Integration Not Enabled [16:09:39 INFO]: [TownyResources] LanguageUtils Integration Not Enabled [16:09:39 INFO]: [TownyResources] Config Loaded [16:09:39 INFO]: [TownyResources] Lang: english.yml v0.06 loaded. [16:09:39 INFO]: [TownyResources] All Resource Offer Categories Loaded [16:09:39 ERROR]: Error occurred while enabling TownyResources v0.1.0 (Is it up to date?) java.lang.NoClassDefFoundError: net/md_5/bungee/api/chat/BaseComponent at io.github.townyadvanced.townyresources.TownyResources.loadAll(TownyResources.java:68) ~[?:?] at io.github.townyadvanced.townyresources.TownyResources.onEnable(TownyResources.java:34) ~[?:?] at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:263) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:343) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:479) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugin(CraftServer.java:480) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at org.bukkit.craftbukkit.v1_16_R3.CraftServer.enablePlugins(CraftServer.java:406) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at net.minecraft.server.v1_16_R3.MinecraftServer.loadWorld(MinecraftServer.java:426) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at net.minecraft.server.v1_16_R3.DedicatedServer.init(DedicatedServer.java:205) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at net.minecraft.server.v1_16_R3.MinecraftServer.w(MinecraftServer.java:787) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at net.minecraft.server.v1_16_R3.MinecraftServer.lambda$0(MinecraftServer.java:155) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at java.lang.Thread.run(Unknown Source) [?:1.8.0_301] Caused by: java.lang.ClassNotFoundException: net.md_5.bungee.api.chat.BaseComponent at java.net.URLClassLoader.findClass(Unknown Source) ~[?:1.8.0_301] at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:167) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at org.bukkit.plugin.java.PluginClassLoader.findClass(PluginClassLoader.java:96) ~[craftbukkit-1.16.5.jar:2991-Bukkit-f3f3094] at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_301] at java.lang.ClassLoader.loadClass(Unknown Source) ~[?:1.8.0_301] ... 12 more

LlmDl commented 3 years ago

Include your config. We aren't psychic and I haven't hacked into your mainframe so I don't have a copy of it.

noisereactz1 commented 3 years ago
version:
  # This is the current version.  Please do not edit.
  version: 0.1.0
# The language file you wish to use
language: english.yml

# If true, the TownyResources system is enabled.
# if false, the TownyResources system is disabled.
enabled: 'true'

############################################################
# +------------------------------------------------------+ #
# |             Resource Extraction Limits               | #
# +------------------------------------------------------+ #
############################################################

resource_extraction_limits:

  # If true, then daily player resource extraction limits are enabled.
  # If false, then daily player resource extraction limits are disabled.
  enabled: 'false'

  # The cooldown after a player receives a daily-limit warning message.
  # During this time they cannot receive another daily-limit warning message for the same material.
  cooldown_after_daily_limit_warning_message_millis: '5000'

  # This list shows the resource extraction categories.
  # 
  # Each category is enclosed in curly brackets, and has 3 parts:
  # 1 - The name of the category (used for messaging)
  # 2-  The daily limit per player (in stacks)
  # 3-  The list of materials in the category
  categories: '{common_dirt, 3, DIRT, FARMLAND},{uncommon_dirt, 1, PODZOL, ROOTED_DIRT, MYCELIUM},{rare_dirt, 1, SOUL_SOIL},{gravel, 1, GRAVEL},{sand, 3, SAND},{common_rocks, 2.5, STONE, COBBLESTONE},{uncommon_rocks, 1.5, DIORITE, ANDESITE, GRANITE, MOSSY_COBBLESTONE, MAGMA_BLOCK, BASALT},{terracotta, 1.5, TERRACOTTA, WHITE_TERRACOTTA, ORANGE_TERRACOTTA, MAGENTA_TERRACOTTA, LIGHT_BLUE_TERRACOTTA, YELLOW_TERRACOTTA,LIME_TERRACOTTA, PINK_TERRACOTTA, GRAY_TERRACOTTA, LIGHT_GRAY_TERRACOTTA, CYAN_TERRACOTTA,PURPLE_TERRACOTTA, BLUE_TERRACOTTA, BROWN_TERRACOTTA, GREEN_TERRACOTTA, RED_TERRACOTTA,BLACK_TERRACOTTA},{quartz, 0.25, QUARTZ_BLOCK},{prismarine, 0.125, PRISMARINE},{obsidian, 0.125, OBSIDIAN},{clay, 1, CLAY_BALL, CLAY},{ice, 1, ICE, PACKED_ICE, BLUE_ICE},{snow, 1, SNOW, SNOWBALL, SNOW_BLOCK},{coal, 1, COAL, COAL_BLOCK},{iron, 1, IRON_ORE, IRON_INGOT},{gold, 0.25, GOLD_ORE, DEEPSLATE_GOLD_ORE, GOLD_INGOT},{gold_nuggets, 0.25, GOLD_NUGGET, NETHER_GOLD_ORE},{emeralds, 0.25, EMERALD_ORE, EMERALD},{lapis_Lazuli, 0.25, LAPIS_LAZULI, LAPIS_BLOCK, LAPIS_ORE},{diamonds, 0.125, DIAMOND_ORE, DIAMOND},{redstone, 1, REDSTONE, REDSTONE_BLOCK},{netherrack, 4, NETHERRACK},{nether_quartz, 1, NETHER_QUARTZ_ORE, QUARTZ},{glowstone, 0.25, GLOWSTONE_DUST, GLOWSTONE},{end_Stone, 4, END_STONE},{ancient_debris, 0.03125, ANCIENT_DEBRIS},{wood, 3.5, OAK_LOG, SPRUCE_LOG, BIRCH_LOG, JUNGLE_LOG, ACACIA_LOG, DARK_OAK_LOG,CRIMSON_STEM, WARPED_STEM, OAK_WOOD, SPRUCE_WOOD, BIRCH_WOOD, JUNGLE_WOOD,ACACIA_WOOD, DARK_OAK_WOOD, CRIMSON_HYPHAE, WARPED_HYPHAE}{wool, 0.5, WHITE_WOOL, ORANGE_WOOL, MAGENTA_WOOL, LIGHT_BLUE_WOOL, YELLOW_WOOL,LIME_WOOL, PINK_WOOL, GRAY_WOOL, LIGHT_GRAY_WOOL, CYAN_WOOL,PURPLE_WOOL, BLUE_WOOL, BROWN_WOOL, GREEN_WOOL, RED_WOOL,BLACK_WOOL},{Coral, 1, TUBE_CORAL, BRAIN_CORAL, BUBBLE_CORAL, FIRE_CORAL, HORN_CORAL,TUBE_CORAL_BLOCK, BRAIN_CORAL_BLOCK, BUBBLE_CORAL_BLOCK, FIRE_CORAL_BLOCK, HORN_CORAL_BLOCK,DEAD_TUBE_CORAL_BLOCK, DEAD_BRAIN_CORAL_BLOCK, DEAD_BUBBLE_CORAL_BLOCK, DEAD_FIRE_CORAL_BLOCK, DEAD_HORN_CORAL_BLOCK,TUBE_CORAL_FAN, BRAIN_CORAL_FAN, BUBBLE_CORAL_FAN, FIRE_CORAL_FAN, HORN_CORAL_FAN,DEAD_TUBE_CORAL_FAN, DEAD_BRAIN_CORAL_FAN, DEAD_BUBBLE_CORAL_FAN, DEAD_FIRE_CORAL_FAN,DEAD_HORN_CORAL_FAN},{wheat, 1, WHEAT},{carrots, 1, CARROT},{potatoes, 1, POTATO},{beetroot, 1, BEETROOT},{melon_slices, 1, MELON_SLICE},{cocoa_beans, 1, COCOA_BEANS},{pumpkin_blocks, 0.125, PUMPKIN},{melon_blocks, 0.125, MELON},{cocoa_pods, 0.125, COCOA},{kelp, 1, KELP},{bamboo, 1, BAMBOO},{cactus, 1, CACTUS},{mushrooms, 1, BROWN_MUSHROOM, RED_MUSHROOM},{apples, 0.125, APPLE},{vines, 0.25, VINE},{nether_wart, 1, NETHER_WART},{chorus_fruit, 1, CHORUS_FRUIT},{fish, 0.5, COD, SALMON, PUFFERFISH, TROPICAL_FISH},{gunpowder, 0.25, GUNPOWDER},{string, 0.25, STRING},{spider_eyes, 0.25, SPIDER_EYE},{slime, 0.25, SLIME_BALL, SLIME_BLOCK},{feathers, 0.25, FEATHER},{leather, 0.25, LEATHER},{rabbit_hides, 0.25, RABBIT_HIDE},{rotten_flesh, 0.5, ROTTEN_FLESH},{bones, 0.5, BONE, BONE_BLOCK},{pork, 0.25, PORKCHOP, COOKED_PORKCHOP},{mutton, 0.25, MUTTON, COOKED_MUTTON},{beef, 0.25, BEEF, COOKED_BEEF},{chicken, 0.25, CHICKEN, COOKED_CHICKEN},{chorus_fruits, 0.25, CHORUS_FRUIT},{ender_pearls, 0.125, ENDER_PEARL}'

############################################################
# +------------------------------------------------------+ #
# |                  Town Resources                      | #
# +------------------------------------------------------+ #
############################################################

town_resources:

  surveys:

    # If true, players can do surveys.
    # if false, they cannot.
    enabled: 'true'

    # This list of values determines how much it costs to do a survey for each resource level.
    # Example: If the first value is 250, then it will cost 250 to survey and discover the level 1 resource.
    cost_per_resource_level: 250, 1000, 5000, 20000

    # This list of values determines how much many townblocks a town must have to DISCOVER each level of resource.
    # Example: If the first value is 10, then the town must have 10 townblocks to survey and discover the level 1 resource.
    num_townblocks_requirement_per_resource_level: 10, 50, 100, 200

  production:

    # If true, towns produce resources.
    # if false, towns do not produce resource.
    enabled: 'true'

    # This list of values determines the level a town needs to be, to PRODUCE its resources.
    # Example: If the first value is 1, then the town has to be level 1 to produce its level 1 resource.
    town_level_requirement_per_resource_level: 2, 4, 6, 8

    # This list of values determines the productivity of each level of resource.
    # Example: If the second value is 200, then the level 2 resource of a town will be 200% productive.
    productivity_percentage_per_resource_level: 100, 200, 300, 400

    # This value determines the limit of how many resources of each type can be stored for collection.
    # Example: If this value 3, and the daily production amount is 32 ..... then the storage limit is 96.
    storage_limit_modifier: '5'

    # The nation of a town gets this percentage of town production, as long as the town is not occupied.
    # The town gets the rest.
    nation_tax_percentage: '50'

    # If a town is occupied, the occupying nation gets this percentage of town production.
    # The town gets the rest.
    occupying_nation_tax_percentage: '50'

  offers:

    # This list shows the survey offer categories.
    # 
    # Each category is enclosed in curly brackets, and has 4 parts:
    # 1 - The name of the category (used for messaging)
    # 2 - The discovery weight of the category (used during discovery)
    # 3-  The base amount of the offer (in stacks)
    # 4-  The list of materials in the category
    # 
    # The default values give a weight of 200 to strategic resources (coal, iron etc.), and 100 to most non-strategic resources. (wheat, quartz etc.)
    # This gives each survey approx. 30% chance to discover a strategic resources, and a 70% to discover a non-strategic resource.
    categories: '{common_dirt, 25, 2, DIRT},{gravel, 100, 1, GRAVEL},{sand, 100, 2, SAND},{common_rocks, 100, 2, STONE, COBBLESTONE},{uncommon_rocks, 100, 1, DIORITE, ANDESITE, GRANITE},{terracotta, 100, 0.5, TERRACOTTA},{quartz, 100, 0.25, QUARTZ_BLOCK},{prismarine, 100, 0.125, PRISMARINE},{obsidian, 100, 0.125, OBSIDIAN},{clay, 100, 1, CLAY_BALL},{ice, 25, 1, ICE},{snow, 25, 1, SNOWBALL},{coal, 200, 1, COAL},{iron, 200, 0.5, RAW_IRON},{gold, 200, 0.25, GOLD_INGOT},{emeralds, 200, 0.25, EMERALD},{diamonds, 200, 0.125, DIAMOND},{redstone, 100, 1, REDSTONE},{ancient_debris, 200, 0.03125, ANCIENT_DEBRIS},{wood, 200, 2, OAK_LOG, SPRUCE_LOG, BIRCH_LOG, JUNGLE_LOG, ACACIA_LOG, DARK_OAK_LOG, OAK_WOOD, SPRUCE_WOOD, BIRCH_WOOD, JUNGLE_WOOD, ACACIA_WOOD, DARK_OAK_WOOD},{wheat, 100, 1, WHEAT},{carrots, 100, 1, CARROT},{potatoes, 100, 1, POTATO},{beetroots, 100, 1, BEETROOT},{pumpkins, 100, 1, PUMPKIN_SEEDS},{melon_slices, 100, 1, MELON_SLICE},{cocoa_plants, 100, 1, COCOA_BEANS},{kelp, 100, 1, KELP},{bamboo, 100, 1, BAMBOO},{cactus, 100, 1, CACTUS},{mushrooms, 100, 1, BROWN_MUSHROOM, RED_MUSHROOM},{apple_trees, 100, 0.125, APPLE},{vines, 100, 0.25, VINE},{fish, 100, 1, COD, SALMON, PUFFERFISH, TROPICAL_FISH},{wool, 100, 0.5, WHITE_WOOL},{gunpowder, 200, 0.25, GUNPOWDER},{string, 100, 0.25, STRING},{spider_eyes, 100, 0.25, SPIDER_EYE},{slime, 100, 0.25, SLIME_BALL},{feathers, 100, 0.25, FEATHER},{leather, 100, 0.25, LEATHER},{rabbit_hide, 100, 0.25, RABBIT_HIDE},{rotten_flesh, 100, 1, ROTTEN_FLESH}{bones, 100, 0.5, BONE},{pork, 100, 0.25, PORKCHOP},{mutton, 100, 0.25, MUTTON},{beef, 100, 0.25, BEEF},{chickens, 100, 0.25, CHICKEN},{ender_pearls, 100, 0.125, ENDER_PEARL}'

  language:

    # If you have the LanguageUtils plugin installed, materials will be automatically translated into this locale/language.
    materials_display_language: zh_cn
Goosius1 commented 3 years ago

The issue seems to related to the PlayerExtractionLimitsController class, which imports the following 2 items:

import net.md_5.bungee.api.ChatMessageType;
import net.md_5.bungee.api.chat.TextComponent;

Both of these classes are involved in sending action bar messages

Goosius1 commented 3 years ago

What MC server version do you have?

noisereactz1 commented 3 years ago

What MC server version do you have?

bukkit 1.16.5

towny + townychat overall is working perfectly on 1.16.5

Goosius1 commented 3 years ago
Goosius1 commented 3 years ago

Technical note:

Goosius1 commented 3 years ago
noisereactz1 commented 3 years ago

im gonna try it :) i am using craftbukkit-1.16.5.jar

noisereactz1 commented 3 years ago

[23:08:49 INFO]: [TownyResources] TownyResources loaded successfully.

Thank you Goosius <3

Goosius1 commented 3 years ago

Np.

Ok so. Technical note: