Open tequt opened 2 years ago
Which version are you using? Depend on the version, you might need to configure mobFilter differently.
I am using the 1.12.2. version of the mod.
What mod are those mobs coming from?
I think there are two possible causes for this issue:
These mobs are from the mods Primitive Mobs and Thaumcraft, and they spawn just like any other hostile mob such as the Zombie or the Creeper. I tried a variation where the space between their names is an actual white space and a underscore and neither of these work, my guess is that there's a specific syntax with Regex so the error is in the 1st option.
The second option however cannot be as the mod worked as intended when I did not have the blacklist (AKA. "InvertedMobFilter" wasn't to true) enabled and creatures from Primitive Mobs did not spawn on the surface.
The AngryZombie is referred as "BrainyZombie" in Thaumcraft's code. Those creepers and skeleton warrior are referred as "rocket_creeper", "festive_creeper", "support_creeper", "skeleton_warrior" in PrimitiveMobs' code.
I see, so your config's filters are literally checking for the mobs' IDs and not the mob's display names. Correct?
Yes, in old versions, those ids are used when spawning those entities.
In newer versions, you will need formal registry ids such as "minecraft:slime".
Which one of these things does your Regex actually look for? I can't figure it out.
Here's the code I've managed to write from the javascript flavour of Regular Expressions' syntax cheatsheets as a foundation. What syntax do you actually use so I can properly configure the .json?
{
"Disabled": false,
"Living": false,
"Mob": true,
"Animal": false,
"Tameable": false,
"Checking_LightLevel": true,
"Sunny": false,
"Raining": false,
"Thundering": false,
"Day": false,
"Night": false,
"InvertedMobFilter": true,
"InvertedDimensionFilter": false,
"InvertedLightLevelChecking": false,
"mobFilter": "(([a-z]{0,}spider)|([a-z]{0,}.spider))|(([a-z]{0,}creeper)|([a-z]{0,}.creeper))|(([a-z]{0,}zombie)|([a-z]{0,}.zombie))|(([a-z]{0,}skeleton)|([a-z]{0,}.skeleton))",
"dimensionFilter": "(\\bthe_end\\b)|(\\bthe_nether\\b)",
"LightLevel": 0,
"MoonPhase": 0,
"DisabledUnderBloodmoon": false,
"DisabledWhenSunny": false,
"DisabledWhenRaining": false,
"DisabledWhenThundering": false,
"DisabledWhenDay": false,
"DisabledWhenNight": false
}
In 1.12.2, the string my regex looking for is just some hardcoded magic string, there is no regulation at that time, modders can use whatever they want, you need to look into their code. Vanilla use something like 'Creeper', 'Zombie'.
I think you just need to use '\\' instead of single '\'.
Here is my config
Essentially, with InvertedMobFilter set to true and mobs written into the mobFilter, it's supposed to blacklist the mobs written into the filter. But only the mobs that only have one word names such as Creeper for example are managing to be blacklisted, mobs that have names with spaces and such are not being recognized. They still manage to spawn on the surface (circled are the blacklisted mobs):