Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Rivello

Members
  • Joined

  • Last visited

  1. For those who might be interested, we came to a solution in this post on the minecraft forums: http://www.minecraftforum.net/forums/mapping-and-modding/minecraft-mods/modification-development/2212981-help-removing-baby-and-armored-zombies In short, "EntityJoinWorldEvent" happens BEFORE the spawn and before the function that set the age and armor of the zombies. For that reason we should remove the armor and set to adult on the "LivingSpawnEvent", which happens AFTER the zombie was already set up and spawned.
  2. Hi folks, I want to make a mod where there are only zombies, not babies neither armored. Only normal "naked" adult zombies. I managed to cancel the spawning of all other mobs, and once I even made all babies grow with setChild(false), but once I started trying cancelling the spawn of the armored ones, nothing else works. I'm completely new to Java and modding, but not to programming. Here is my code (yes, started from the example, lol): It currently just lets zombies spawn (OK) but the babies and armored keeps coming, even if I setCanceled instead of trying to correct them. public class ExampleMod { public static final String MODID = "examplemod"; public static final String VERSION = "1.0"; @EventHandler public void init(FMLInitializationEvent event) { MinecraftForge.EVENT_BUS.register(new SpawnHandler()); } } public class SpawnHandler { @SubscribeEvent public void onEntitySpawn(EntityJoinWorldEvent event) { if( event.entity instanceof EntityMob ) { if ( !(event.entity instanceof EntityZombie) ) { event.setCanceled(true); } else { EntityZombie Mr_zombie = (EntityZombie) event.entity; if ( Mr_zombie.isChild() ) { Mr_zombie.setChild(false); } ItemStack itemstack = Mr_zombie.getEquipmentInSlot(4); if (itemstack != null) { Mr_zombie.setCurrentItemOrArmor(4, (ItemStack)null); } } } } } Help!

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.