mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-25 22:56:45 +01:00
Merge pull request #4220 from FrankHeijden/fix/deathmessages
Update regex to also match colorless healthbar instances
This commit is contained in:
commit
2dfd7fd5a4
@ -27,7 +27,7 @@ public final class MobHealthbarUtils {
|
||||
EntityDamageEvent lastDamageCause = player.getLastDamageCause();
|
||||
String replaceString = lastDamageCause instanceof EntityDamageByEntityEvent ? StringUtils.getPrettyEntityTypeString(((EntityDamageByEntityEvent) lastDamageCause).getDamager().getType()) : "a mob";
|
||||
|
||||
return deathMessage.replaceAll("(?:\u00A7(?:[0-9A-FK-ORa-fk-or]){1}(?:[\u2764\u25A0]{1,10})){1,2}", replaceString);
|
||||
return deathMessage.replaceAll("(?:(\u00A7(?:[0-9A-FK-ORa-fk-or]))*(?:[\u2764\u25A0]{1,10})){1,2}", replaceString);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user