Compare commits

..

No commits in common. "647b1aa0ac92e5b29eb388998096d1ae516f9a11" and "525c247bf7fa89e49862b0362e45755a4273a2e3" have entirely different histories.

View file

@ -1,26 +0,0 @@
package xyz.nearmisses.patience.mc_rebalance.mixin.mob;
import net.minecraft.world.damagesource.DamageSource;
import net.minecraft.world.damagesource.DamageSources;
import net.minecraft.world.entity.EntityType;
import net.minecraft.world.entity.LivingEntity;
import net.minecraft.world.entity.Mob;
import net.minecraft.world.entity.boss.enderdragon.EnderDragon;
import net.minecraft.world.entity.monster.Enemy;
import net.minecraft.world.level.Level;
import org.spongepowered.asm.mixin.Mixin;
import org.spongepowered.asm.mixin.injection.At;
import org.spongepowered.asm.mixin.injection.Redirect;
@Mixin(EnderDragon.class)
public class EnderDragonHitRateCap extends Mob implements Enemy {
protected EnderDragonHitRateCap(EntityType<? extends Mob> entityType, Level level) {
super(entityType, level);
}
@Redirect(method = "hurt(Ljava/util/List;)V", at=@At(value="INVOKE", target = "Lnet/minecraft/world/damagesource/DamageSources;mobAttack(Lnet/minecraft/world/entity/LivingEntity;)Lnet/minecraft/world/damagesource/DamageSource;"))
private DamageSource hurt(DamageSources instance, LivingEntity livingEntity){
return this.damageSources().dragonBreath();
}
}