mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2025-05-08 13:06:02 +08:00
Fix healing skills being able to heal dead characters
This commit is contained in:
parent
513924af7c
commit
dbf2b91d03
@ -126,6 +126,11 @@ public class EntityAvatar extends GameEntity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public float heal(float amount) {
|
public float heal(float amount) {
|
||||||
|
// Do not heal character if they are dead
|
||||||
|
if (!this.isAlive()) {
|
||||||
|
return 0f;
|
||||||
|
}
|
||||||
|
|
||||||
float healed = super.heal(amount);
|
float healed = super.heal(amount);
|
||||||
|
|
||||||
if (healed > 0f) {
|
if (healed > 0f) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user