2018-02-15 18:49:01 -08:00
|
|
|
package WayofTime.bloodmagic.util;
|
2015-10-29 20:22:14 -07:00
|
|
|
|
2016-03-17 13:00:44 -07:00
|
|
|
import WayofTime.bloodmagic.util.helper.TextHelper;
|
2019-09-22 12:55:43 -07:00
|
|
|
import net.minecraft.entity.LivingEntity;
|
2015-10-29 20:22:14 -07:00
|
|
|
import net.minecraft.util.DamageSource;
|
2016-03-17 13:00:44 -07:00
|
|
|
import net.minecraft.util.text.ITextComponent;
|
2019-09-22 12:55:43 -07:00
|
|
|
import net.minecraft.util.text.StringTextComponent;
|
2015-10-29 20:22:14 -07:00
|
|
|
|
2017-08-15 21:30:48 -07:00
|
|
|
public class DamageSourceBloodMagic extends DamageSource {
|
2018-03-17 22:30:14 -07:00
|
|
|
|
|
|
|
public static final DamageSourceBloodMagic INSTANCE = new DamageSourceBloodMagic();
|
|
|
|
|
2017-08-15 21:30:48 -07:00
|
|
|
public DamageSourceBloodMagic() {
|
2015-10-29 20:22:14 -07:00
|
|
|
super("bloodMagic");
|
|
|
|
|
|
|
|
setDamageBypassesArmor();
|
2015-12-01 23:35:09 -08:00
|
|
|
setDamageIsAbsolute();
|
|
|
|
}
|
|
|
|
|
|
|
|
@Override
|
2019-09-22 12:55:43 -07:00
|
|
|
public ITextComponent getDeathMessage(LivingEntity livingBase) {
|
|
|
|
return new StringTextComponent(TextHelper.localizeEffect("chat.bloodmagic.damageSource", livingBase.getName()));
|
2015-10-29 20:22:14 -07:00
|
|
|
}
|
|
|
|
}
|