|
|
@ -5153,7 +5153,6 @@ public class PlayerCharacter extends AbstractCharacter { |
|
|
|
if (this.updateLock.writeLock().tryLock()) { |
|
|
|
if (this.updateLock.writeLock().tryLock()) { |
|
|
|
|
|
|
|
|
|
|
|
this.updateMovementState(); |
|
|
|
this.updateMovementState(); |
|
|
|
|
|
|
|
|
|
|
|
this.updateLocation(); |
|
|
|
this.updateLocation(); |
|
|
|
|
|
|
|
|
|
|
|
try { |
|
|
|
try { |
|
|
@ -5238,7 +5237,7 @@ public class PlayerCharacter extends AbstractCharacter { |
|
|
|
this.timestamps.put("nextReload",System.currentTimeMillis() + 5000L); |
|
|
|
this.timestamps.put("nextReload",System.currentTimeMillis() + 5000L); |
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|
if(this.timestamps.get("nextReload") > System.currentTimeMillis()) |
|
|
|
if(this.timestamps.get("nextReload") > System.currentTimeMillis()) |
|
|
|
updateLoadedPlayers(this); |
|
|
|
this.setDirtyLoad(true); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} catch (Exception e) { |
|
|
|
} catch (Exception e) { |
|
|
@ -5267,16 +5266,6 @@ public class PlayerCharacter extends AbstractCharacter { |
|
|
|
player.isBoxed = false; |
|
|
|
player.isBoxed = false; |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public static void updateLoadedPlayers(PlayerCharacter pc){ |
|
|
|
|
|
|
|
HashSet<AbstractWorldObject> inRange = WorldGrid.getObjectsInRangePartial(pc.loc,MBServerStatics.CHARACTER_LOAD_RANGE,MBServerStatics.MASK_PLAYER); |
|
|
|
|
|
|
|
for(AbstractWorldObject awo : inRange){ |
|
|
|
|
|
|
|
PlayerCharacter toLoad = (PlayerCharacter)awo; |
|
|
|
|
|
|
|
if(toLoad.hidden > pc.seeInvis) |
|
|
|
|
|
|
|
continue; |
|
|
|
|
|
|
|
LoadCharacterMsg lcm = new LoadCharacterMsg(toLoad, PlayerCharacter.hideNonAscii()); |
|
|
|
|
|
|
|
pc.getClientConnection().sendMsg(lcm); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
public static boolean checkIfBoxed(PlayerCharacter player){ |
|
|
|
public static boolean checkIfBoxed(PlayerCharacter player){ |
|
|
|
if(ConfigManager.MB_WORLD_BOXLIMIT.getValue().equals("false")) { |
|
|
|
if(ConfigManager.MB_WORLD_BOXLIMIT.getValue().equals("false")) { |
|
|
|
return false; |
|
|
|
return false; |
|
|
@ -5567,7 +5556,6 @@ public class PlayerCharacter extends AbstractCharacter { |
|
|
|
//mhm.setOmitFromChat(0);
|
|
|
|
//mhm.setOmitFromChat(0);
|
|
|
|
Dispatch dispatch = Dispatch.borrow(this, modifyHealthMsg); |
|
|
|
Dispatch dispatch = Dispatch.borrow(this, modifyHealthMsg); |
|
|
|
DispatchMessage.dispatchMsgDispatch(dispatch, DispatchChannel.PRIMARY); |
|
|
|
DispatchMessage.dispatchMsgDispatch(dispatch, DispatchChannel.PRIMARY); |
|
|
|
this.setDirtyLoad(true); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
public MovementState getMovementState() { |
|
|
|
public MovementState getMovementState() { |
|
|
|