Change spell chat messages to hotbar toast notifications
This commit is contained in:
@@ -143,9 +143,9 @@ public class LightningWeb extends SpellRay {
|
||||
private void electrocute(World world, Entity caster, Entity origin, Entity target, float damage, int ticksInUse){
|
||||
|
||||
if(MagicDamage.isEntityImmune(DamageType.SHOCK, target)){
|
||||
if(!world.isRemote && ticksInUse == 1)
|
||||
caster.sendMessage(new TextComponentTranslation("spell.resist",
|
||||
target.getName(), this.getNameForTranslationFormatted()));
|
||||
if(!world.isRemote && ticksInUse == 1 && caster instanceof EntityPlayer)
|
||||
((EntityPlayer)caster).sendStatusMessage(new TextComponentTranslation("spell.resist", target.getName(),
|
||||
this.getNameForTranslationFormatted()), true);
|
||||
}else{
|
||||
WizardryUtilities.attackEntityWithoutKnockback(target,
|
||||
MagicDamage.causeDirectMagicDamage(caster, DamageType.SHOCK), damage);
|
||||
|
||||
Reference in New Issue
Block a user