Browse Source

temporarily disable box limits

lakebane-strongholds
FatBoy-DOTC 3 months ago
parent
commit
ea0cefd3f9
  1. 38
      src/engine/objects/PlayerCharacter.java

38
src/engine/objects/PlayerCharacter.java

@ -4929,24 +4929,26 @@ public class PlayerCharacter extends AbstractCharacter {
} }
public static boolean checkIfBoxed(PlayerCharacter player){ public static boolean checkIfBoxed(PlayerCharacter player){
try { //REMOVE BEFORE LAUNCH -TEMP DISABLE OF BOX LIMIT
String machineID = player.getClientConnection().machineID; return false;
ArrayList<PlayerCharacter> sameMachine = new ArrayList<>(); //try {
for (PlayerCharacter pc : SessionManager.getAllActivePlayerCharacters()) { // String machineID = player.getClientConnection().machineID;
if (!pc.equals(player) && pc.isActive && pc.isEnteredWorld() && pc.getClientConnection().machineID.equals(machineID)) { // ArrayList<PlayerCharacter> sameMachine = new ArrayList<>();
sameMachine.add(pc); // for (PlayerCharacter pc : SessionManager.getAllActivePlayerCharacters()) {
} // if (!pc.equals(player) && pc.isActive && pc.isEnteredWorld() && pc.getClientConnection().machineID.equals(machineID)) {
} // sameMachine.add(pc);
// }
boolean boxed = false; // }
for (PlayerCharacter pc : sameMachine)
if (!pc.isBoxed) // boolean boxed = false;
boxed = true; // for (PlayerCharacter pc : sameMachine)
// if (!pc.isBoxed)
return boxed; // boxed = true;
}catch(Exception e){
return false; // return boxed;
} //}catch(Exception e){
// return false;
//}
} }
@Override @Override
public void updateFlight() { public void updateFlight() {

Loading…
Cancel
Save