Changed addExpAndSp methods to synchronized.

This commit is contained in:
MobiusDevelopment
2022-05-23 21:55:33 +00:00
parent 42039fadd5
commit 9d7d7f4db3
89 changed files with 115 additions and 115 deletions

View File

@@ -1187,7 +1187,7 @@ public abstract class Creature extends WorldObject
return true;
}
public void addExpAndSp(int addToExp, int addToSp)
public synchronized void addExpAndSp(int addToExp, int addToSp)
{
}

View File

@@ -336,7 +336,7 @@ public class Player extends Creature
}
@Override
public void addExpAndSp(int addToExp, int addToSp)
public synchronized void addExpAndSp(int addToExp, int addToSp)
{
_exp += addToExp;
_sp += addToSp;

View File

@@ -244,7 +244,7 @@ public class Pet extends Creature
}
@Override
public void addExpAndSp(int addToExp, int addToSp)
public synchronized void addExpAndSp(int addToExp, int addToSp)
{
_exp += addToExp;
_sp += addToSp;