KubeJS

KubeJS

69M Downloads

The event.removeSpawnsByID do not seem to be functional

Demiosis opened this issue ยท 2 comments

commented

I created a little script to test if i could disabled the creepers from spawning I changed it from .txt to .js then putted it into:kubejs/startup_scripts/ as this bit of the wiki suggested:

https://mods.latvian.dev/books/kubejs/page/worldgenaddeventjs

I am using fabric-api-0.37.1+1.16.jar for Mc 1.16.5 The script that I added to my server in question:

onEvent('worldgen.remove', event => {

// test by disabling a vanilla mob

event.removeSpawnsByID(spawns => {
spawns.entities.values = [
'minecraft:creeper'
]
})
})

(My script may be wrong though... But I saw another person that seemed to know what he was doing who was experiencing the same problem: redgoblin88. Bear in mind that I am already able to modify mobs spawn list in the Age of exile mod's randomly generated dungeons so im certain the mod is properly installed)

I reffered to: https://mods.latvian.dev/books/kubejs/page/worldgenremoveeventjs to build my lill script btw.

commented

Is this still an issue in 1.18.2?

commented

Closing due to lack of a response, if this is still an issue in 1.18.2 or 1.19, feel free to reopen