mirror of
https://github.com/ReactionQuake3/reaction.git
synced 2024-11-26 22:21:16 +00:00
Removed the zcam defines again and did some cleanups
This commit is contained in:
parent
08555edb8d
commit
468c0073ee
1 changed files with 197 additions and 293 deletions
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.63 2002/04/02 00:56:18 jbravo
|
||||
// Removed the zcam defines again and did some cleanups
|
||||
//
|
||||
// Revision 1.62 2002/04/01 22:23:14 slicer
|
||||
// Added "weapon" command buffering | Solved Gren Mode Bug
|
||||
//
|
||||
|
@ -105,10 +108,6 @@
|
|||
|
||||
// the "gameversion" client command will print this plus compile date
|
||||
#define GAMEVERSION "reaction"
|
||||
|
||||
// NiceAss: Took it out until later.
|
||||
#define __ZCAM__
|
||||
|
||||
#define BODY_QUEUE_SIZE 8
|
||||
|
||||
// JBravo: Max number of killed enemys to track
|
||||
|
@ -125,8 +124,7 @@
|
|||
// Let's enforce that in-code because it's sometimes 7 or even 8
|
||||
// Elder: LOL it's 3, dumb Elder!
|
||||
#define BLEED_BANDAGE 3
|
||||
//#define BLEED_BANDAGE_TIME 5400 // 27 x 2
|
||||
#define BLEED_BANDAGE_TIME 5600 // 27 x 2
|
||||
#define BLEED_BANDAGE_TIME 5400 // 27 x 2
|
||||
|
||||
// types of locations that can be hit
|
||||
#define LOC_HDAM 1 // head
|
||||
|
@ -173,12 +171,9 @@ typedef enum {
|
|||
} moverState_t;
|
||||
|
||||
#define SP_PODIUM_MODEL "models/mapobjects/podium/podium4.md3"
|
||||
|
||||
#define RQ3_RESPAWNTIME_DEFAULT 60000 // Elder: time for weapons to respawn - up to 60s
|
||||
|
||||
#define SP_AUTOOPEN 4 // Elder: revert to Q3 behaviour
|
||||
#define SP_DOORTOGGLE 8 // Elder: added to enable mover toggling
|
||||
|
||||
#define MAXDOORTIME 100 // Elder: max time the opendoor key can stay open
|
||||
|
||||
//============================================================================
|
||||
|
@ -195,12 +190,9 @@ struct gentity_s {
|
|||
//================================
|
||||
|
||||
struct gclient_s *client; // NULL if not a client
|
||||
|
||||
qboolean inuse;
|
||||
|
||||
char *classname; // set in QuakeEd
|
||||
int spawnflags; // set in QuakeEd
|
||||
|
||||
qboolean neverFree; // if true, FreeEntity will only unlink
|
||||
// bodyque uses this
|
||||
// JBravo: adding func_explosive
|
||||
|
@ -210,24 +202,19 @@ struct gentity_s {
|
|||
int bounce;
|
||||
int material;
|
||||
int size;
|
||||
|
||||
int flags; // FL_* variables
|
||||
|
||||
char *model;
|
||||
char *model2;
|
||||
int freetime; // level.time when the object was freed
|
||||
|
||||
int eventTime; // events will be cleared EVENT_VALID_MSEC after set
|
||||
qboolean freeAfterEvent;
|
||||
qboolean unlinkAfterEvent;
|
||||
|
||||
qboolean physicsObject; // if true, it can be pushed by movers and fall off edges
|
||||
// all game items are physicsObjects,
|
||||
float physicsBounce; // 1.0 = continuous bounce, 0.0 = no bounce
|
||||
int clipmask; // brushes with this content value will be collided against
|
||||
// when moving. items and corpses do not collide against
|
||||
// players, for instance
|
||||
|
||||
// movers
|
||||
moverState_t moverState;
|
||||
int soundPos1;
|
||||
|
@ -239,11 +226,8 @@ struct gentity_s {
|
|||
gentity_t *nextTrain;
|
||||
gentity_t *prevTrain;
|
||||
vec3_t pos1, pos2;
|
||||
|
||||
char *message;
|
||||
|
||||
int timestamp; // body queue sinking, etc
|
||||
|
||||
float angle; // set in editor, -1 = up, -2 = down
|
||||
char *target;
|
||||
char *targetname;
|
||||
|
@ -265,23 +249,17 @@ struct gentity_s {
|
|||
void (*use)(gentity_t *self, gentity_t *other, gentity_t *activator);
|
||||
void (*pain)(gentity_t *self, gentity_t *attacker, int damage);
|
||||
void (*die)(gentity_t *self, gentity_t *inflictor, gentity_t *attacker, int damage, int mod);
|
||||
|
||||
int pain_debounce_time;
|
||||
int fly_sound_debounce_time; // wind tunnel
|
||||
int last_move_time;
|
||||
|
||||
int health;
|
||||
|
||||
qboolean takedamage;
|
||||
|
||||
int damage;
|
||||
int splashDamage; // quad will increase this without increasing radius
|
||||
int splashRadius;
|
||||
int methodOfDeath;
|
||||
int splashMethodOfDeath;
|
||||
|
||||
int count;
|
||||
|
||||
gentity_t *chain;
|
||||
gentity_t *enemy;
|
||||
gentity_t *activator;
|
||||
|
@ -295,16 +273,13 @@ struct gentity_s {
|
|||
|
||||
int watertype;
|
||||
int waterlevel;
|
||||
|
||||
int noise_index;
|
||||
|
||||
// timing variables
|
||||
float wait;
|
||||
float random;
|
||||
|
||||
gitem_t *item; // for bonus items
|
||||
float distance; // VALKYRIE: for rotating door
|
||||
|
||||
};
|
||||
|
||||
|
||||
|
@ -318,11 +293,9 @@ typedef enum {
|
|||
SPECTATOR_NOT,
|
||||
SPECTATOR_FREE,
|
||||
SPECTATOR_FOLLOW,
|
||||
#ifdef __ZCAM__
|
||||
SPECTATOR_ZCAM,
|
||||
SPECTATOR_CAMERA_FLIC,
|
||||
SPECTATOR_CAMERA_SWING,
|
||||
#endif
|
||||
SPECTATOR_SCOREBOARD
|
||||
} spectatorState_t;
|
||||
|
||||
|
@ -333,16 +306,13 @@ typedef enum {
|
|||
|
||||
typedef struct {
|
||||
playerTeamStateState_t state;
|
||||
|
||||
int location;
|
||||
|
||||
int captures;
|
||||
int basedefense;
|
||||
int carrierdefense;
|
||||
int flagrecovery;
|
||||
int fragcarrier;
|
||||
int assists;
|
||||
|
||||
float lasthurtcarrier;
|
||||
float lastreturnedflag;
|
||||
float flagsince;
|
||||
|
@ -397,7 +367,6 @@ typedef struct {
|
|||
int voteCount; // to prevent people from constantly calling votes
|
||||
int teamVoteCount; // to prevent people from constantly calling votes
|
||||
qboolean teamInfo; // send team overlay updates?
|
||||
|
||||
qboolean hadUniqueWeapon[MAX_WEAPONS]; //Elder: for "ammo" in last gun
|
||||
|
||||
int sayTime; // Elder: say validation stuff
|
||||
|
@ -406,13 +375,10 @@ typedef struct {
|
|||
int sayBans;
|
||||
int sayMuteTime;
|
||||
qboolean sayModerated; // so warnings are not repeated for multi-line, same-frame messages
|
||||
|
||||
int records[REC_NUM_RECORDS]; // Elder: for our statistics tracking
|
||||
} clientPersistant_t;
|
||||
|
||||
#ifdef __ZCAM__
|
||||
struct camera_s;
|
||||
#endif /* __ZCAM__ */
|
||||
|
||||
// Elder: spam prevention defaults
|
||||
/*
|
||||
|
@ -442,24 +408,18 @@ typedef enum
|
|||
struct gclient_s {
|
||||
// ps MUST be the first element, because the server expects it
|
||||
playerState_t ps; // communicated by server to clients
|
||||
|
||||
// the rest of the structure is private to game
|
||||
clientPersistant_t pers;
|
||||
clientSession_t sess;
|
||||
|
||||
qboolean readyToExit; // wishes to leave the intermission
|
||||
|
||||
qboolean noclip;
|
||||
|
||||
int lastCmdTime; // level.time of last usercmd_t, for EF_CONNECTION
|
||||
// we can't just use pers.lastCommand.time, because
|
||||
// of the g_sycronousclients case
|
||||
int buttons;
|
||||
int oldbuttons;
|
||||
int latched_buttons;
|
||||
|
||||
vec3_t oldOrigin;
|
||||
|
||||
// sum up damage over an entire frame, so
|
||||
// shotgun blasts give a single big kick
|
||||
int damage_armor; // damage absorbed by armor
|
||||
|
@ -468,36 +428,9 @@ struct gclient_s {
|
|||
vec3_t damage_from; // origin for vector calculation
|
||||
qboolean damage_fromWorld; // if true, don't use the damage_from vector
|
||||
//qboolean damage_vest; // Elder: if true, play the vest-hit sound
|
||||
|
||||
int accurateCount; // for "impressive" reward sound
|
||||
|
||||
int accuracy_shots; // total number of shots
|
||||
int accuracy_hits; // total number of hits
|
||||
//Blaze: For weapon stats
|
||||
//Will need to pass these along in g_client to the new client after spawn
|
||||
// Elder: to be merged into rq3Record_t for more comprehensive tracking
|
||||
/*
|
||||
int knifeShots;
|
||||
int knifeHits;
|
||||
int mk23Shots;
|
||||
int mk23Hits;
|
||||
int m4Shots;
|
||||
int m4Hits;
|
||||
int mp5Shots;
|
||||
int mp5Hits;
|
||||
int m3Shots;
|
||||
int m3Hits;
|
||||
int hcShots;
|
||||
int hcHits;
|
||||
int ssgShots;
|
||||
int ssgHits;
|
||||
int akimboShots;
|
||||
int akimboHits;
|
||||
int grenShots;
|
||||
int grenHits;
|
||||
*/
|
||||
|
||||
// int lastkilled_client; // last client that this client killed
|
||||
gentity_t *lastkilled_client[5]; // JBravo: last 5 clients that this client killed
|
||||
int num_kills; // JBravo: Number of killed players in TP.
|
||||
int lasthurt_client; // last client that damaged this client
|
||||
|
@ -505,40 +438,30 @@ struct gclient_s {
|
|||
//Slicer
|
||||
int weapon_attempts;
|
||||
qboolean weapon_after_bandage_warned;
|
||||
|
||||
// Begin Duffman
|
||||
int lasthurt_location; // Where the client was hit.
|
||||
// End Duffman
|
||||
|
||||
// timers
|
||||
int respawnTime; // can respawn when time > this, force after g_forcerespwan
|
||||
int inactivityTime; // kick players when time > this
|
||||
qboolean inactivityWarning; // qtrue if the five seoond warning has been given
|
||||
int rewardTime; // clear the EF_AWARD_IMPRESSIVE, etc when time > this
|
||||
|
||||
int airOutTime;
|
||||
|
||||
int lastKillTime; // for multiple kill rewards
|
||||
|
||||
qboolean fireHeld; // used for hook
|
||||
gentity_t *hook; // grapple hook if out
|
||||
|
||||
int switchTeamTime; // time the player switched teams
|
||||
// Begin Duffman
|
||||
int numClips[MAX_WEAPONS]; // Number of clips each weapon has
|
||||
// End Duffman
|
||||
int weaponCount[WP_NUM_WEAPONS]; // Elder: for duplicate unique weapon tracking
|
||||
|
||||
int openDoor; //Blaze: used to hold if someone has hit opendoor key
|
||||
int openDoorTime;
|
||||
|
||||
// timeResidual is used to handle events that happen every second
|
||||
// like health / armor countdowns and regeneration
|
||||
int timeResidual;
|
||||
|
||||
//Elder: C3A laser tutorial
|
||||
gentity_t *lasersight; // lasersight OR flashlight if in use
|
||||
|
||||
// Bleeding server-only cvars
|
||||
int bleeding; // Blaze: remaining points to bleed away
|
||||
int bleed_remain; // Blaze: How much left to bleed
|
||||
|
@ -551,21 +474,17 @@ struct gclient_s {
|
|||
int bleedtick; // Blaze: Holds # of seconds till bleeding stops.
|
||||
int bleedBandageCount; // Elder: hack to restrict amount of bleeding to 3 points
|
||||
int headShotTime; // Elder: got headshot?
|
||||
|
||||
//Elder: server only needs to know for sniper spread - ARGH
|
||||
// int zoomed; // Hawkins (SSG zoom)
|
||||
//qboolean semi; // hawkins (semiauto mode for m4, mp5, pistol)
|
||||
int shots; // Blaze: Number of shots fired so far with this weapon
|
||||
|
||||
int weaponfireNextTime; // for akimbos
|
||||
int lastzoom; // Elder: save last zoom state when firing
|
||||
|
||||
// These are now obsolete with the new reload code
|
||||
int fastReloads; // Elder: for queuing M3/SSG reloads
|
||||
int lastReloadTime; // Elder: for queuing M3/SSG reloads
|
||||
int reloadAttempts; // Elder: for queuing M3/SSG reloads
|
||||
int reloadStage; // Elder: 0, 1, 2 for sound queuing - move to stats?
|
||||
|
||||
int consecutiveShots; // Elder: for M4 ride-up/kick
|
||||
int uniqueWeapons; // Elder: formerly a stat, now just a server var
|
||||
int uniqueItems;
|
||||
|
@ -581,9 +500,7 @@ struct gclient_s {
|
|||
#endif
|
||||
|
||||
char *areabits;
|
||||
#ifdef __ZCAM__
|
||||
struct camera_s *camera;
|
||||
#endif /* __ZCAM__ */
|
||||
// JBravo adding TP stuff
|
||||
int specMode;
|
||||
int teamplayWeapon;
|
||||
|
@ -608,42 +525,29 @@ struct gclient_s {
|
|||
|
||||
typedef struct {
|
||||
struct gclient_s *clients; // [maxclients]
|
||||
|
||||
struct gentity_s *gentities;
|
||||
int gentitySize;
|
||||
int num_entities; // current number, <= MAX_GENTITIES
|
||||
|
||||
int warmupTime; // restart match at this time
|
||||
|
||||
fileHandle_t logFile;
|
||||
|
||||
// store latched cvars here that we want to get at often
|
||||
int maxclients;
|
||||
|
||||
int framenum;
|
||||
int time; // in msec
|
||||
int previousTime; // so movers can back up when blocked
|
||||
|
||||
int startTime; // level.time the map was started
|
||||
|
||||
int teamScores[TEAM_NUM_TEAMS];
|
||||
int lastTeamLocationTime; // last time of client team location update
|
||||
|
||||
qboolean newSession; // don't use any old session data, because
|
||||
// we changed gametype
|
||||
|
||||
qboolean restarted; // waiting for a map_restart to fire
|
||||
|
||||
int numConnectedClients;
|
||||
int numNonSpectatorClients; // includes connecting clients
|
||||
int numPlayingClients; // connected, non-spectators
|
||||
int sortedClients[MAX_CLIENTS]; // sorted by score
|
||||
int follow1, follow2; // clientNums for auto-follow spectators
|
||||
|
||||
int snd_fry; // sound index for standing in lava
|
||||
|
||||
int warmupModificationCount; // for detecting if g_warmup is changed
|
||||
|
||||
// voting state
|
||||
char voteString[MAX_STRING_CHARS];
|
||||
char voteDisplayString[MAX_STRING_CHARS];
|
||||
|
|
Loading…
Reference in a new issue