Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

[SOLVED][1.16.5] Entity naturally spawn!


TonyOneG112
 Share

Recommended Posts

Hi, I'm making a custom Entity, already fix it all, i can spawn it by commands but idk how to create spawnegg, i'm working with deferred register and I want that mob spawns naturally in biomes, but i don't see any way to add my monster to biomemaker class etc, any tip? thank u btw.

1. I'm using tthis to try to spawn it (I know 500 it's too much), problem is: Pigs are spawning, not my mob... But on dungeons it's spawning okay.

2. Maybe a more "natural" codding way to spawn it naturally?

3. Really thanks for ur patience, I post a lot, sorry.

  private void setup(final FMLCommonSetupEvent event) {
        // some preinit code
        LOGGER.info("HELLO FROM PREINIT");

        EntitySpawnPlacementRegistry.register(VERRUCT.get(), EntitySpawnPlacementRegistry.PlacementType.ON_GROUND, Heightmap.Type.MOTION_BLOCKING_NO_LEAVES,
                MonsterEntity::checkMonsterSpawnRules);
        DungeonHooks.addDungeonMob(VERRUCT.get(), 500);
    @SubscribeEvent
    public static void onBiomeLoad(final BiomeLoadingEvent event){
        if (event.getName() == null){
            return;
        }

          MobSpawnInfoBuilder spawns = event.getSpawns();

            if (event.getCategory()!=(Biome.Category.OCEAN)) {
                spawns.addSpawn(EntityClassification.MONSTER, new MobSpawnInfo.Spawners(VERRUCT.get(), 500, 1, 1));
            }

    }
Edited by TonyOneG112
Solved, close thread
Link to comment
Share on other sites

[18:32:34] [Server thread/WARN] [ne.mi.co.ForgeConfigSpec/CORE]: Configuration file .\saves\New World (2)\serverconfig\forge-server.toml is not correct. Correcting
[18:32:34] [Server thread/WARN] [ne.mi.co.ForgeConfigSpec/CORE]: Incorrect key server was corrected from null to its default, SimpleCommentedConfig:{

 

Using that code and before I get that. And my mob still don't work.

Link to comment
Share on other sites

bump, now server is creating pigs instead mob, any idea?

 

    @SubscribeEvent
    public static void onBiomeLoad(final BiomeLoadingEvent event){
        if (event.getName() == null){
            return;
        }


            if ((event.getCategory().getName()!=Biome.Category.NETHER.getName()) && (event.getCategory().getName()!=Biome.Category.THEEND.getName())) {
                event.getSpawns().addSpawn(EntityClassification.MONSTER, new MobSpawnInfo.Spawners(VERRUCT.get(), 200, 5, 5)).addMobCharge(VERRUCT.get(), 0.1D, 0.1D);
            LOGGER.info("Welcome to generation!  "+event.getName());
            }

    }

 

Link to comment
Share on other sites

8 minutes ago, TonyOneG112 said:

bump, now server is creating pigs instead mob, any idea?

 

Check your entity renderer. Did you make a custom model? Did you properly place your textures in the resources?

  • Thanks 1
Link to comment
Share on other sites

  • TonyOneG112 changed the title to [SOLVED][1.16.5] Entity naturally spawn!

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share



  • Recently Browsing

    No registered users viewing this page.

  • Posts

    • Time: 12/3/21 11:33 PM Description: Ticking entity java.lang.BootstrapMethodError: java.lang.LinkageError: loader constraint violation: loader (instance of sun/misc/Launcher$AppClassLoader) previously initiated loading for a different type with name "org/apache/logging/log4j/util/MessageSupplier"     at net.minecraftforge.eventbus.EventBus.handleException(EventBus.java:316) ~[eventbus-4.0.0.jar:?] {}     at net.minecraftforge.eventbus.EventBus.post(EventBus.java:307) ~[eventbus-4.0.0.jar:?] {}     at net.minecraftforge.eventbus.EventBus.post(EventBus.java:283) ~[eventbus-4.0.0.jar:?] {}     at net.minecraftforge.event.ForgeEventFactory.gatherCapabilities(ForgeEventFactory.java:597) ~[?:?] {re:mixin,re:classloading}     at net.minecraftforge.event.ForgeEventFactory.gatherCapabilities(ForgeEventFactory.java:591) ~[?:?] {re:mixin,re:classloading}     at net.minecraftforge.common.capabilities.CapabilityProvider.doGatherCapabilities(CapabilityProvider.java:83) ~[?:?] {re:computing_frames,re:mixin,re:classloading}     at net.minecraftforge.common.capabilities.CapabilityProvider.getCapabilities(CapabilityProvider.java:91) ~[?:?] {re:computing_frames,re:mixin,re:classloading}     at net.minecraftforge.common.capabilities.CapabilityProvider.areCapsCompatible(CapabilityProvider.java:103) ~[?:?] {re:computing_frames,re:mixin,re:classloading}     at net.minecraft.item.ItemStack.func_77959_d(ItemStack.java:387) ~[?:?] {re:mixin,xf:fml:forge:filled_map.4,xf:fml:forge:itemstack,re:classloading,xf:fml:forge:filled_map.4,xf:fml:forge:itemstack,pl:mixin:APP:performant.mixins.json:item.ItemStackMixin,pl:mixin:APP:itemfilters-common.mixins.json:ItemStackMixin,pl:mixin:APP:epicfight.mixins.json:MixinItemStack,pl:mixin:A}     at net.minecraft.item.ItemStack.func_77989_b(ItemStack.java:375) ~[?:?] {re:mixin,xf:fml:forge:filled_map.4,xf:fml:forge:itemstack,re:classloading,xf:fml:forge:filled_map.4,xf:fml:forge:itemstack,pl:mixin:APP:performant.mixins.json:item.ItemStackMixin,pl:mixin:APP:itemfilters-common.mixins.json:ItemStackMixin,pl:mixin:APP:epicfight.mixins.json:MixinItemStack,pl:mixin:A}     at net.minecraft.entity.LivingEntity.func_241354_r_(LivingEntity.java:2267) ~[?:?] {re:mixin,pl:accesstransformer:B,re:computing_frames,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:performant.mixins.json:entity.LivingEntityMixin,pl:mixin:APP:citadel.mixins.json:LivingEntityMixin,pl:mixin:APP:environmental.mixins.json:LivingEntityMixin,pl:mixin:APP:allurement.mixins.json:LivingEntityAccessor,pl:mixin:APP:allurement.mixins.json:LivingEntityMixin,pl:mixin:APP:ars_nouveau.mixins.json:ExpInvokerMixin,pl:mixin:APP:ars_nouveau.mixins.json:MixinLivingEntity,pl:mixin:APP:personality.mixins.json:LivingEntityMixin,pl:mixin:APP:assets/botania/botania.mixins.json:AccessorLivingEntity,pl:mixin:A}     at net.minecraft.entity.LivingEntity.func_241353_q_(LivingEntity.java:2239) ~[?:?] {re:mixin,pl:accesstransformer:B,re:computing_frames,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:performant.mixins.json:entity.LivingEntityMixin,pl:mixin:APP:citadel.mixins.json:LivingEntityMixin,pl:mixin:APP:environmental.mixins.json:LivingEntityMixin,pl:mixin:APP:allurement.mixins.json:LivingEntityAccessor,pl:mixin:APP:allurement.mixins.json:LivingEntityMixin,pl:mixin:APP:ars_nouveau.mixins.json:ExpInvokerMixin,pl:mixin:APP:ars_nouveau.mixins.json:MixinLivingEntity,pl:mixin:APP:personality.mixins.json:LivingEntityMixin,pl:mixin:APP:assets/botania/botania.mixins.json:AccessorLivingEntity,pl:mixin:A}     at net.minecraft.entity.LivingEntity.func_70071_h_(LivingEntity.java:2141) ~[?:?] {re:mixin,pl:accesstransformer:B,re:computing_frames,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:performant.mixins.json:entity.LivingEntityMixin,pl:mixin:APP:citadel.mixins.json:LivingEntityMixin,pl:mixin:APP:environmental.mixins.json:LivingEntityMixin,pl:mixin:APP:allurement.mixins.json:LivingEntityAccessor,pl:mixin:APP:allurement.mixins.json:LivingEntityMixin,pl:mixin:APP:ars_nouveau.mixins.json:ExpInvokerMixin,pl:mixin:APP:ars_nouveau.mixins.json:MixinLivingEntity,pl:mixin:APP:personality.mixins.json:LivingEntityMixin,pl:mixin:APP:assets/botania/botania.mixins.json:AccessorLivingEntity,pl:mixin:A}     at net.minecraft.entity.MobEntity.func_70071_h_(MobEntity.java:431) ~[?:?] {re:mixin,pl:accesstransformer:B,xf:OptiFine:default,re:classloading,pl:accesstransformer:B,xf:OptiFine:default,pl:mixin:APP:environmental.mixins.json:MobEntityMixin,pl:mixin:APP:assets/botania/botania.mixins.json:AccessorMobEntity,pl:mixin:APP:performant.mixins.json:entity.MobEntityDespawnMixin,pl:mixin:APP:performant.mixins.json:entity.MobEntityMixin,pl:mixin:A}     at net.minecraft.world.server.ServerWorld.func_217479_a(ServerWorld.java:611) ~[?:?] {re:mixin,pl:accesstransformer:B,re:computing_frames,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:performant.mixins.json:world.ServerWorldBlockUpdateMixin,pl:mixin:APP:abnormals_core.mixins.json:ServerWorldMixin,pl:mixin:APP:performant.mixins.json:world.ServerWorldMixin,pl:mixin:APP:performant.mixins.json:entity.MobServerWorldMixin,pl:mixin:A}     at net.minecraft.world.server.ServerWorld$$Lambda$16565/514282080.accept(Unknown Source) ~[?:?] {}     at net.minecraft.world.World.func_217390_a(World.java:554) ~[?:?] {re:computing_frames,pl:accesstransformer:B,xf:fml:observerlib:coremodmethod,re:mixin,pl:accesstransformer:B,xf:fml:observerlib:coremodmethod,re:classloading,pl:accesstransformer:B,xf:fml:observerlib:coremodmethod,pl:mixin:APP:sereneseasons.mixins.json:MixinWorld,pl:mixin:APP:flywheel.mixins.json:TileWorldHookMixin,pl:mixin:A}     at net.minecraft.world.server.ServerWorld.func_72835_b(ServerWorld.java:404) ~[?:?] {re:mixin,pl:accesstransformer:B,re:computing_frames,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:performant.mixins.json:world.ServerWorldBlockUpdateMixin,pl:mixin:APP:abnormals_core.mixins.json:ServerWorldMixin,pl:mixin:APP:performant.mixins.json:world.ServerWorldMixin,pl:mixin:APP:performant.mixins.json:entity.MobServerWorldMixin,pl:mixin:A}     at net.minecraft.server.MinecraftServer.func_71190_q(MinecraftServer.java:851) ~[?:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:structure_gel.mixins.json:MinecraftServerMixin,pl:mixin:APP:byg.mixins.json:server.MixinMinecraftServer,pl:mixin:APP:marg.mixins.json:MinecraftServerMixin,pl:mixin:A}     at net.minecraft.server.MinecraftServer.func_71217_p(MinecraftServer.java:787) ~[?:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:structure_gel.mixins.json:MinecraftServerMixin,pl:mixin:APP:byg.mixins.json:server.MixinMinecraftServer,pl:mixin:APP:marg.mixins.json:MinecraftServerMixin,pl:mixin:A}     at net.minecraft.server.integrated.IntegratedServer.func_71217_p(IntegratedServer.java:118) ~[?:?] {re:mixin,xf:OptiFine:default,re:classloading,xf:OptiFine:default,pl:mixin:APP:smoothboot.mixins.json:client.IntegratedServerMixin,pl:mixin:A}     at net.minecraft.server.MinecraftServer.func_240802_v_(MinecraftServer.java:642) [?:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:structure_gel.mixins.json:MinecraftServerMixin,pl:mixin:APP:byg.mixins.json:server.MixinMinecraftServer,pl:mixin:APP:marg.mixins.json:MinecraftServerMixin,pl:mixin:A}     at net.minecraft.server.MinecraftServer.func_240783_a_(MinecraftServer.java:232) [?:?] {re:mixin,pl:accesstransformer:B,re:classloading,pl:accesstransformer:B,pl:mixin:APP:structure_gel.mixins.json:MinecraftServerMixin,pl:mixin:APP:byg.mixins.json:server.MixinMinecraftServer,pl:mixin:APP:marg.mixins.json:MinecraftServerMixin,pl:mixin:A}     at net.minecraft.server.MinecraftServer$$Lambda$15673/85323444.run(Unknown Source) [?:?] {}     at java.lang.Thread.run(Thread.java:745) [?:1.8.0_51] {} Caused by: java.lang.LinkageError: loader constraint violation: loader (instance of sun/misc/Launcher$AppClassLoader) previously initiated loading for a different type with name "org/apache/logging/log4j/util/MessageSupplier"     at java.lang.ClassLoader.defineClass1(Native Method) ~[?:1.8.0_51] {}     at java.lang.ClassLoader.defineClass(ClassLoader.java:760) ~[?:1.8.0_51] {}     at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) ~[?:1.8.0_51] {}     at java.net.URLClassLoader.defineClass(URLClassLoader.java:467) ~[?:1.8.0_51] {}     at java.net.URLClassLoader.access$100(URLClassLoader.java:73) ~[?:1.8.0_51] {}     at java.net.URLClassLoader$1.run(URLClassLoader.java:368) ~[?:1.8.0_51] {}     at java.net.URLClassLoader$1.run(URLClassLoader.java:362) ~[?:1.8.0_51] {}     at java.security.AccessController.doPrivileged(Native Method) ~[?:1.8.0_51] {}     at java.net.URLClassLoader.findClass(URLClassLoader.java:361) ~[?:1.8.0_51] {}     at java.lang.ClassLoader.loadClass(ClassLoader.java:424) ~[?:1.8.0_51] {}     at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) ~[?:1.8.0_51] {}     at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ~[?:1.8.0_51] {}     ... 25 more for full report https://pastebin.com/Did3vHvR    
    • you need to create a new ForgeSpawnEggItem and not a SpawnEggItem!
    • this is at the moment not implemented, since vanilla changed the Biome generation, and the old Forge patch doesn't work anymore you need to wait till it's will be added back
    • Please can you HELP instead of posting learn java learn java, PLEASE
    • Please learn basic Java. Do not use SpawnEggItem.
  • Topics

  • Who's Online (See full list)

×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.