mirror of
https://github.com/ProjectSWGCore/NGECore2.git
synced 2026-07-14 00:02:07 -04:00
Removed debug messages
This commit is contained in:
@@ -266,6 +266,12 @@ public class NGECore {
|
||||
config = DefaultConfig.getConfig();
|
||||
}
|
||||
|
||||
DevLogQueuer devLogQueuer = new DevLogQueuer();
|
||||
|
||||
CharonPacketLogger packetLogger;
|
||||
if (PACKET_DEBUG)
|
||||
packetLogger = new CharonPacketLogger();
|
||||
|
||||
options = new Config();
|
||||
options.setFilePath("options.cfg");
|
||||
if (!(options.loadConfigFile())) {
|
||||
@@ -573,12 +579,6 @@ public class NGECore {
|
||||
//battlefieldService = new BattlefieldService(this);
|
||||
adminService = new AdminService(this);
|
||||
|
||||
DevLogQueuer devLogQueuer = new DevLogQueuer();
|
||||
|
||||
CharonPacketLogger packetLogger;
|
||||
if (PACKET_DEBUG)
|
||||
packetLogger = new CharonPacketLogger();
|
||||
|
||||
didServerCrash = false;
|
||||
System.out.println("Started Server.");
|
||||
cleanupCreatureODB();
|
||||
|
||||
@@ -262,17 +262,13 @@ public class AttackState extends AIState {
|
||||
creature.setIntendedTarget(target.getObjectId());
|
||||
|
||||
if (attacks==null) {
|
||||
//if(attacks.size() == 0) {
|
||||
System.out.println("AI calls default attack1" + actor.getMobileTemplate().getDefaultAttack());
|
||||
core.commandService.callCommand(creature, actor.getMobileTemplate().getDefaultAttack(), target, "");
|
||||
} else {
|
||||
Random rand = new Random();
|
||||
if(rand.nextFloat() <= 0.33f) {
|
||||
System.out.println("AI calls special attack");
|
||||
if(attacks.size() > 0)
|
||||
core.commandService.callCommand(creature, attacks.get(rand.nextInt(attacks.size())), target, "");
|
||||
} else {
|
||||
System.out.println("AI calls default attack2 " + actor.getMobileTemplate().getDefaultAttack());
|
||||
core.commandService.callCommand(creature, actor.getMobileTemplate().getDefaultAttack(), target, "");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1301,7 +1301,6 @@ public class CombatService implements INetworkDispatch {
|
||||
return;
|
||||
}
|
||||
synchronized(target.getMutex()) {
|
||||
System.out.println("THIS SHOULD BE RUN!!! " + (target.getHealth() - damage));
|
||||
target.setHealth(target.getHealth() - damage);
|
||||
}
|
||||
|
||||
|
||||
@@ -85,17 +85,14 @@ public class CommandService implements INetworkDispatch {
|
||||
return false;
|
||||
|
||||
if (actor.isPlayer() && command.getCharacterAbility().length() > 0 && !actor.hasAbility(command.getCharacterAbility())){
|
||||
System.out.println("RETURN 1! " + command.getCharacterAbility());
|
||||
return false;
|
||||
}
|
||||
|
||||
if (command.isDisabled()){
|
||||
System.out.println("RETURN 2!");
|
||||
return false;
|
||||
}
|
||||
|
||||
if (actor.hasCooldown(command.getCooldownGroup()) || actor.hasCooldown(command.getCommandName())){
|
||||
System.out.println("RETURN 3!");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -117,11 +114,10 @@ public class CommandService implements INetworkDispatch {
|
||||
|
||||
for (byte locomotion : command.getInvalidLocomotions()) {
|
||||
if (actor.getLocomotion() == locomotion) {
|
||||
System.out.println("RETURN 4!");
|
||||
return false;
|
||||
}
|
||||
}
|
||||
System.out.println("IN CALLCOMMAND!");
|
||||
|
||||
switch (command.getTargetType()) {
|
||||
case 0: // Target Not Used For This Command
|
||||
break;
|
||||
@@ -257,7 +253,7 @@ public class CommandService implements INetworkDispatch {
|
||||
default:
|
||||
break;
|
||||
}
|
||||
System.out.println("IN CALLCOMMAND2!");
|
||||
|
||||
switch (command.getTarget()) {
|
||||
case 0: // Ally Only
|
||||
if (target == null) {
|
||||
@@ -306,7 +302,7 @@ public class CommandService implements INetworkDispatch {
|
||||
default:
|
||||
break;
|
||||
}
|
||||
System.out.println("IN CALLCOMMAND! processCommand55");
|
||||
|
||||
if (command.shouldCallOnTarget()) {
|
||||
if (target == null || !(target instanceof CreatureObject)) {
|
||||
return false;
|
||||
@@ -327,14 +323,12 @@ public class CommandService implements INetworkDispatch {
|
||||
|
||||
if(command instanceof CombatCommand) {
|
||||
try {
|
||||
System.out.println("IN CALLCOMMAND! processCommand");
|
||||
processCommand(actor, target, (BaseSWGCommand) command.clone(), actionCounter, commandArgs);
|
||||
} catch (CloneNotSupportedException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
else {
|
||||
System.out.println("IN CALLCOMMAND! No combat cmdprocessCommand");
|
||||
processCommand(actor, target, command, actionCounter, commandArgs);
|
||||
}
|
||||
|
||||
@@ -643,7 +637,6 @@ public class CommandService implements INetworkDispatch {
|
||||
|
||||
for (BaseSWGCommand command : commands) {
|
||||
if (command.getCommandName().equalsIgnoreCase(name)) {
|
||||
System.out.println("commmand " + command.getCommandName());
|
||||
return command;
|
||||
}
|
||||
}
|
||||
@@ -663,12 +656,10 @@ public class CommandService implements INetworkDispatch {
|
||||
if (commandName.equalsIgnoreCase(name)) {
|
||||
if (isCombatCommand(commandName)) {
|
||||
CombatCommand command = new CombatCommand(commandName);
|
||||
System.out.println("commmand " + command.getCommandName());
|
||||
commandLookup.add(command);
|
||||
return command;
|
||||
} else {
|
||||
BaseSWGCommand command = new BaseSWGCommand(commandName);
|
||||
System.out.println("commmand " + command.getCommandName());
|
||||
commandLookup.add(command);
|
||||
return command;
|
||||
}
|
||||
@@ -700,7 +691,7 @@ public class CommandService implements INetworkDispatch {
|
||||
}
|
||||
|
||||
public void processCommand(CreatureObject actor, SWGObject target, BaseSWGCommand command, int actionCounter, String commandArgs) {
|
||||
System.out.println("NPC command name1 " + command.getCommandName());
|
||||
|
||||
if (command.getGodLevel() > 0 || command.getCommandName().equals("setgodmode") || command.getCommandName().equals("server") || command.getCommandName().equals("teleport")
|
||||
|| command.getCommandName().equals("teleportto") || command.getCommandName().equals("teleporttarget") ) {
|
||||
String accessLevel = core.adminService.getAccessLevelFromDB(actor.getClient().getAccountId());
|
||||
@@ -739,7 +730,6 @@ public class CommandService implements INetworkDispatch {
|
||||
}
|
||||
|
||||
if (command instanceof CombatCommand) {
|
||||
System.out.println("NPC command name2 " + command.getCommandName());
|
||||
processCombatCommand(actor, target, (CombatCommand) command, actionCounter, commandArgs);
|
||||
} else
|
||||
if (FileUtilities.doesFileExist("scripts/commands/" + command.getCommandName().toLowerCase() + ".py")) {
|
||||
|
||||
Reference in New Issue
Block a user