Caverns & Chasms

Caverns & Chasms

491k Downloads

Suggestion: Config option to disable Glare

Closed this issue ยท 3 comments

commented

I tried to disable Glare spawning using a datapack because I already have another mod that includes Glare, and I don't want duplicates. But every time I try to modify it, it causes a crash.
Is it possible to have a config option to disable its spawning in a future version?

https://github.com/team-abnormals/caverns-and-chasms/blob/1.20.x/src/generated/resources/data/caverns_and_chasms/forge/biome_modifier/add_spawn/glare.json

Below is the configuration I attempted to change. Please let me know if I did something wrong.

{
  "type": "forge:add_spawns",
  "biomes": "#caverns_and_chasms:has_animal/glare",
  "spawners": [
    {
      "type": "caverns_and_chasms:glare",
      "weight": 0,
      "minCount": 0,
      "maxCount": 0
    }
  ]
}
commented

No, Mojang keeps converting more and more things to json based and its unfortunately just the future, tying configs in with jsons is hard to maintain and often times has issues.

The issue with your datapack is possibly a file format/location issue, but I believe spawns also break when everything is set to 0 like that, since it doesn't make logical sense - just don't add the spawn. You can just replace the file with an empty bracket/json or empty out the caverns_and_chasms:has_animal/glare tag.

commented

No, Mojang keeps converting more and more things to json based and its unfortunately just the future, tying configs in with jsons is hard to maintain and often times has issues.

The issue with your datapack is possibly a file format/location issue, but I believe spawns also break when everything is set to 0 like that, since it doesn't make logical sense - just don't add the spawn. You can just replace the file with an empty bracket/json or empty out the caverns_and_chasms:has_animal/glare tag.

I didn't mean to be annoying.
But I tried emty this one with this

{
  "values": [
    
  ]
} 

but it seems its still spawning
Image

and if I replace the file with an empty tag like this

{
  "type": "forge:add_spawns",
  "biomes": "",
  "spawners": {
    "type": "caverns_and_chasms:glare",
    "maxCount": 1,
    "minCount": 1,
    "weight": 20
  }
}

this is what happen when I load world

Image

it can even crash if I created new world.
I'm honest not sure which step I did wrong.

commented

Yes because your json is invalid, it still has to be a valid json. Change it to a different tag that exists but has no entries