twcore.core
Class BotAction

java.lang.Object
  |
  +--twcore.core.BotAction

public class BotAction
extends java.lang.Object

Defines all the actions your bot may do in the arena. Combinations of these actions define more complex actions.


Constructor Summary
BotAction(twcore.core.GamePacketGenerator packetGenerator, twcore.core.Arena arena, java.util.Timer timer, twcore.core.Session botSession)
          Constructor for BotAction.
 
Method Summary
 void cancelTasks()
          Cancels all pending TimerTasks.
 void changeAllShips(int shipType)
          Issues a *setship to all the players in the arena (who are not in spec).
 void changeAllShipsOnFreq(int freq, int shipType)
          Changes all the ships on a freq to a particular ship type.
 void changeArena(short arenaNumber)
          This method tells the bot to leave the current arena, and join another arena specified by an integer.
 void changeArena(short arenaNumber, short xResolution, short yResolution)
          This is an overloaded function to allow resolution changes
 void changeArena(java.lang.String newArenaName)
          This method tells the bot to leave the current arena, and join another arena specified by a String.
 void changeArena(java.lang.String newArenaName, short xResolution, short yResolution)
          This is an overloaded change function to allow variations in resolution
 void checkAndSpec(int deaths)
          Checks every player in the game for X number of deaths, and places them in spectator mode.
 void createRandomTeams(int teamSize)
          Creates a set of teams of a particular size randomly.
 void die()
          Tells the bot to go parachuting (without the parachute).
 void dropFlags()
          Drops all flags the bot is carrying
 void fillInTeams(int size)
          Unimplemented
 boolean freqContainsShip(int freq, int ship)
          Tells if a freq in the arena contains a specific type of ship.
 java.lang.String getArenaName()
          Gets the name of the arena the bot is in.
 int getArenaSize()
          Gets the number of players in the arena.
