-
Notifications
You must be signed in to change notification settings - Fork 1
Documentation: acserver
RonaldReagan edited this page Dec 7, 2013
·
1 revision
Main module for server interaction.
This module is the module that directly interacts with the server.
Methods defined here:
- acserver.log(str msg, [int]) -
- Logs a message, level defaults to info.
- acserver.msg(str msg, [int]) -
- Sends a message to a client, if cn is -1 (default) then it sends the message to all clients.
- acserver.killClient(int acn, int tcn [bool]) -
- Makes it as if acn killed tcn with given weapon, and specifies if it was gib or not
- acserver.spawnClient(int cn, int health, [int]) -
- Spawn client with specified starting stats.
- acserver.getClient(int cn) -
- Returns a dictionary with client stats
- acserver.getCmdLineOptions()
- Returns a dictionary with all of the server commandline options.
- acserver.getAdminPasswords()
- Returns a tuple of all of the admin passwords. Return value is structured like:
(
(str password,int linenumber, bool denyadmin),
(...)
)- acserver.getGameMillis()
- Returns the time spent in the current game
- acserver.getMinRemain()
- Returns the minutes remaining
- acserver.getServMillis()
- Returns the number of milliseconds that the server has been running.
- acserver.getMaprot()
- Returns a tuple of all of the maprot entries. Return value is structured like:
(
(str mapname, int mode, int time, int vote, int minplayer, int maxplayer, int skiplines)
(...)
)- acserver.clearMaprot()
- Clears the maprot. **WARNING**, if you do not fill it up with at least one valid map, this will fail with a fatal error.
- acserver.addMapToRot(str mapname,int mode, int time, int vote, [int]) -
- Adds maprot entry to the maprot