Cold Sweat

Cold Sweat

5M Downloads

[Undocumented change?] 1.21.1 Datapack entity temp parameters with NBT doesn't work as of 2.4-b05a

moninformateur opened this issue ยท 3 comments

commented

Mod loader: Neoforge v21.1.205
Mod version: Cold Sweat 1.21.1-2.4-b05a

Sorry in advance if the change was documented somewhere, but I can't find anything anywhere in the changelogs or in the source code that would indicate a breaking change toward previous entity_temp jsons.

The log confirms that the entity temp is loaded in both versions.

Example of a file in my datapack : datapack_name\data\zyx\cold_sweat\entity\entity_temp\charmander.json :

{
    "required_mods": [
        "cobblemon"
    ],
    "entity": {
        "entity": [
            "cobblemon:pokemon"
        ],
        "nbt": {
            "Pokemon": {
                "Species": "cobblemon:charmander"
            }
        }
    },
    "temperature": 45.0,
    "units": "c",
    "range": 8.0,
    "affects_self": true
}

Behavior as of 2.4-b04b

Working as expected. Being around a charmander raises your temperature.

Image
Behavior as of 2.4-b05a

Being around a charmander does not change your temperature.

Image
commented

I haven't tried it out yet, but I think I know your issue. The formatting for "entity" is slightly off (the inner "entity" is actually "entities"). Because of that, the JSON interpreter can't find "cobblemon:pokemon" and assumes you didn't define a list of entities.

In the previous version, not specifying a list of entities makes it apply to ALL entities in the game, which happened to work out fine in your case since there was still the NBT check. However in this version, it only applies the config to all entities if you put a "*" in the list of entities.

commented

It was really that simple, small oversight from my part! Thank you so much for your mod and for taking the time to answer!

commented

You're welcome! Happy modding :)