Arena System
This commit is contained in:
@@ -20,6 +20,9 @@ public class ArenaManager {
|
|||||||
lastExecution = System.currentTimeMillis();
|
lastExecution = System.currentTimeMillis();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(activeArenas.isEmpty() && playerQueue.isEmpty())
|
||||||
|
return;
|
||||||
|
|
||||||
Iterator<Arena> iterator = activeArenas.iterator();
|
Iterator<Arena> iterator = activeArenas.iterator();
|
||||||
|
|
||||||
while (iterator.hasNext()) {
|
while (iterator.hasNext()) {
|
||||||
|
|||||||
@@ -114,8 +114,16 @@ public enum SimulationManager {
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
if ((_cityPulseTime != 0) && (System.currentTimeMillis() > _cityPulseTime)) {
|
if ((_cityPulseTime != 0) && (System.currentTimeMillis() > _cityPulseTime)) {
|
||||||
pulseCities();
|
try {
|
||||||
ArenaManager.pulseArenas();
|
pulseCities();
|
||||||
|
}catch(Exception e){
|
||||||
|
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
ArenaManager.pulseArenas();
|
||||||
|
}catch(Exception e){
|
||||||
|
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
Logger.error(
|
Logger.error(
|
||||||
|
|||||||
@@ -203,16 +203,16 @@ public class Contract extends AbstractGameObject {
|
|||||||
|
|
||||||
switch(optionId){
|
switch(optionId){
|
||||||
case 15020431:
|
case 15020431:
|
||||||
if(pc.isBoxed){
|
//if(pc.isBoxed){
|
||||||
ChatManager.chatSystemInfo(pc, "You Cannot Join The Que, You Are Boxed");
|
// ChatManager.chatSystemInfo(pc, "You Cannot Join The Que, You Are Boxed");
|
||||||
}else {
|
//}else {
|
||||||
if (ArenaManager.playerQueue.contains(pc)) {
|
if (ArenaManager.playerQueue.contains(pc)) {
|
||||||
ChatManager.chatSystemInfo(pc, "You Are Already In The Arena Que");
|
ChatManager.chatSystemInfo(pc, "You Are Already In The Arena Que");
|
||||||
} else {
|
} else {
|
||||||
ArenaManager.joinQueue(pc);
|
ArenaManager.joinQueue(pc);
|
||||||
ChatManager.chatSystemInfo(pc, "You Have Joined The Arena Que");
|
ChatManager.chatSystemInfo(pc, "You Have Joined The Arena Que");
|
||||||
}
|
}
|
||||||
}
|
//}
|
||||||
break;
|
break;
|
||||||
case 15020432:
|
case 15020432:
|
||||||
if(ArenaManager.playerQueue.contains(pc)) {
|
if(ArenaManager.playerQueue.contains(pc)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user