R:/projects/actioncube/_svn/trunk/ac/source/src/clientgame.cpp File Reference

#include "pch.h"
#include "cube.h"
#include "bot/bot.h"

Include dependency graph for clientgame.cpp:


Classes

struct  scriptsleep
struct  gmdesc
struct  mline

Defines

#define SECURESPAWNDIST   15

Functions

 VAR (gamemode, 1, 0, 0)
 VARP (modeacronyms, 0, 0, 1)
void mode (int n)
 COMMAND (mode, ARG_1INT)
char * getclientmap ()
void mapname ()
 COMMAND (mapname, ARG_NONE)
void setskin (playerent *pl, uint skin)
bool duplicatename (playerent *d, char *name=NULL)
char * colorname (playerent *d, int num, char *name, const char *prefix)
char * colorping (int ping)
void newname (const char *name)
int smallerteam ()
void changeteam (int team, bool respawn)
void newteam (char *name)
 VARNP (skin, nextskin, 0, 0, 1000)
int curteam ()
int currole ()
int curmode ()
void curmap (int cleaned)
 COMMANDN (team, newteam, ARG_1STR)
 COMMANDN (name, newname, ARG_1STR)
 COMMAND (curteam, ARG_IVAL)
 COMMAND (currole, ARG_IVAL)
 COMMAND (curmode, ARG_IVAL)
 COMMAND (curmap, ARG_1INT)
 VARP (showscoresondeath, 0, 1, 1)
 VARP (autoscreenshot, 0, 0, 1)
void deathstate (playerent *pl)
void spawnstate (playerent *d)
playerent * newplayerent ()
botent * newbotent ()
void freebotent (botent *d)
void zapplayer (playerent *&d)
void movelocalplayer ()
 VARP (smoothmove, 0, 75, 100)
 VARP (smoothdist, 0, 8, 16)
void predictplayer (playerent *d, bool move)
void moveotherplayers ()
bool showhudtimer (int maxsecs, int startmillis, const char *msg, bool flash)
void showrespawntimer ()
void addsleep (int msec, const char *cmd)
void addsleep_ (char *msec, char *cmd)
void resetsleep ()
 COMMANDN (sleep, addsleep_, ARG_2STR)
void updateworld (int curtime, int lastmillis)
float nearestenemy (vec place, char *team)
void findplayerstart (playerent *d, bool mapcenter, int arenaspawn)
void spawnplayer (playerent *d)
void respawnself ()
bool tryrespawn ()
void dodamage (int damage, playerent *pl, playerent *actor, bool gib, bool local)
void dokill (playerent *pl, playerent *act, bool gib)
 VAR (minutesremaining, 1, 0, 0)
void timeupdate (int timeremain)
playerent * newclient (int cn)
playerent * getclient (int cn)
void initclient ()
void initflag (int i)
void zapplayerflags (playerent *p)
void preparectf (bool cleanonly=false)
void gamemodedesc (char *modenr, char *desc)
 COMMAND (gamemodedesc, ARG_2STR)
void resetmap ()
void startmap (const char *name, bool reset)
void suicide ()
 COMMAND (suicide, ARG_NONE)
void flagmsg (int flag, int message, int actor, int flagtime)
void dropflag ()
 COMMAND (dropflag, ARG_NONE)
char * votestring (int type, char *arg1, char *arg2)
votedisplayinfo * newvotedisplayinfo (playerent *owner, int type, char *arg1, char *arg2)
void callvote (int type, char *arg1, char *arg2)
void scallvote (char *type, char *arg1, char *arg2)
void vote (int v)
void displayvote (votedisplayinfo *v)
void callvotesuc ()
void callvoteerr (int e)
void votecount (int v)
void voteresult (int v)
void clearvote ()
 COMMANDN (callvote, scallvote, ARG_3STR)
 COMMAND (vote, ARG_1INT)
void cleanplayervotes (playerent *p)
void whois (int cn)
 COMMAND (whois, ARG_1INT)
