ericgrandt / TotalEconomy

All in one economy plugin for Minecraft.
https://ericgrandt.github.io/TotalEconomy/
MIT License
32 stars 33 forks source link

Mobs with space in the names don't count for kills #358

Closed IAmDoot closed 4 years ago

IAmDoot commented 4 years ago

Minecraft Version: 1.12.2 SpongeAPI: 7.1.0-57b017778 Sponge Version: 1.12.2-7.1.7-SNAPSHOT Sponge Forge: 1.12.2-2838-7.1.7-RC3926 Forge Version: 14.23.5.2838 Total Economy Version: 1.8.1

Description of issue

All mobs that have a space in the name (or an underscore in the configs) don't award anything for killing.

Console errors

N/A, nothing comes up in console

Steps to reproduce

Take the warrior job, and kill any mob set up in the config file that has a space/underscore (cave_spider, for example). All mobs that don't have a space/underscore work fine. Changing the name to "cave spider" and ""minecraft:cave_spider"" have no effect.

Related Configuration Files

https://gist.github.com/IAmDoot/81109ab0745fb2680cd82076f8aa6ae5

MarkL4YG commented 4 years ago

Hi, TotalEconomy uses the entity type name to match the killed entity to your job set configuration.
If that type name contains characters like a space, that means it needs to be quoted in your configuration according to the HOCON specification for unquoted strings. That means that cave spider would become "cave spider" { in your job set configuration.

If you still have issues configuring this, consider turning on the entity-kill-info option for yourself. That will make TE display the exact provided type name for you. That's the value that goes into your config.
The command for toggling this option is /job toggle entity-kill-info.

Of course, feel free to ask if you have any further questions or are unable to resolve your issue.

IAmDoot commented 4 years ago

Thank you so much! Toggling the option and then using the names from that worked perfectly.

MarkL4YG commented 4 years ago

Glad to have helped :)