Improve compatibility with some economy plugins (hopefully) #385

This commit is contained in:
BuildTools
2016-01-24 20:07:09 +01:00
committed by Olof Larsson
parent 6bc16d25b1
commit f77750fc91
6 changed files with 42 additions and 36 deletions

View File

@@ -13,7 +13,7 @@ public abstract class EventFactionsAbstractSender extends EventMassiveCore
private final CommandSender sender;
public CommandSender getSender() { return this.sender; }
public MPlayer getMSender() { return this.sender == null ? null : MPlayer.get(this.sender); }
public MPlayer getMPlayer() { return this.sender == null ? null : MPlayer.get(this.sender); }
// -------------------------------------------- //
// CONSTRUCT
@@ -29,4 +29,5 @@ public abstract class EventFactionsAbstractSender extends EventMassiveCore
super(async);
this.sender = sender;
}
}

View File

@@ -60,7 +60,7 @@ public class EventFactionsChunksChange extends EventFactionsAbstractSender
this.oldChunkFaction = Collections.unmodifiableMap(BoardColl.getChunkFaction(chunks));
this.oldFactionChunks = Collections.unmodifiableMap(MUtil.reverseIndex(this.oldChunkFaction));
MPlayer msender = this.getMSender();
MPlayer msender = this.getMPlayer();
Faction self = null;
if (msender != null) self = msender.getFaction();
Map<PS, EventFactionsChunkChangeType> currentChunkType = new LinkedHashMap<PS, EventFactionsChunkChangeType>();