void setadmin (char *claim, char *password)
 COMMAND (setadmin, ARG_2STR)
void changemap (const char *name)
void refreshsopmenu (void *menu, bool init)
playerent * updatefollowplayer (int shiftdirection)
void spectate (int mode)
void togglespect ()
void changefollowplayer (int shift)
 COMMAND (spectate, ARG_1INT)
 COMMAND (togglespect, ARG_NONE)
 COMMAND (changefollowplayer, ARG_1INT)
int isalive ()
 COMMANDN (alive, isalive, ARG_IVAL)
void serverextension (char *ext, char *args)
 COMMAND (serverextension, ARG_2STR)

Variables

int nextmode = 0
flaginfo flaginfos [2]
bool intermission = false
bool autoteambalance = false
int arenaintermission = 0
playerent * player1 = newplayerent()
vector< playerent * > players
int lastmillis = 0
int totalmillis = 0
int curtime = 0
string clientmap
int framesinmap
bool c2sinit
bool senditemstoserver
int lastspawnattempt = 0
vector< scriptsleep > sleeps
int spawncycle = -1
int fixspawn = 2
entity flagdummies [2]
vector< gmdesc > gmdescs
int suicided = -1
votedisplayinfo * curvote = NULL
votedisplayinfo * calledvote = NULL
int sessionid = 0
static vector< mline > mlines
void * kickmenu = NULL
void * banmenu = NULL
void * forceteammenu = NULL
void * giveadminmenu = NULL
bool watchingdemo

Define Documentation

#define SECURESPAWNDIST   15


Function Documentation

void addsleep ( int  msec,
const char *  cmd 
)

void addsleep_ ( char *  msec,
char *  cmd 
)

void callvote ( int  type,
char *  arg1,
char *  arg2 
)

void callvoteerr ( int  e  ) 

void callvotesuc (  ) 

void changefollowplayer ( int  shift  ) 

void changemap ( const char *  name  ) 

void changeteam ( int  team,
bool  respawn 
)

void cleanplayervotes ( playerent *  p  ) 

void clearvote (  ) 

char* colorname ( playerent *  d,
int  num,
char *  name,
const char *  prefix 
)

char* colorping ( int  ping  ) 

COMMAND ( serverextension  ,
ARG_2STR   
)

COMMAND ( changefollowplayer  ,
ARG_1INT   
)

COMMAND ( togglespect  ,
ARG_NONE   
)

COMMAND ( spectate  ,
ARG_1INT   
)

COMMAND ( setadmin  ,
ARG_2STR   
)

COMMAND ( whois  ,
ARG_1INT   
)

COMMAND ( vote  ,
ARG_1INT   
)

COMMAND ( dropflag  ,
ARG_NONE   
)

COMMAND ( suicide  ,
ARG_NONE   
)

COMMAND ( gamemodedesc  ,
ARG_2STR   
)

COMMAND ( curmap  ,
ARG_1INT   
)

COMMAND ( curmode  ,
ARG_IVAL   
)

COMMAND ( currole  ,
ARG_IVAL   
)

COMMAND ( curteam  ,
ARG_IVAL   
)

COMMAND ( mapname  ,
ARG_NONE   
)

COMMAND ( mode  ,
ARG_1INT   
)

COMMANDN ( alive  ,
isalive  ,
ARG_IVAL   
)

COMMANDN ( callvote  ,
scallvote  ,
ARG_3STR   
)

COMMANDN ( sleep  ,
addsleep_  ,
ARG_2STR   
)

COMMANDN ( name  ,
newname  ,
ARG_1STR   
)

COMMANDN ( team  ,
newteam  ,
ARG_1STR   
)

void curmap ( int  cleaned  ) 

int curmode (  ) 

int currole (  ) 

int curteam (  ) 

void deathstate ( playerent *  pl  ) 

void displayvote ( votedisplayinfo *  v  ) 

void dodamage ( int  damage,
playerent *  pl,
playerent *  actor,
bool  gib,
bool  local 
)

