Fixed crash on death for servers

Fixed an issue where the client would crash when you died by the Sacrificial Knife when on a server.
This commit is contained in:
WayofTime 2020-10-26 16:08:04 -04:00
parent ec1b0644cb
commit 152525bbe3
6 changed files with 8 additions and 6 deletions

View file

@ -3,8 +3,7 @@ package wayoftime.bloodmagic.util;
import net.minecraft.entity.LivingEntity;
import net.minecraft.util.DamageSource;
import net.minecraft.util.text.ITextComponent;
import net.minecraft.util.text.StringTextComponent;
import wayoftime.bloodmagic.util.helper.TextHelper;
import net.minecraft.util.text.TranslationTextComponent;
public class DamageSourceBloodMagic extends DamageSource
{
@ -21,6 +20,6 @@ public class DamageSourceBloodMagic extends DamageSource
@Override
public ITextComponent getDeathMessage(LivingEntity livingBase)
{
return new StringTextComponent(TextHelper.localizeEffect("chat.bloodmagic.damageSource", livingBase.getName()));
return new TranslationTextComponent("chat.bloodmagic.damageSource", livingBase.getName());
}
}