static twcore.core.BotAction getBotAction()
          Return the correct BotAction for the running Thread.
 java.lang.String getBotName()
          Retreives the name of the bot.
 twcore.core.BotSettings getBotSettings()
          Gets a BotSettings for this bot.
 int getBotState()
          Gets the state of the bot.
 java.io.File getCoreCfg(java.lang.String filename)
           
 twcore.core.CoreData getCoreData()
           
 java.io.File getCoreDirectory()
          Gets the directory the core is in as a File object.
 java.io.File getCoreDirectoryFile(java.lang.String filename)
          Gets a file from the core directory.
 java.io.File getDataFile(java.lang.String filename)
          Gets a file from the Data directory, given the filename as a String.
 twcore.core.EventRequester getEventRequester()
          Gets the EventRequester object.
 twcore.core.Flag getFlag(int flagID)
          Gets the Flag object associated with the FlagID provided.
 java.util.Iterator getFlagIDIterator()
          Gets an Iterator of all the Flags in the game.
 java.util.Iterator getFreqPlayerIterator(int freq)
           
 twcore.core.Player getFuzzyPlayer(java.lang.String playerName)
          Searches for players in the arena of which the first part of the name matches with 'playerName'.
 java.lang.String getFuzzyPlayerName(java.lang.String playerName)
          Searches for players in the arena of which the first part of the name matches with 'playerName'.
 twcore.core.BotSettings getGeneralSettings()
          Retreives the information from setup.cfg
 twcore.core.InterProcessCommunicator getIPC()
           
 twcore.core.Objset getObjectSet()
          Returns the Objset object associated with this bot
 twcore.core.OperatorList getOperatorList()
          Gets an OperatorList.
 twcore.core.Player getPlayer(int playerID)
          Gets the Player object associated with the PlayerID provided.
 twcore.core.Player getPlayer(java.lang.String playerName)
          Gets the Player object associated with the PlayerID provided.
 int getPlayerID(java.lang.String playerName)
          Translates a player's name into a playerID.
 java.util.Iterator getPlayerIDIterator()
          Gets the PlayerIDs of all the players in the Iterator.
 java.util.Iterator getPlayerIterator()
          Gets an Iterator of all the Players playing in the game.
 java.lang.String getPlayerName(int playerID)
          Translates a playerID into a name, as a String.
 java.util.Iterator getPlayingPlayerIterator()
          Returns an iterator of all non-specced Players.
 int getScoreForFreq(int freq)
          Gets the total score for a particular frequency.
 void getServerFile(java.lang.String fileName)
          Retreives a file from the server.
 java.lang.String getServerName()
          Retrieves the name of the server the bot is connected to.
 int getServerPort()
          Retrieves the port of the server the bot is connected to.
 twcore.core.Ship getShip()
          Gets the Ship class, where ship movements, firing, and flying can be controlled.
 void giveBounty(int number)
          Gives an amount of bounty to everyone in the arena
 void giveBounty(int playerID, int number)
          Gives an amount of bounty to everyone in the arena.
 void giveBounty(java.lang.String name, int number)
          Gives an amount of bounty to everyone in the arena.
 void grabFlag(int flagID)
          Sets the bot to pickup the specified flag
 void hideObject(int objID)
          Issues an LVZ object off command.
 void ipcDestroyChannel(java.lang.String channelName)
          Explicitly destroys a channel
 void ipcSubscribe(java.lang.String channelName)
          Subscribes the current bot to the specified IPC Channel.
 void ipcTransmit(java.lang.String channelName, java.lang.Object o)
          Transmits an object to the specified channel over inter-process communication.
 void ipcUnSubscribe(java.lang.String channelName)
          Unsubscribes this bot from the provided channelName.
 void joinArena(short arena)
          Causes the bot to join a public arena.
 void joinArena(short arena, short xResolution, short yResolution)
          Overloaded function to joinArena which allows to specify the resolution of the arena
 void joinArena(java.lang.String arenaName)
          Causes the bot to join an arena.
 void joinArena(java.lang.String arenaName, short xResolution, short yResolution)
          Overloaded function to joinArena which allows to specify the resolution of the arena
 void joinRandomPublicArena()
          Causes the bot to join a random public arena
 void move(int x, int y)
          Moves the bot to position X, Y.
 void move(int x, int y, int vx, int vy)
           
 void moveToTile(int x, int y)
          Moves the bot to the tile (x,y). 512, 512 is the center.
 void privateMessageSpam(int playerID, java.lang.String[] spam)
          Sends the contents of the String array to the player in private messages.
 void privateMessageSpam(java.lang.String playerName, java.lang.String[] spam)
          Sends the contents of the String array to the player in private messages.
 void prize(int playerID, int prizeNum)
          Issues a prize to a specified player
 void prize(java.lang.String playerName, int prizeNum)
          Issue a prize to a specific player
 void prizeAll(int prizeNum)
          Issues a prize to every player in the arena
 void prizeFreq(int freqID, int prizeNum)
          Issues a prize to a frequency of players.
 void putFile(java.lang.String fileName)
          Issues the command *putfile.
 void remotePrivateMessageSpam(java.lang.String playerName, java.lang.String[] spam)
          Sends the contents of the String array to the player in remote private messages.
 void requestArenaList()
          Sends out a request for an ArenaList packet to be sent back.
 void resetFlagGame()
          Resets the flag game
 void scheduleTask(java.util.TimerTask task, long delayms)
          Schedules a TimerTask to occur once at a future time.
 void scheduleTaskAtFixedRate(java.util.TimerTask task, long delayms, long periodms)
          Schedules a TimerTask to occur repeatedly at an interval.
 void scoreReset(int playerID)
          Resets the scores of an individual player
 void scoreReset(java.lang.String playerName)
          Resets the scores of an individual player
 void scoreResetAll()
          Resets the scores of the players in an arena
 void sendAlertMessage(java.lang.String type, java.lang.String message)
          Sends a alert command as specified.
 void sendArenaMessage(java.lang.String message)
          Displays a green arena message to the arena the bot is in.
 void sendArenaMessage(java.lang.String message, int soundCode)
          Displays a green arena message to the arena the bot is in, with a sound code.
 void sendChatMessage(int chatNumber, java.lang.String message)
          Sends a chat message to a specific chat number.
 void sendChatMessage(int chatNumber, java.lang.String message, int soundCode)
          Sends a chat message to a specific chat number, with a sound code.
 void sendChatMessage(java.lang.String message)
          Sends a chat message to the first chat.
 void sendCheaterMessage(java.lang.String message)
          Sends a "?
 void sendDeath(int bounty)
          Sends a death packet.
 void sendHelpMessage(java.lang.String message)
          Sends a "?
 void sendOpposingTeamMessage(int frequency, java.lang.String message)
          Send a message to a whole frequency of players.
 void sendOpposingTeamMessage(int frequency, java.lang.String message, int soundCode)
          Send a message to a whole frequency of players.
 void sendPrivateMessage(int playerID, java.lang.String message)
          Sends a private message to someone in the same arena.
 void sendPrivateMessage(int playerID, java.lang.String message, int soundCode)
          Sends a private message to someone in the same arena.
 void sendPrivateMessage(java.lang.String name, java.lang.String message)
          Sends a private message to someone in the same arena.
 void sendPrivateMessage(java.lang.String name, java.lang.String message, int soundCode)
          Sends a private message to someone in the same arena.
 void sendPublicMessage(java.lang.String message)
          Sends a normal (blue) message to the public chat.
 void sendPublicMessage(java.lang.String message, int soundCode)
          Sends a normal (blue) message to the public chat with a sound code.
 void sendRemotePrivateMessage(java.lang.String name, java.lang.String message)
          Sends a remote private message.
 void sendRemotePrivateMessage(java.lang.String name, java.lang.String message, int soundCode)
          Sends a remote private message.
 void sendSmartPrivateMessage(java.lang.String name, java.lang.String message)
          Sends a smart private message.
 void sendSmartPrivateMessage(java.lang.String name, java.lang.String message, int soundCode)
          Sends a smart private message.
 void sendSquadMessage(java.lang.String squadName, java.lang.String message)
          Sends a squad message to a specific squad.
 void sendSquadMessage(java.lang.String squadName, java.lang.String message, int soundCode)
          Sends a squad message to a specific squad with a sound code.
 void sendTeamMessage(java.lang.String message)
          Send a message to your teammates.
 void sendTeamMessage(java.lang.String message, int soundCode)
          Send a message to your teammates.
 void sendUnfilteredPrivateMessage(int playerID, java.lang.String message)
          Sends a private message without any filtration.
 void sendUnfilteredPrivateMessage(int playerID, java.lang.String message, int soundCode)
          Sends a private message without any filtration.
 void sendUnfilteredPrivateMessage(java.lang.String name, java.lang.String message)
          Sends a private message without any filtration.
 void sendUnfilteredPrivateMessage(java.lang.String name, java.lang.String message, int soundCode)
          Sends a private message without any filtration.
 void sendUnfilteredPublicMessage(java.lang.String message)
          Sends a private message without any filtration.
 void sendUnfilteredPublicMessage(java.lang.String message, int soundCode)
          Sends a private message without any filtration.
 void sendZoneMessage(java.lang.String message)
          Sends a zone wide advertisement.
 void sendZoneMessage(java.lang.String message, int soundCode)
          Sends a zone wide advertisement.
 void setAlltoFreq(int destFreq)
          Changes the frequency of all the playing players in the game to a specified frequency.
 void setDoors(int doors)
          Sets the doors in the arena to the specified value.
 void setDoors(java.lang.String eightBinaryDigits)
          Uses a binary string such as "11010110" to turn specific doors on or off.
 void setFreq(int playerID, int freqNum)
          Changes the frequency a player is on.
 void setFreq(java.lang.String playerName, int freqNum)
          Changes the frequency a player is on.
 void setFreqtoFreq(int initialFreq, int destFreq)
          Changes all the players on one freq to another freq.
 void setMessageLimit(int msgsPerMin)
          Sets up spam protection for the bot.
 void setObjects()
          Sets private objects of an individual player
 void setObjects(int playerId)
          Sets private objects of an individual player
 void setPacketSendDelay(int milliseconds)
          Adjusts the packet send delay.
 void setReliableKills(int var)
          Sets the kill message reliability to an integer bounty value.
 void setShip(int playerID, int shipType)
          Changes the ship type of a player.
 void setShip(java.lang.String playerName, int shipType)
          Changes the ship type of a player.
 void setThorAdjust(int thorAdjust)
          Sets the power of the thor weapons
 void setTimer(int seconds)
          Sets the *timer game timer
 void shipReset(int playerID)
          Issues a *shipreset to a specific player
 void shipReset(java.lang.String playerName)
          Issues a *shipreset to a specific player
 void shipResetAll()
          Issues a *shipreset to all players in the arena
 void showObject(int objID)
          Issues an LVZ object on command.
 void smartPrivateMessageSpam(java.lang.String playerName, java.lang.String[] spam)
          This Sends the contents of the String array to the player in smart private messages.
 void spec(int playerID)
          Issues a /*spec command to the player supplied by the parameter.
 void spec(java.lang.String playerName)
          Issues a /*spec command to the player supplied by the parameter.
 void specAll()
          Places all players in the arena into spectator mode.
 void spectatePlayer(int playerID)
          Sets the bot to spectate the specified player and surrounding area
 void spectatePlayer(java.lang.String playerName)
          Sets the bot to spectate the specified player and surrounding area
 void SQLBackgroundInsertInto(java.lang.String connectName, java.lang.String tableName, java.lang.String[] fields, java.lang.String[] values)
          Insert Into helper method.
 void SQLBackgroundQuery(java.lang.String connectName, java.lang.String identifier, java.lang.String query)
          Runs a high priority backround SQL Query.
 void SQLHighPriorityBackgroundQuery(java.lang.String connectName, java.lang.String identifier, java.lang.String query)
          Runs a high priority background query.
 void SQLInsertInto(java.lang.String connectName, java.lang.String tableName, java.lang.String[] fields, java.lang.String[] values)
          Insert Into helper method.
 boolean SQLisOperational()
          If the SQL connection pools weren't initialized properly for some reason, this method will return false.
 java.sql.ResultSet SQLQuery(java.lang.String connectName, java.lang.String query)
          Runs a direct SQL Query.
 void toggleBlueOut()
          Starts or ends blue message out, depending on state.
 void toggleLocked()
          Locks or unlocks the arena, depending on game state.
 void toggleWatchDamage(int playerID)
          Toggles WatchDamage for this player.
 void toggleWatchDamage(java.lang.String playerName)
          Toggles WatchDamage for this player.
 void warnPlayer(int playerID, java.lang.String message)
          Warns the player with a moderator warning
 void warnPlayer(java.lang.String playername, java.lang.String message)
          Warns the player with a moderator warning
 void warpAllRandomly()
          Warps the warp prize to all playing players in the arena.
 void warpAllToLocation(int x, int y)
          Warps all the players in the arena to location X, Y.
 void warpFreqToLocation(int freq, int x, int y)
          Warps all the players on a frequency to location X, Y.
 void warpTo(int playerID, int xTiles, int yTiles)
          Warps a player to the given coordinates
 void warpTo(java.lang.String playerName, int xTiles, int yTiles)
          Warps a player to the given coordinates
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BotAction

public BotAction(twcore.core.GamePacketGenerator packetGenerator,
                 twcore.core.Arena arena,
                 java.util.Timer timer,
                 twcore.core.Session botSession)
Constructor for BotAction. Don't worry about this, the object has already been constructed for you.

Parameters:
botSession - Session object describing the session
packetGenerator - Packet generator which is called when packets are sent out.
arena - Arena Tracker object used to represent an arena full of players.
Method Detail

getBotAction

public static twcore.core.BotAction getBotAction()
Return the correct BotAction for the running Thread. Useful for subclasses of bots, so you don't need to pass BotAction down the entire hierarchy.

Returns:
BotAction the botAction object of the currently running Thread(Bot)

scheduleTask

public void scheduleTask(java.util.TimerTask task,
                         long delayms)
Schedules a TimerTask to occur once at a future time. TimerTask is part of the package java.util. The only method that a TimerTask must override is public void run().

Parameters:
task - TimerTask to be executed.
delayms - Length of time before execution, in milliseconds

scheduleTaskAtFixedRate

public void scheduleTaskAtFixedRate(java.util.TimerTask task,
                                    long delayms,
                                    long periodms)
Schedules a TimerTask to occur repeatedly at an interval. TimerTask is part of the package java.util. The only method that a TimerTask must override is public void run().

Parameters:
task - TimerTask to be executed.
delayms - Length of time before execution, in milliseconds
periodms - Delay between executions after the initial execution, in milliseconds.

cancelTasks

public void cancelTasks()
Cancels all pending TimerTasks. You can cancel an individual TimerTask by using task.cancel().


sendUnfilteredPrivateMessage

public void sendUnfilteredPrivateMessage(java.lang.String name,
                                         java.lang.String message)
Sends a private message without any filtration. Use this ONLY in situations where you are hard coding in commands to be sent. For the sake of security, use the filtered methods for *everything* else.

Parameters:
name - Name of the person the message is to be sent to.
message - Message to be sent.

sendUnfilteredPrivateMessage

public void sendUnfilteredPrivateMessage(int playerID,
                                         java.lang.String message)
Sends a private message without any filtration. Use this ONLY in situations where you are hard coding in commands to be sent. For the sake of security, use the filtered methods for *everything* else.

Parameters:
playerID - Player ID of the player you wish to send the message to.
message - Message to be sent.

sendUnfilteredPrivateMessage

public void sendUnfilteredPrivateMessage(java.lang.String name,
                                         java.lang.String message,
                                         int soundCode)
Sends a private message without any filtration. Use this ONLY in situations where you are hard coding in commands to be sent. For the sake of security, use the filtered methods for *everything* else.

Parameters:
name - Name of the person the message is to be sent to.
message - Message to be sent.
soundCode - Sound code to be sent along with the message.

sendUnfilteredPrivateMessage

public void sendUnfilteredPrivateMessage(int playerID,
                                         java.lang.String message,
                                         int soundCode)
Sends a private message without any filtration. Use this ONLY in situations where you are hard coding in commands to be sent. For the sake of security, use the filtered methods for *everything* else.

Parameters:
playerID - Player ID of the player you wish to send the message to.
message - Message to be sent.
soundCode - Sound code to be sent along with the message.

sendUnfilteredPublicMessage

public void sendUnfilteredPublicMessage(java.lang.String message)
Sends a private message without any filtration. Use this ONLY in situations where you are hard coding in commands to be sent. For the sake of security, use the filtered methods for *everything* else.

Parameters:
message - Message to be sent.

sendUnfilteredPublicMessage

public void sendUnfilteredPublicMessage(java.lang.String message,
                                        int soundCode)
Sends a private message without any filtration. Use this ONLY in situations where you are hard coding in commands to be sent. For the sake of security, use the filtered methods for *everything* else.

Parameters:
message - Message to be sent.
soundCode - Sound code to be sent along with the message.

sendZoneMessage

public void sendZoneMessage(java.lang.String message)
Sends a zone wide advertisement. Do not use unless absolutely necessary.

Parameters:
message - The message to be sent

sendZoneMessage

public void sendZoneMessage(java.lang.String message,
                            int soundCode)
Sends a zone wide advertisement. Do not use unless absolutely necessary. Includes a sound code.

Parameters:
message - The away message to be sent
soundCode - Sound code to be sent along with the message.

getServerName

public java.lang.String getServerName()
Retrieves the name of the server the bot is connected to.

Returns:
The host name of the server the bot is connected to.

getServerPort

public int getServerPort()
Retrieves the port of the server the bot is connected to.

Returns:
The port number on the server that the bot is connected to.

getOperatorList

public twcore.core.OperatorList getOperatorList()
Gets an OperatorList. Operator list is our means of access control. Please see the class OperatorList for more information. This one instance is shared between every bot running on the system.

Returns:
An instance containing methods and information related to access control.

getGeneralSettings

public twcore.core.BotSettings getGeneralSettings()
Retreives the information from setup.cfg

Returns:
An instance of a class that provides the data contained in setup.cfg

getBotState

public int getBotState()
Gets the state of the bot. This is important only internally. This can safely be ignored by most people.

Returns:
An integer representing the state of the bot as reflected in Session

sendHelpMessage

public void sendHelpMessage(java.lang.String message)
Sends a "?help" alert command.

Parameters:
message - The message to be sent along with the alert

sendCheaterMessage

public void sendCheaterMessage(java.lang.String message)
Sends a "?cheater" alert command.

Parameters:
message - The message to be sent along with the alert

sendAlertMessage

public void sendAlertMessage(java.lang.String type,
                             java.lang.String message)
Sends a alert command as specified.

Parameters:
type - The type of alert command to be sent
message - The message to be sent along with the alert

sendArenaMessage

public void sendArenaMessage(java.lang.String message)
Displays a green arena message to the arena the bot is in.

Parameters:
message - The message to be displayed.

sendArenaMessage

public void sendArenaMessage(java.lang.String message,
                             int soundCode)
Displays a green arena message to the arena the bot is in, with a sound code.

Parameters:
message - The message to be displayed.
soundCode - Sound code to be sent along with the message.

sendPublicMessage

public void sendPublicMessage(java.lang.String message)
Sends a normal (blue) message to the public chat.

Parameters:
message - The message to be displayed.

sendPublicMessage

public void sendPublicMessage(java.lang.String message,
                              int soundCode)
Sends a normal (blue) message to the public chat with a sound code.

Parameters:
message - The message to be displayed.
soundCode - Sound code to be sent along with the message.

sendTeamMessage

public void sendTeamMessage(java.lang.String message)
Send a message to your teammates. If the bot is in spectator mode, it will speak with the players in spectator mode.

Parameters:
message - The message to be displayed.

sendTeamMessage

public void sendTeamMessage(java.lang.String message,
                            int soundCode)
Send a message to your teammates. If the bot is in spectator mode, it will speak with the players in spectator mode. Includes a sound code.

Parameters:
message - The message to be displayed.
soundCode - Sound code to be sent along with the message.

sendOpposingTeamMessage

public void sendOpposingTeamMessage(int frequency,
                                    java.lang.String message)
Send a message to a whole frequency of players.

Parameters:
frequency - The frequency this message is to be sent to.
message - The message to be displayed.

sendOpposingTeamMessage

public void sendOpposingTeamMessage(int frequency,
                                    java.lang.String message,
                                    int soundCode)
Send a message to a whole frequency of players.

Parameters:
frequency - The frequency this message is to be sent to.
message - The message to be sent
soundCode - Sound code to be sent along with the message.

getServerFile

public void getServerFile(java.lang.String fileName)
Retreives a file from the server. File arrives in a "FileArrived" packet.

Parameters:
fileName - Filename of the file requested.

putFile

public void putFile(java.lang.String fileName)
Issues the command *putfile. Sphonk, please fill in what one might do with this.

Parameters:
fileName - Name of the file to send.

sendChatMessage

public void sendChatMessage(java.lang.String message)
Sends a chat message to the first chat.

Parameters:
message - The message to be displayed.

sendChatMessage

public void sendChatMessage(int chatNumber,
                            java.lang.String message)
Sends a chat message to a specific chat number.

Parameters:
chatNumber - Number of the chat to send information to.
message - The message to be displayed.

sendChatMessage

public void sendChatMessage(int chatNumber,
                            java.lang.String message,
                            int soundCode)
Sends a chat message to a specific chat number, with a sound code.

Parameters:
chatNumber - Number of the chat to send information to.
message - The message to be displayed.
soundCode - Sound code to be sent along with the message.

sendSquadMessage

public void sendSquadMessage(java.lang.String squadName,
                             java.lang.String message)
Sends a squad message to a specific squad.

Parameters:
squadName - Name of the squad
message - Message to send to that squad

sendSquadMessage

public void sendSquadMessage(java.lang.String squadName,
                             java.lang.String message,
                             int soundCode)
Sends a squad message to a specific squad with a sound code.

Parameters:
squadName - Name of the squad
message - Message to send to that squad
soundCode - Sound code to be sent along with the message.

sendPrivateMessage

public void sendPrivateMessage(java.lang.String name,
                               java.lang.String message)
Sends a private message to someone in the same arena. Do not attempt to use this method if you are not absolutely certain that the player is in the arena. If you are at all unsure, use sendSmartPrivateMessage instead.

Parameters:
name - The name of the player.
message - The message to be displayed.

sendPrivateMessage

public void sendPrivateMessage(int playerID,
                               java.lang.String message)
Sends a private message to someone in the same arena. Do not attempt to use this method if you are not absolutely certain that the player is in the arena. If you are at all unsure, use sendSmartPrivateMessage instead.

Parameters:
playerID - Player ID of the player you wish to send the message to.
message - The message to be displayed.

sendPrivateMessage

public void sendPrivateMessage(java.lang.String name,
                               java.lang.String message,
                               int soundCode)
Sends a private message to someone in the same arena. Do not attempt to use this method if you are not absolutely certain that the player is in the arena. If you are at all unsure, use sendSmartPrivateMessage instead.

Parameters:
name - The name of the player.
message - The message to be displayed.
soundCode - Sound code to be sent along with the message.

sendPrivateMessage

public void sendPrivateMessage(int playerID,
                               java.lang.String message,
                               int soundCode)
Sends a private message to someone in the same arena. Do not attempt to use this method if you are not absolutely certain that the player is in the arena. If you are at all unsure, use sendSmartPrivateMessage instead.

Parameters:
playerID - Player ID of the player you wish to send the message to.
message - The message to be displayed.
soundCode - Sound code to be sent along with the message.

sendSmartPrivateMessage

public void sendSmartPrivateMessage(java.lang.String name,
                                    java.lang.String message)
Sends a smart private message. A smart private message is a private message sent much like the Continuum client does it. If a player is not present in the arena, the message will be sent as a remote private message. Otherwise, the message will be sent as a private message. Using this will help save server time over remote private messages, and appear more natural to players.

Parameters:
name - The name of the player.
message - The message to be displayed.

sendSmartPrivateMessage

public void sendSmartPrivateMessage(java.lang.String name,
                                    java.lang.String message,
                                    int soundCode)
Sends a smart private message. A smart private message is a private message sent much like the Continuum client does it. If a player is not present in the arena, the message will be sent as a remote private message. Otherwise, the message will be sent as a private message. Using this will help save server time over remote private messages, and appear more natural to players.

Parameters:
name - The name of the player.
message - The message to be displayed.
soundCode - Sound code to be sent along with the message.

sendRemotePrivateMessage

public void sendRemotePrivateMessage(java.lang.String name,
                                     java.lang.String message)
Sends a remote private message. Remote private messages look like (Name)> to the player, even if the player is in the same arena as you. Try to use smart private messages instead.

Parameters:
name - The name of the player.
message - The message to be displayed.

sendRemotePrivateMessage

public void sendRemotePrivateMessage(java.lang.String name,
                                     java.lang.String message,
                                     int soundCode)
Sends a remote private message. Remote private messages look like (Name)> to the player, even if the player is in the same arena as you. Try to use smart private messages instead.

Parameters:
name - The name of the player.
message - The message to be displayed.

createRandomTeams

public void createRandomTeams(int teamSize)
Creates a set of teams of a particular size randomly. The problem with this is it is not entirely random. A more random algorithm needs to be developed.

Parameters:
teamSize - The size of the team desired.

spec

public void spec(java.lang.String playerName)
Issues a /*spec command to the player supplied by the parameter. Note that in most cases the command must be issued twice, just as in the game.

Parameters:
playerName - The name of the player.

spec

public void spec(int playerID)
Issues a /*spec command to the player supplied by the parameter. Note that in most cases the command must be issued twice, just as in the game.

Parameters:
playerID - Player ID of the player you want to spec.

specAll

public void specAll()
Places all players in the arena into spectator mode.


setShip

public void setShip(int playerID,
                    int shipType)
Changes the ship type of a player.

Parameters:
playerID - Player ID of the player you want to change.
shipType - Ship type that you wish to set. Must be a value between 1 and 8.

setShip

public void setShip(java.lang.String playerName,
                    int shipType)
Changes the ship type of a player.

Parameters:
playerName - The name of the player.
shipType - Ship type that you wish to set. Must be a value between 1 and 8.

setFreq

public void setFreq(int playerID,
                    int freqNum)
Changes the frequency a player is on.

Parameters:
playerID - Player ID of the player you want to change.
freqNum - Frequency you want this player to be on.

setFreq

public void setFreq(java.lang.String playerName,
                    int freqNum)
Changes the frequency a player is on.

Parameters:
playerName - The name of the player.
freqNum - Frequency you want this player to be on.

warpTo

public void warpTo(int playerID,
                   int xTiles,
                   int yTiles)
Warps a player to the given coordinates

Parameters:
playerID - PlayerID of the player to be warped
xTiles - X coordinate
yTiles - Y coordinate

warpTo

public void warpTo(java.lang.String playerName,
                   int xTiles,
                   int yTiles)
Warps a player to the given coordinates

Parameters:
playerName - The name of the player.
xTiles - X coordinate
yTiles - Y coordinate

showObject

public void showObject(int objID)
Issues an LVZ object on command.

Parameters:
objID - The ID of the object as denoted in the LVZ.

hideObject

public void hideObject(int objID)
Issues an LVZ object off command.

Parameters:
objID - The ID of the object as denoted in the LVZ.

getObjectSet

public twcore.core.Objset getObjectSet()
Returns the Objset object associated with this bot


setObjects

public void setObjects()
Sets private objects of an individual player


setObjects

public void setObjects(int playerId)
Sets private objects of an individual player


scoreReset

public void scoreReset(java.lang.String playerName)
Resets the scores of an individual player

Parameters:
playerName - Name of player to be reset

scoreReset

public void scoreReset(int playerID)
Resets the scores of an individual player

Parameters:
playerID - Player ID of player to be reset

scoreResetAll

public void scoreResetAll()
Resets the scores of the players in an arena


shipReset

public void shipReset(java.lang.String playerName)
Issues a *shipreset to a specific player

Parameters:
playerName - Name of the player to be *shipresetted

shipReset

public void shipReset(int playerID)
Issues a *shipreset to a specific player

Parameters:
playerID - Integer reference to the player specified

shipResetAll

public void shipResetAll()
Issues a *shipreset to all players in the arena


setThorAdjust

public void setThorAdjust(int thorAdjust)
Sets the power of the thor weapons

Parameters:
thorAdjust - Amount to adjust thor power by

prize

public void prize(java.lang.String playerName,
                  int prizeNum)
Issue a prize to a specific player

Parameters:
playerName - Name of the player
prizeNum - Number of the prize

prize

public void prize(int playerID,
                  int prizeNum)
Issues a prize to a specified player

Parameters:
playerID - Player ID
prizeNum - Number of the prize

prizeFreq

public void prizeFreq(int freqID,
                      int prizeNum)
Issues a prize to a frequency of players. Possibly buggy?

Parameters:
freqID - The frequency of players you wish to issue the prizes to.
prizeNum - Number of the prize

prizeAll

public void prizeAll(int prizeNum)
Issues a prize to every player in the arena

Parameters:
prizeNum - Number of the prize

giveBounty

public void giveBounty(int number)
Gives an amount of bounty to everyone in the arena

Parameters:
number - Amount of bounty to give

giveBounty

public void giveBounty(java.lang.String name,
                       int number)
Gives an amount of bounty to everyone in the arena.

Parameters:
name - Name of the player to give the bounty to.
number - Amount of bounty you want to give.

giveBounty

public void giveBounty(int playerID,
                       int number)
Gives an amount of bounty to everyone in the arena.

Parameters:
playerID - PlayerID of the player you want to give the bounty to.
number - Amount of bounty you want to give.

resetFlagGame

public void resetFlagGame()
Resets the flag game


toggleLocked

public void toggleLocked()
Locks or unlocks the arena, depending on game state.


toggleBlueOut

public void toggleBlueOut()
Starts or ends blue message out, depending on state.


setTimer

public void setTimer(int seconds)
Sets the *timer game timer

Parameters:
seconds - Time to game end in seconds

warnPlayer

public void warnPlayer(java.lang.String playername,
                       java.lang.String message)
Warns the player with a moderator warning

Parameters:
playername - The name of the player
message - The message to be sent

warnPlayer

public void warnPlayer(int playerID,
                       java.lang.String message)
Warns the player with a moderator warning

Parameters:
playerID - The player to be warned
message - The message to be sent

getFlag

public twcore.core.Flag getFlag(int flagID)
Gets the Flag object associated with the FlagID provided. The Flag object describes all the pertinent details about a flag in the arena the bot is in.

Parameters:
flagID - The FlagID of the player you wish to retrieve info for.
Returns:
Returns a Flag object.

getPlayer

public twcore.core.Player getPlayer(int playerID)
Gets the Player object associated with the PlayerID provided. The Player object describes all the pertinent details about a player in the arena the bot is in.

Parameters:
playerID - The PlayerID of the player you wish to retrieve info for.
Returns:
Returns a Player object.

getPlayer

public twcore.core.Player getPlayer(java.lang.String playerName)
Gets the Player object associated with the PlayerID provided. The Player object describes all the pertinent details about a player in the arena the bot is in.

Parameters:
playerName - The name of the player you wish to retreive info for.
Returns:
Returns a Player object.

getPlayerName

public java.lang.String getPlayerName(int playerID)
Translates a playerID into a name, as a String.

Parameters:
playerID - The PlayerID you want to translate.
Returns:
The player's name.

getPlayerID

public int getPlayerID(java.lang.String playerName)
Translates a player's name into a playerID. Be careful while using this, however, as players may or may not be in a given arena.

Parameters:
playerName - The name of the player.
Returns:
The PlayerID of the player given in playerName.

getFuzzyPlayer

public twcore.core.Player getFuzzyPlayer(java.lang.String playerName)
Searches for players in the arena of which the first part of the name matches with 'playerName'. When there are multiple player matches it will return the first found match OR the player which exactly matches (case insensitive) 'playerName' if there is one.

Parameters:
playerName - The partial name of a player
Returns:
The PlayerID of the first found player matching or starting with playerName

getFuzzyPlayerName

public java.lang.String getFuzzyPlayerName(java.lang.String playerName)
Searches for players in the arena of which the first part of the name matches with 'playerName'. When there are multiple player matches it will return the first found match OR the player which exactly matches (case insensitive) 'playerName' if there is one.

Parameters:
playerName - The partial name of a player
Returns:
The PlayerName of the first found player matching or starting with playerName

getBotName

public java.lang.String getBotName()
Retreives the name of the bot.

Returns:
Thw name of the bot.

joinArena

public void joinArena(java.lang.String arenaName)
Causes the bot to join an arena. If the bot is already in an arena, use changeArena( int ) instead. This method is only to be used before the bot is in an arena. String encoded Integer values denote public arenas.

Parameters:
arenaName - The name or number of the arena to join.

joinArena

public void joinArena(java.lang.String arenaName,
                      short xResolution,
                      short yResolution)
               throws java.lang.Exception
Overloaded function to joinArena which allows to specify the resolution of the arena

Parameters:
xResolution - The X - coordinate resolution for the screen
yResolution - The Y - coordinate resolution for the screen
java.lang.Exception
See Also:
joinArena(String arenaName)

joinArena

public void joinArena(short arena)
Causes the bot to join a public arena.

Parameters:
arena - The arena number to join

joinArena

public void joinArena(short arena,
                      short xResolution,
                      short yResolution)
               throws java.lang.Exception
Overloaded function to joinArena which allows to specify the resolution of the arena

Parameters:
arena - The arena number to join
xResolution - The X - coordinate resolution for the screen
yResolution - The Y - coordinate resolution for the screen
java.lang.Exception
See Also:
(short arena)

joinRandomPublicArena

public void joinRandomPublicArena()
Causes the bot to join a random public arena


changeArena

public void changeArena(java.lang.String newArenaName)
This method tells the bot to leave the current arena, and join another arena specified by a String. If the String contains an integer value, the bot will go to a public arena of that value.

Parameters:
newArenaName - Name or number of the arena to change to.

changeArena

public void changeArena(java.lang.String newArenaName,
                        short xResolution,
                        short yResolution)
                 throws java.lang.Exception
This is an overloaded change function to allow variations in resolution

Parameters:
newArenaName - Name or number of the arena to change to.
xResolution - The X Max for the screen size
yResolution - The Y Max for the screen size
Throws:
catches - the resolution mistake for specifying X max and Y
java.lang.Exception
See Also:
changeArena(String newArenaName)

changeArena

public void changeArena(short arenaNumber)
This method tells the bot to leave the current arena, and join another arena specified by an integer.

Parameters:
arenaNumber - The number of the public arena to change to.

changeArena

public void changeArena(short arenaNumber,
                        short xResolution,
                        short yResolution)
                 throws java.lang.Exception
This is an overloaded function to allow resolution changes

Parameters:
arenaNumber - The number of the public arena to change to.
xResolution - The X Max for the screen size
yResolution - The Y Max for the screen size
Throws:
catches - the resolution mistake for specifying X max and Y
java.lang.Exception
See Also:
changeArena(short arenaNumber)

getArenaName

public java.lang.String getArenaName()
Gets the name of the arena the bot is in.

Returns:
the arena the bot currently is in or is going to

setReliableKills

public void setReliableKills(int var)
Sets the kill message reliability to an integer bounty value.

Parameters:
var - Amount of bounty for kill messages to become reliable.

spectatePlayer

public void spectatePlayer(int playerID)
Sets the bot to spectate the specified player and surrounding area

Parameters:
playerID - Ident of the player to spectate

spectatePlayer

public void spectatePlayer(java.lang.String playerName)
Sets the bot to spectate the specified player and surrounding area

Parameters:
playerName - Name of the player to spectate

grabFlag

public void grabFlag(int flagID)
Sets the bot to pickup the specified flag

Parameters:
flagID - ID of flag to pickup.

dropFlags

public void dropFlags()
Drops all flags the bot is carrying


warpAllToLocation

public void warpAllToLocation(int x,
                              int y)
Warps all the players in the arena to location X, Y.

Parameters:
x - X coordinate to warp the players to
y - X coordinate to warp the players to

warpFreqToLocation

public void warpFreqToLocation(int freq,
                               int x,
                               int y)
Warps all the players on a frequency to location X, Y.

Parameters:
freq - Frequency to warp
x - X coordinate to warp the players to
y - Y coordinate to warp the players to

changeAllShips

public void changeAllShips(int shipType)
Issues a *setship to all the players in the arena (who are not in spec).

Parameters:
shipType - Ship type to switch the players into.

warpAllRandomly

public void warpAllRandomly()
Warps the warp prize to all playing players in the arena.


changeAllShipsOnFreq

public void changeAllShipsOnFreq(int freq,
                                 int shipType)
Changes all the ships on a freq to a particular ship type.

Parameters:
freq - The frequency of the players you wish to change
shipType - The ship type that you wish to change the players to

setFreqtoFreq

public void setFreqtoFreq(int initialFreq,
                          int destFreq)
Changes all the players on one freq to another freq. Great for consolidating teams.

Parameters:
initialFreq - Frequency of the players you wish to change
destFreq - The frequency you wish to change the players to

setAlltoFreq

public void setAlltoFreq(int destFreq)
Changes the frequency of all the playing players in the game to a specified frequency.

Parameters:
destFreq - Frequency to change the players to.

getScoreForFreq

public int getScoreForFreq(int freq)
Gets the total score for a particular frequency.

Parameters:
freq - Frequency of the players to get the score for.
Returns:
The total score for the players on the specified frequency.

setDoors

public void setDoors(int doors)
Sets the doors in the arena to the specified value. If you wish, you can use setDoors( String ) and enter binary string such as "11010110" to turn doors on or off.

Parameters:
doors - The value of the doors to be set.

privateMessageSpam

public void privateMessageSpam(int playerID,
                               java.lang.String[] spam)
Sends the contents of the String array to the player in private messages.

Parameters:
playerID - PlayerID to send the messages to.
spam - The array of Strings to send to the player in private messages.

privateMessageSpam

public void privateMessageSpam(java.lang.String playerName,
                               java.lang.String[] spam)
Sends the contents of the String array to the player in private messages.

Parameters:
playerName - Player name to send the messages to.
spam - The array of Strings to send to the player in private messages.

remotePrivateMessageSpam

public void remotePrivateMessageSpam(java.lang.String playerName,
                                     java.lang.String[] spam)
Sends the contents of the String array to the player in remote private messages. Careful with this one, sending too many across the billing server can cause trouble.

Parameters:
playerName - Name of the player to send the messages to.
spam - The array of Strings to send to the player in private messages.

smartPrivateMessageSpam

public void smartPrivateMessageSpam(java.lang.String playerName,
                                    java.lang.String[] spam)
This Sends the contents of the String array to the player in smart private messages. Smart private messages are private messages that are sent as private messages if the player is in the same arena, and remote private messages if the player is not in the arena.

Parameters:
playerName - Name of the player to send the messages to.
spam - The array of Strings to send to the player in private messages.

freqContainsShip

public boolean freqContainsShip(int freq,
                                int ship)
Tells if a freq in the arena contains a specific type of ship.

Parameters:
freq - Frequency to check
ship - Ship type to look for
Returns:
Returns whether the ship exists in the freq

getArenaSize

public int getArenaSize()
Gets the number of players in the arena.

Returns:
The number of players in the arena.

checkAndSpec

public void checkAndSpec(int deaths)
Checks every player in the game for X number of deaths, and places them in spectator mode. Use this command once, then use the PlayerDeath packets to count the rest.

Parameters:
deaths - Number of deaths to spec at.

die

public void die()
Tells the bot to go parachuting (without the parachute).


sendDeath

public void sendDeath(int bounty)
Sends a death packet. Not really sure what this does.

Parameters:
bounty - Amount of bounty the death is related to.

fillInTeams

public void fillInTeams(int size)
Unimplemented

Parameters:
size - Maximum size of the freqs

getPlayingPlayerIterator

public java.util.Iterator getPlayingPlayerIterator()
Returns an iterator of all non-specced Players. Example usage: Iterator i = m_botAction.getPlayingPlayerIterator(); while( i.hasNext() ){ Player p = (Player)i.next(); if( p.getPlayerName().equals( "DoCk>" )){ m_botAction.sendPrivateMessage( p.getPlayerID(), "Hi DoCk>!" ); } else if( p.getFrequency() == 223 && p.getSquadName().equals( "LAME" )){ m_botAction.sendPrivateMessage( p.getPlayerID(), "L!" ); } }

Returns:
An Iterator of players who are playing

getFreqPlayerIterator

public java.util.Iterator getFreqPlayerIterator(int freq)
Parameters:
freq -
Returns:

getPlayerIterator

public java.util.Iterator getPlayerIterator()
Gets an Iterator of all the Players playing in the game.

Returns:
An Iterator of all the Players playing in the game.

getPlayerIDIterator

public java.util.Iterator getPlayerIDIterator()
Gets the PlayerIDs of all the players in the Iterator.

Returns:
Returns an Iterator containing the player ID value wrapped in an Integer

getFlagIDIterator

public java.util.Iterator getFlagIDIterator()
Gets an Iterator of all the Flags in the game.

Returns:
An Iterator of all the Flags in the game.

getBotSettings

public twcore.core.BotSettings getBotSettings()
Gets a BotSettings for this bot. Reads the .cfg file.

Returns:
A BotSettings object containing data from the bot's .cfg

moveToTile

public void moveToTile(int x,
                       int y)
Moves the bot to the tile (x,y). 512, 512 is the center.

Parameters:
x - X value to move the bot to
y - Y value to move the bot to

move

public void move(int x,
                 int y)
Moves the bot to position X, Y. Center of the arena is (8192, 8192) as opposed to the less accurate (512, 512) of moveToTile( x, y ).

Parameters:
x - Position of the bot along the X axis.
y - Position of the bot along the Y axis.

move

public void move(int x,
                 int y,
                 int vx,
                 int vy)

getShip

public twcore.core.Ship getShip()
Gets the Ship class, where ship movements, firing, and flying can be controlled.

Returns:
The Ship class, which controls the in-game flight of the bot.

SQLQuery

public java.sql.ResultSet SQLQuery(java.lang.String connectName,
                                   java.lang.String query)
                            throws java.sql.SQLException
Runs a direct SQL Query. This method does block up the bot from doing anything else, so be careful while using it. Queries should be quick. Only use it for queries where the performance of the bot depends primarily upon the value returned by this query.

Parameters:
connectName - The connection name as specified in sql.cfg
query - The SQL query to be executed
Returns:
ResultSet from the SQL Query.
Throws:
java.sql.SQLException - SQLException

SQLBackgroundQuery

public void SQLBackgroundQuery(java.lang.String connectName,
                               java.lang.String identifier,
                               java.lang.String query)
Runs a high priority backround SQL Query. This is the same as a normal background query, except these queries are executed first, if there are other queries in line to be executed. Use this only for time-important queries. Otherwise, let them flow along with the rest.

Parameters:
connectName - The connection name as specified in sql.cfg
identifier - A unique identifier that describes what this Query is. This identifier will be found in the SQLEvent when it is returned. This identifier helps you handle different sorts of background queries differently when they come out the other end. If the identifier is null, the result of the query will not be delivered.
query - The SQL query to be executed

SQLHighPriorityBackgroundQuery

public void SQLHighPriorityBackgroundQuery(java.lang.String connectName,
                                           java.lang.String identifier,
                                           java.lang.String query)
Runs a high priority background query. This query will be executed before all the others. This is useful for when you know the queue will be rather large, and you need a query done immediately.

Parameters:
connectName - The connection name as specified in sql.cfg
identifier - A unique identifier that describes what this Query is. This identifier will be found in the SQLEvent when it is returned. This identifier helps you handle different sorts of background queries differently when they come out the other end. If the identifier is null, the result of the query will not be delivered.
query - The SQL query to be executed

SQLInsertInto

public void SQLInsertInto(java.lang.String connectName,
                          java.lang.String tableName,
                          java.lang.String[] fields,
                          java.lang.String[] values)
Insert Into helper method.

Parameters:
connectName - The connection name as specified in sql.cfg
tableName - The name of the table you wish to insert the values into.
fields - The field names you want to enter data into.
values - The corresponding values for the field names.

SQLBackgroundInsertInto

public void SQLBackgroundInsertInto(java.lang.String connectName,
                                    java.lang.String tableName,
                                    java.lang.String[] fields,
                                    java.lang.String[] values)
Insert Into helper method.

Parameters:
connectName - The connection name as specified in sql.cfg
tableName - The name of the table you wish to insert the values into.
fields - The field names you want to enter data into.
values - The corresponding values for the field names.

requestArenaList

public void requestArenaList()
Sends out a request for an ArenaList packet to be sent back.


getEventRequester

public twcore.core.EventRequester getEventRequester()
Gets the EventRequester object. This object controls what events are being sent to the bot. EventRequester can turn on or off any events at any time.

Returns:
The EventRequester object for this bot.

ipcTransmit

public void ipcTransmit(java.lang.String channelName,
                        java.lang.Object o)
Transmits an object to the specified channel over inter-process communication. The object will arrive as an InterProcessEvent, which must be handled by the bot. If a bot is not yet subscribed to the channel, the bot will automatically be subscribed.

Parameters:
channelName - Channel name to send the object to.
o - Object to be transmitted

ipcSubscribe

public void ipcSubscribe(java.lang.String channelName)
Subscribes the current bot to the specified IPC Channel. Please remember you must not attempt to use this method in the constructor of a bot. This method must be used in the LoggedOn packet handler.

Parameters:
channelName - Name of the IPC channel you wish to subscribe to.

ipcUnSubscribe

public void ipcUnSubscribe(java.lang.String channelName)
Unsubscribes this bot from the provided channelName. If the bot was the last one on the channel, the channel is destroyed.

Parameters:
channelName - Name of the IPC channel you wish to unsubscribe from.

ipcDestroyChannel

public void ipcDestroyChannel(java.lang.String channelName)
Explicitly destroys a channel

Parameters:
channelName - The name of the channel to be destroyed

getIPC

public twcore.core.InterProcessCommunicator getIPC()

setDoors

public void setDoors(java.lang.String eightBinaryDigits)
Uses a binary string such as "11010110" to turn specific doors on or off.

Parameters:
eightBinaryDigits - Door state as a String

toggleWatchDamage

public void toggleWatchDamage(int playerID)
Toggles WatchDamage for this player.

Parameters:
playerID - PlayerID of the player

toggleWatchDamage

public void toggleWatchDamage(java.lang.String playerName)
Toggles WatchDamage for this player.

Parameters:
playerName - PlayerName of the player

getDataFile

public java.io.File getDataFile(java.lang.String filename)
Gets a file from the Data directory, given the filename as a String. Filename can a path relative to the data directory.

Parameters:
filename - Filename or pathname to the file in question.
Returns:
File object for the specified file.

getCoreCfg

public java.io.File getCoreCfg(java.lang.String filename)
Parameters:
filename -
Returns:

getCoreData

public twcore.core.CoreData getCoreData()

getCoreDirectory

public java.io.File getCoreDirectory()
Gets the directory the core is in as a File object. Specified by setup.cfg

Returns:
File object representing the directory the core is in

getCoreDirectoryFile

public java.io.File getCoreDirectoryFile(java.lang.String filename)
Gets a file from the core directory. May be a pathname relative to the core directory as well.

Parameters:
filename - Filename or pathname of the file or directory
Returns:
File representation of the object

setMessageLimit

public void setMessageLimit(int msgsPerMin)
Sets up spam protection for the bot. Indicate the number of messages per minute the player is allowed.

Parameters:
msgsPerMin - Number of messages per minute you want the bot to allow.

SQLisOperational

public boolean SQLisOperational()
If the SQL connection pools weren't initialized properly for some reason, this method will return false. Good for disabling portions of bots that use SQL.

Returns:
Boolean value representing the operational status of the SQL Connection pools.

setPacketSendDelay

public void setPacketSendDelay(int milliseconds)
Adjusts the packet send delay. The more packets that are sent out, the greater the possibility you'll overflow the 2500 packet/minute limit. The default setting is 75 ms. If your bot doesn't require a quick response, set it higher. If your bot requires a near-real time response, set it lower. The lower you set it the more packets will be sent from the bot.

Parameters:
milliseconds - Number of milliseconds between each packet.