Party loot & Mob Skill cooldown patch

Fixed an issue with party loot that started from recent updates.
Implemented party loot permission update for players ingressing a party.
Fixed mob skills not using cooldown time.
This commit is contained in:
ronancpl
2019-04-06 23:57:27 -03:00
parent ee23a9405a
commit 0b80389971
6 changed files with 70 additions and 28 deletions

View File

@@ -1480,15 +1480,25 @@ public class MapleCharacter extends AbstractMapleCharacterObject {
partyLeaver = this;
}
int partyId = exPartyMembers != null ? 0 : this.getPartyId();
MapleMap map = this.getMap();
List<MapleMapItem> partyItems = null;
int partyId = exPartyMembers != null ? -1 : this.getPartyId();
for(WeakReference<MapleMap> mapRef : mapids) {
MapleMap mapObj = mapRef.get();
if(mapObj != null) {
mapObj.updatePlayerItemDrops(partyId, id, partyMembers, partyLeaver);
List<MapleMapItem> partyMapItems = mapObj.updatePlayerItemDropsToParty(partyId, id, partyMembers, partyLeaver);
if (map.hashCode() == mapObj.hashCode()) {
partyItems = partyMapItems;
}
}
}
if (partyItems != null && exPartyMembers == null) {
map.updatePartyItemDropsToNewcomer(this, partyItems);
}
updatePartyTownDoors(party, this, partyLeaver, partyMembers);
}