net.minecraft.entity.mob.ZombieEntity Java Examples
The following examples show how to use
net.minecraft.entity.mob.ZombieEntity.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: MummyEntityRenderer.java From the-hallow with MIT License | 4 votes |
@Override protected void scale(ZombieEntity entity, MatrixStack matrixStack, float f1) { super.scale(entity, matrixStack, f1 * 1.2f); }
Example #2
Source File: MummyEntityRenderer.java From the-hallow with MIT License | 4 votes |
@Override public Identifier getTexture(ZombieEntity entity) { return SKIN; }
Example #3
Source File: ZombieEntityMixin.java From the-hallow with MIT License | 4 votes |
@Redirect(method = "initialize(Lnet/minecraft/world/IWorld;Lnet/minecraft/world/LocalDifficulty;Lnet/minecraft/entity/SpawnType;Lnet/minecraft/entity/EntityData;Lnet/minecraft/nbt/CompoundTag;)Lnet/minecraft/entity/EntityData;", at = @At(value = "INVOKE", target = "Lnet/minecraft/entity/mob/ZombieEntity;getEquippedStack(Lnet/minecraft/entity/EquipmentSlot;)Lnet/minecraft/item/ItemStack;")) private ItemStack getStack(ZombieEntity zombieEntity, EquipmentSlot equipmentSlot) { return MixinHelpers.getEquippedOrPumpkin(zombieEntity, equipmentSlot); }
Example #4
Source File: Protocol_1_12_2.java From multiconnect with MIT License | 4 votes |
@Override public boolean acceptEntityData(Class<? extends Entity> clazz, TrackedData<?> data) { if (!super.acceptEntityData(clazz, data)) return false; if (clazz == AreaEffectCloudEntity.class && data == AreaEffectCloudEntityAccessor.getParticleId()) { DataTrackerManager.registerOldTrackedData(AreaEffectCloudEntity.class, OLD_AREA_EFFECT_CLOUD_PARTICLE_ID, Registry.PARTICLE_TYPE.getRawId(ParticleTypes.ENTITY_EFFECT), (entity, val) -> { ParticleType<?> type = Registry.PARTICLE_TYPE.get(val); if (type == null) type = ParticleTypes.ENTITY_EFFECT; setParticleType(entity, type); }); DataTrackerManager.registerOldTrackedData(AreaEffectCloudEntity.class, OLD_AREA_EFFECT_CLOUD_PARTICLE_PARAM1, 0, (entity, val) -> { ((IAreaEffectCloudEntity) entity).multiconnect_setParam1(val); setParticleType(entity, entity.getParticleType().getType()); }); DataTrackerManager.registerOldTrackedData(AreaEffectCloudEntity.class, OLD_AREA_EFFECT_CLOUD_PARTICLE_PARAM2, 0, (entity, val) -> { ((IAreaEffectCloudEntity) entity).multiconnect_setParam2(val); setParticleType(entity, entity.getParticleType().getType()); }); return false; } if (clazz == Entity.class && data == EntityAccessor.getCustomName()) { DataTrackerManager.registerOldTrackedData(Entity.class, OLD_CUSTOM_NAME, "", (entity, val) -> entity.setCustomName(val.isEmpty() ? null : new LiteralText(val))); return false; } if (clazz == BoatEntity.class && data == BoatEntityAccessor.getBubbleWobbleTicks()) { return false; } if (clazz == ZombieEntity.class && data == ZombieEntityAccessor.getConvertingInWater()) { return false; } if (clazz == AbstractMinecartEntity.class) { TrackedData<Integer> displayTile = AbstractMinecartEntityAccessor.getCustomBlockId(); if (data == displayTile) { DataTrackerManager.registerOldTrackedData(AbstractMinecartEntity.class, OLD_MINECART_DISPLAY_TILE, 0, (entity, val) -> entity.getDataTracker().set(displayTile, Blocks_1_12_2.convertToStateRegistryId(val))); return false; } } if (clazz == WolfEntity.class) { TrackedData<Integer> collarColor = WolfEntityAccessor.getCollarColor(); if (data == collarColor) { DataTrackerManager.registerOldTrackedData(WolfEntity.class, OLD_WOLF_COLLAR_COLOR, 1, (entity, val) -> entity.getDataTracker().set(collarColor, 15 - val)); return false; } } return true; }