1 /* 2 =========================================================================== 3 Copyright (C) 1999 - 2005, Id Software, Inc. 4 Copyright (C) 2000 - 2013, Raven Software, Inc. 5 Copyright (C) 2001 - 2013, Activision, Inc. 6 Copyright (C) 2013 - 2015, OpenJK contributors 7 8 This file is part of the OpenJK source code. 9 10 OpenJK is free software; you can redistribute it and/or modify it 11 under the terms of the GNU General Public License version 2 as 12 published by the Free Software Foundation. 13 14 This program is distributed in the hope that it will be useful, 15 but WITHOUT ANY WARRANTY; without even the implied warranty of 16 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 17 GNU General Public License for more details. 18 19 You should have received a copy of the GNU General Public License 20 along with this program; if not, see <http://www.gnu.org/licenses/>. 21 =========================================================================== 22 */ 23 24 #pragma once 25 26 #define CTF_CAPTURE_BONUS 100 // what you get for capture 27 #define CTF_TEAM_BONUS 25 // what your team gets for capture 28 #define CTF_RECOVERY_BONUS 10 // what you get for recovery 29 #define CTF_FLAG_BONUS 10 // what you get for picking up enemy flag 30 #define CTF_FRAG_CARRIER_BONUS 20 // what you get for fragging enemy flag carrier 31 #define CTF_FLAG_RETURN_TIME 40000 // seconds until auto return 32 33 #define CTF_CARRIER_DANGER_PROTECT_BONUS 5 // bonus for fraggin someone who has recently hurt your flag carrier 34 #define CTF_CARRIER_PROTECT_BONUS 2 // bonus for fraggin someone while either you or your target are near your flag carrier 35 #define CTF_FLAG_DEFENSE_BONUS 10 // bonus for fraggin someone while either you or your target are near your flag 36 #define CTF_RETURN_FLAG_ASSIST_BONUS 10 // awarded for returning a flag that causes a capture to happen almost immediately 37 #define CTF_FRAG_CARRIER_ASSIST_BONUS 10 // award for fragging a flag carrier if a capture happens almost immediately 38 39 #define CTF_TARGET_PROTECT_RADIUS 1000 // the radius around an object being defended where a target will be worth extra frags 40 #define CTF_ATTACKER_PROTECT_RADIUS 1000 // the radius around an object being defended where an attacker will get extra frags when making kills 41 42 #define CTF_CARRIER_DANGER_PROTECT_TIMEOUT 8000 43 #define CTF_FRAG_CARRIER_ASSIST_TIMEOUT 10000 44 #define CTF_RETURN_FLAG_ASSIST_TIMEOUT 10000 45 46 #define CTF_GRAPPLE_SPEED 750 // speed of grapple in flight 47 #define CTF_GRAPPLE_PULL_SPEED 750 // speed player is pulled at 48 49 #define OVERLOAD_ATTACK_BASE_SOUND_TIME 20000 50 51 // Prototypes 52 53 int OtherTeam(int team); 54 const char *TeamName(int team); 55 const char *OtherTeamName(int team); 56 const char *TeamColorString(int team); 57 void AddTeamScore(vec3_t origin, int team, int score); 58 59 void Team_DroppedFlagThink(gentity_t *ent); 60 void Team_FragBonuses(gentity_t *targ, gentity_t *inflictor, gentity_t *attacker); 61 void Team_CheckHurtCarrier(gentity_t *targ, gentity_t *attacker); 62 void Team_InitGame(void); 63 void Team_ReturnFlag(int team); 64 void Team_FreeEntity(gentity_t *ent); 65 gentity_t *SelectCTFSpawnPoint ( team_t team, int teamstate, vec3_t origin, vec3_t angles, qboolean isbot ); 66 gentity_t *SelectSiegeSpawnPoint ( int siegeClass, team_t team, int teamstate, vec3_t origin, vec3_t angles, qboolean isbot ); 67 locationData_t *Team_GetLocation(gentity_t *ent); 68 qboolean Team_GetLocationMsg(gentity_t *ent, char *loc, int loclen); 69 void TeamplayInfoMessage( gentity_t *ent ); 70 void CheckTeamStatus(void); 71 72 int Pickup_Team( gentity_t *ent, gentity_t *other ); 73