Fixed NPE at stats update.

Contributed by Sahar.
This commit is contained in:
MobiusDevelopment
2019-11-22 17:20:28 +00:00
parent 88a3b5b381
commit 9c9220457b
17 changed files with 36 additions and 19 deletions

View File

@@ -4177,11 +4177,12 @@ public class PlayerInstance extends Playable
final boolean needCpUpdate = needCpUpdate();
final boolean needHpUpdate = needHpUpdate();
final Party party = getParty();
// Check if a party is in progress and party window update is usefull
if (isInParty() && (needCpUpdate || needHpUpdate || needMpUpdate()))
if ((party != null) && (needCpUpdate || needHpUpdate || needMpUpdate()))
{
_party.broadcastToPartyMembers(this, new PartySmallWindowUpdate(this));
party.broadcastToPartyMembers(this, new PartySmallWindowUpdate(this));
}
if (_inOlympiadMode && _OlympiadStart && (needCpUpdate || needHpUpdate))