Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class AttackWithMoltenGauntletEvent
- {
- public AttackWithMoltenGauntletEvent() { }
- @SubscribeEvent
- public void attackFromGauntlet(LivingHurtEvent event) {
- if (event.getSource().getTrueSource() instanceof PlayerEntity) {
- PlayerEntity playerIn = (PlayerEntity) event.getSource().getTrueSource();
- if (!playerIn.inventory.isEmpty()) {
- if (playerIn.inventory.hasItemStack(new ItemStack(ItemInit.MOLTEN_GAUNTLET.get())))
- if (event.getEntity() instanceof LivingEntity) {
- event.getEntity().setFire(3);
- ProjectDawn.LOGGER.info("FIRE! FIRE!!!");
- }
- }
- }
- else ProjectDawn.LOGGER.info("Huh.... odd ain't it?");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment