Wolf wolf2 = (Wolf) entity2; wolf2.setOwner(p); wolf2.setTarget(null); wolf2.setAngry(false);