void dokill ( playerent *  pl,
playerent *  act,
bool  gib 
)

void dropflag (  ) 

bool duplicatename ( playerent *  d,
char *  name = NULL 
)

void findplayerstart ( playerent *  d,
bool  mapcenter,
int  arenaspawn 
)

void flagmsg ( int  flag,
int  message,
int  actor,
int  flagtime 
)

void freebotent ( botent *  d  ) 

void gamemodedesc ( char *  modenr,
char *  desc 
)

playerent* getclient ( int  cn  ) 

char* getclientmap (  ) 

void initclient (  ) 

void initflag ( int  i  ) 

int isalive (  ) 

void mapname (  ) 

void mode ( int  n  ) 

void movelocalplayer (  ) 

void moveotherplayers (  ) 

float nearestenemy ( vec  place,
char *  team 
)

botent* newbotent (  ) 

playerent* newclient ( int  cn  ) 

void newname ( const char *  name  ) 

playerent* newplayerent (  ) 

void newteam ( char *  name  ) 

votedisplayinfo* newvotedisplayinfo ( playerent *  owner,
int  type,
char *  arg1,
char *  arg2 
)

void predictplayer ( playerent *  d,
bool  move 
)

void preparectf ( bool  cleanonly = false  ) 

void refreshsopmenu ( void *  menu,
bool  init 
)

void resetmap (  ) 

void resetsleep (  ) 

void respawnself (  ) 

void scallvote ( char *  type,
char *  arg1,
char *  arg2 
)

void serverextension ( char *  ext,
char *  args 
)

void setadmin ( char *  claim,
char *  password 
)

void setskin ( playerent *  pl,
uint  skin 
)

bool showhudtimer ( int  maxsecs,
int  startmillis,
const char *  msg,
bool  flash 
)

void showrespawntimer (  ) 

int smallerteam (  ) 

void spawnplayer ( playerent *  d  ) 

void spawnstate ( playerent *  d  ) 

void spectate ( int  mode  ) 

void startmap ( const char *  name,
bool  reset 
)

void suicide (  ) 

void timeupdate ( int  timeremain  ) 

void togglespect (  ) 

bool tryrespawn (  ) 

playerent* updatefollowplayer ( int  shiftdirection  ) 

void updateworld ( int  curtime,
int  lastmillis 
)

VAR ( minutesremaining  ,
1  ,
0  ,
0   
)

VAR ( gamemode  ,
1  ,
0  ,
0   
)

VARNP ( skin  ,
nextskin  ,
0  ,
0  ,
1000   
)

VARP ( smoothdist  ,
0  ,
8  ,
16   
)

VARP ( smoothmove  ,
0  ,
75  ,
100   
)

VARP ( autoscreenshot  ,
0  ,
0  ,
1   
)

VARP ( showscoresondeath  ,
0  ,
1  ,
1   
)

VARP ( modeacronyms  ,
0  ,
0  ,
1   
)

void vote ( int  v  ) 

void votecount ( int  v  ) 

void voteresult ( int  v  ) 

char* votestring ( int  type,
char *  arg1,
char *  arg2 
)

void whois ( int  cn  ) 

void zapplayer ( playerent *&  d  ) 

void zapplayerflags ( playerent *  p  ) 


Variable Documentation

bool autoteambalance = false

void * banmenu = NULL

bool c2sinit

int curtime = 0

int fixspawn = 2

Initial value:

 
{
    entity(-1, -1, -1, CTF_FLAG, 0, 0, 0, 0),
    entity(-1, -1, -1, CTF_FLAG, 0, 1, 0, 0)
}

void * forceteammenu = NULL

void * giveadminmenu = NULL

bool intermission = false

void* kickmenu = NULL

int lastmillis = 0

vector<mline> mlines [static]

int nextmode = 0

playerent* player1 = newplayerent()

int sessionid = 0

int spawncycle = -1

int suicided = -1

int totalmillis = 0


Generated on Mon Dec 8 21:41:31 2008 for AssaultCube by  doxygen 1.5.7.1