codemp/game/g_team.h

Go to the documentation of this file.
00001 // Copyright (C) 1999-2000 Id Software, Inc.
00002 //
00003 
00004 #define CTF_CAPTURE_BONUS               100             // what you get for capture
00005 #define CTF_TEAM_BONUS                  25              // what your team gets for capture
00006 #define CTF_RECOVERY_BONUS              10              // what you get for recovery
00007 #define CTF_FLAG_BONUS                  10              // what you get for picking up enemy flag
00008 #define CTF_FRAG_CARRIER_BONUS  20              // what you get for fragging enemy flag carrier
00009 #define CTF_FLAG_RETURN_TIME    40000   // seconds until auto return
00010 
00011 #define CTF_CARRIER_DANGER_PROTECT_BONUS        5       // bonus for fraggin someone who has recently hurt your flag carrier
00012 #define CTF_CARRIER_PROTECT_BONUS                       2       // bonus for fraggin someone while either you or your target are near your flag carrier
00013 #define CTF_FLAG_DEFENSE_BONUS                          10      // bonus for fraggin someone while either you or your target are near your flag
00014 #define CTF_RETURN_FLAG_ASSIST_BONUS            10      // awarded for returning a flag that causes a capture to happen almost immediately
00015 #define CTF_FRAG_CARRIER_ASSIST_BONUS           10      // award for fragging a flag carrier if a capture happens almost immediately
00016 
00017 #define CTF_TARGET_PROTECT_RADIUS                       1000    // the radius around an object being defended where a target will be worth extra frags
00018 #define CTF_ATTACKER_PROTECT_RADIUS                     1000    // the radius around an object being defended where an attacker will get extra frags when making kills
00019 
00020 #define CTF_CARRIER_DANGER_PROTECT_TIMEOUT      8000
00021 #define CTF_FRAG_CARRIER_ASSIST_TIMEOUT         10000
00022 #define CTF_RETURN_FLAG_ASSIST_TIMEOUT          10000
00023 
00024 #define CTF_GRAPPLE_SPEED                                       750 // speed of grapple in flight
00025 #define CTF_GRAPPLE_PULL_SPEED                          750     // speed player is pulled at
00026 
00027 #define OVERLOAD_ATTACK_BASE_SOUND_TIME         20000
00028 
00029 // Prototypes
00030 
00031 int OtherTeam(int team);
00032 const char *TeamName(int team);
00033 const char *OtherTeamName(int team);
00034 const char *TeamColorString(int team);
00035 void AddTeamScore(vec3_t origin, int team, int score);
00036 
00037 void Team_DroppedFlagThink(gentity_t *ent);
00038 void Team_FragBonuses(gentity_t *targ, gentity_t *inflictor, gentity_t *attacker);
00039 void Team_CheckHurtCarrier(gentity_t *targ, gentity_t *attacker);
00040 void Team_InitGame(void);
00041 void Team_ReturnFlag(int team);
00042 void Team_FreeEntity(gentity_t *ent);
00043 gentity_t *SelectCTFSpawnPoint ( team_t team, int teamstate, vec3_t origin, vec3_t angles );
00044 gentity_t *SelectSiegeSpawnPoint ( int siegeClass, team_t team, int teamstate, vec3_t origin, vec3_t angles );
00045 gentity_t *Team_GetLocation(gentity_t *ent);
00046 qboolean Team_GetLocationMsg(gentity_t *ent, char *loc, int loclen);
00047 void TeamplayInfoMessage( gentity_t *ent );
00048 void CheckTeamStatus(void);
00049 
00050 int Pickup_Team( gentity_t *ent, gentity_t *other );