Project MMO

Project MMO

10M Downloads

[1.19.2] Mod mobs do not respect datapacks for certain XP Reward methods

NewbulaCo opened this issue ยท 2 comments

commented

Describe the bug
Using datapacks, I added reward values to minecraft:bow for these XP value methods: DEAL_RANGED_DAMAGE, RANGED_TO_MOBS, RANGED_TO_PLAYERS, RANGED TO ANIMALS. Default and Auto values were off. However, only vanilla mobs (minecraft:skeleton, minecraft:creeper) will respect the datapack and grant XP in those skills (zombies dont work either but I made a seperate report for that).

I tested with several different mods that add mobs, and the result is the same, they give no XP with those methods, although they do respect the server config in regards to reward XP. I don't know if other XP value methods share this behavior.

Mods tested:
Ars Nouveau
MonsterPlus
Quark
Alex's Mobs

Expected behavior
Non-vanilla mobs should reward XP values based on datapacks.

To Reproduce
Steps to reproduce the behavior:

  1. Set auto values to false, and set default XP for Archery to 0.0
  2. Use this datapack for minecraft:bow in this path: datapacks/packname/data/minecraft/pmmo/items/bow.json

{"override":true, "xp_values":{ "DEAL_RANGED_DAMAGE":{ "archery": 2, "gunslinging": 2, "slayer": 2 }, "RANGED_TO_MOBS":{ "archery": 2, "gunslinging": 2, "slayer": 2 }, "RANGED_TO_PLAYERS":{ "archery": 2, "gunslinging": 2, "slayer": 2 }, "RANGED_TO_ANIMALS":{ "archery": 2, "gunslinging": 2, "slayer": 2 } } }

  1. Modded mobs will not generate XP reward values when using the bow, but vanilla mobs will.

Versions:

  • Minecraft: 1.19.2
  • PMMO 3.1.2
commented

This will be because those creatures don't have the appropriate tags.

In your datapack will be a pmmo/tags/entity_types/ folder. You can add new critters to the various types.

For example:

Adding these two monsters to mobs.json

{
  "values": [
    {"id":"creeperoverhaul:cave_creeper","required":false},
    {"id":"minecraft:ghast","required":false}
  ]
}
commented

@NewbulaCo did the above suggestion about tags resolve your issue?