Xonotic
sv_ctf.qh File Reference
+ Include dependency graph for sv_ctf.qh:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  Flag
 

Macros

#define CTF_DIFFTEAM(a, b)   ((autocvar_g_ctf_reverse || (ctf_oneflag && autocvar_g_ctf_oneflag_reverse)) ? SAME_TEAM(a,b) : DIFF_TEAM(a,b))
 
#define CTF_SAMETEAM(a, b)   ((autocvar_g_ctf_reverse || (ctf_oneflag && autocvar_g_ctf_oneflag_reverse)) ? DIFF_TEAM(a,b) : SAME_TEAM(a,b))
 
#define ctf_spawnorigin   dropped_origin
 
#define FLAG_SPAWN_OFFSET   ('0 0 1' * (PL_MAX_CONST.z - 13))
 
#define snd_flag_capture   noise2
 
#define snd_flag_respawn   noise3
 
#define snd_flag_returned   noise1
 
#define snd_flag_taken   noise
 
#define WPCOLOR_DROPPEDFLAG(t)   ((t) ? ('0.25 0.25 0.25' + colormapPaletteColor(t - 1, false)) * 0.5 : '1 1 1')
 
#define WPCOLOR_ENEMYFC(t)   ((t) ? colormapPaletteColor(t - 1, false) * 0.75 : '1 1 1')
 
#define WPCOLOR_FLAGCARRIER(t)   ((t) ? colormapPaletteColor(t - 1, false) * 0.75 : '1 1 1')
 

Functions

void ctf_FlagTouch (entity this, entity toucher)
 
void ctf_Handle_Throw (entity player, entity receiver, float droptype)
 
void ctf_Initialize ()
 
void ctf_RespawnFlag (entity flag)
 
bool ctf_Stalemate_Customize (entity this, entity client)
 
void havocbot_role_ctf_setrole (entity bot, int role)
 
 REGISTER_MUTATOR (ctf, false)
 

Variables

int autocvar_captureleadlimit_override
 
int autocvar_capturelimit_override
 
string capeffect
 
const int CAPTURE_DROPPED = 2
 
const int CAPTURE_NORMAL = 1
 
float ctf_captimerecord
 
float ctf_captureshield_force
 
float ctf_captureshield_max_ratio
 
float ctf_captureshield_min_negscore
 
bool ctf_captureshielded
 
entity ctf_dropper
 
float ctf_droptime
 
Flag CTF_FLAG
 
bool ctf_flagdamaged_byworld
 
bool ctf_oneflag
 
float ctf_pickuptime
 
entity ctf_staleflagnext
 
bool ctf_stalemate
 
int ctf_status
 
int ctf_teams
 
entity ctf_worldflaglist
 
entity ctf_worldflagnext
 
const int DROP_NORMAL = 1
 
const int DROP_PASS = 3
 
const int DROP_RESET = 4
 
const int DROP_THROW = 2
 
entity enemy
 
const int FLAG_BASE = 1
 
const int FLAG_CARRY = 3
 
const vector FLAG_CARRY_OFFSET = ('-16 0 8')
 
const vector FLAG_DROP_OFFSET = ('0 0 32')
 
const int FLAG_DROPPED = 2
 
const int FLAG_FLOAT_OFFSET_Z = 32
 
const int FLAG_PASS_ARC_OFFSET_Z = -10
 
const int FLAG_PASSING = 4
 
const float FLAG_SCALE = 0.6
 
const float FLAG_THINKRATE = 0.2
 
const float FLAG_TOUCHRATE = 0.5
 
const vector FLAG_WAYPOINT_OFFSET = ('0 0 64')
 
entity flagcarried
 
bool havocbot_cantfindflag
 
const int HAVOCBOT_CTF_ROLE_CARRIER = 16
 
const int HAVOCBOT_CTF_ROLE_DEFENSE = 2
 
const int HAVOCBOT_CTF_ROLE_ESCORT = 64
 
const int HAVOCBOT_CTF_ROLE_MIDDLE = 4
 
const int HAVOCBOT_CTF_ROLE_NONE = 0
 
const int HAVOCBOT_CTF_ROLE_OFFENSE = 8
 
const int HAVOCBOT_CTF_ROLE_RETRIEVER = 32
 
float next_take_time
 
float pass_distance
 
entity pass_sender
 
entity pass_target
 
string passeffect
 
const int PICKUP_BASE = 1
 
const int PICKUP_DROPPED = 2
 
const int RETURN_DAMAGE = 3
 
const int RETURN_DROPPED = 2
 
const int RETURN_NEEDKILL = 5
 
const int RETURN_SPEEDRUN = 4
 
const int RETURN_TIMEOUT = 1
 
float score_assist
 
float score_capture
 
float score_drop
 
float score_pickup
 
float score_return
 
float score_team_capture
 
string snd_flag_dropped
 
string snd_flag_pass
 
string snd_flag_touch
 
const int ST_CTF_CAPS = 1
 
float throw_antispam
 
int throw_count
 
float throw_prevtime
 
string toucheffect
 
const vector VEHICLE_FLAG_OFFSET = ('0 0 96')
 
const float VEHICLE_FLAG_SCALE = 1.0
 
const float WPFE_THINKRATE = 0.5
 
bool wpforenemy_announced
 
float wpforenemy_nextthink
 
entity wps_enemyflagcarrier
 
entity wps_flagbase
 
entity wps_flagcarrier
 
entity wps_flagdropped
 
entity wps_flagreturn
 
entity wps_helpme
 
float wps_helpme_time
 

Macro Definition Documentation

◆ CTF_DIFFTEAM

◆ CTF_SAMETEAM

◆ ctf_spawnorigin

#define ctf_spawnorigin   dropped_origin

Definition at line 133 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ FLAG_SPAWN_OFFSET

#define FLAG_SPAWN_OFFSET   ('0 0 1' * (PL_MAX_CONST.z - 13))

Definition at line 50 of file sv_ctf.qh.

Referenced by ctf_FlagSetup().

◆ snd_flag_capture

#define snd_flag_capture   noise2

Definition at line 67 of file sv_ctf.qh.

Referenced by ctf_FlagSetup().

◆ snd_flag_respawn

#define snd_flag_respawn   noise3

Definition at line 68 of file sv_ctf.qh.

Referenced by ctf_FlagSetup().

◆ snd_flag_returned

#define snd_flag_returned   noise1

Definition at line 66 of file sv_ctf.qh.

Referenced by ctf_FlagSetup().

◆ snd_flag_taken

#define snd_flag_taken   noise

Definition at line 65 of file sv_ctf.qh.

Referenced by ctf_FlagSetup().

◆ WPCOLOR_DROPPEDFLAG

#define WPCOLOR_DROPPEDFLAG (   t)    ((t) ? ('0.25 0.25 0.25' + colormapPaletteColor(t - 1, false)) * 0.5 : '1 1 1')

Definition at line 62 of file sv_ctf.qh.

Referenced by ctf_Handle_Drop().

◆ WPCOLOR_ENEMYFC

#define WPCOLOR_ENEMYFC (   t)    ((t) ? colormapPaletteColor(t - 1, false) * 0.75 : '1 1 1')

Definition at line 59 of file sv_ctf.qh.

Referenced by ctf_CheckStalemate(), and ctf_FlagcarrierWaypoints().

◆ WPCOLOR_FLAGCARRIER

#define WPCOLOR_FLAGCARRIER (   t)    ((t) ? colormapPaletteColor(t - 1, false) * 0.75 : '1 1 1')

Definition at line 60 of file sv_ctf.qh.

Referenced by ctf_FlagcarrierWaypoints().

Function Documentation

◆ ctf_FlagTouch()

void ctf_FlagTouch ( entity  this,
entity  toucher 
)

Definition at line 38 of file sv_ctf.qh.

References CTF_FLAG, and ITEM_HANDLE.

Referenced by ctf_FlagSetup().

38 { ITEM_HANDLE(Pickup, CTF_FLAG, this, toucher); }
Definition: pickup.qh:22
#define ITEM_HANDLE(signal,...)
Definition: item.qh:103
Flag CTF_FLAG
Definition: sv_ctf.qh:12
+ Here is the caller graph for this function:

◆ ctf_Handle_Throw()

void ctf_Handle_Throw ( entity  player,
entity  receiver,
float  droptype 
)

◆ ctf_Initialize()

void ctf_Initialize ( )

Definition at line 2820 of file sv_ctf.qc.

References autocvar_g_ctf_shield_force, autocvar_g_ctf_shield_max_ratio, autocvar_g_ctf_shield_min_negscore, ctf_captimerecord, ctf_captureshield_force, ctf_captureshield_max_ratio, ctf_captureshield_min_negscore, ctf_DelayedInit(), CTF_FLAG, CTF_RECORD, db_get(), GetMapname(), InitializeEntity(), NEW, NULL, record_type, ServerProgsDB, stof(), and strcat().

Referenced by REGISTER_MUTATOR().

2821 {
2822  CTF_FLAG = NEW(Flag);
2824  ctf_captimerecord = stof(db_get(ServerProgsDB, strcat(GetMapname(), "/captimerecord/time")));
2825 
2829 
2830  InitializeEntity(NULL, ctf_DelayedInit, INITPRIO_GAMETYPE);
2831 }
#define NEW(cname,...)
Definition: oo.qh:105
float autocvar_g_ctf_shield_force
Definition: sv_ctf.qc:83
string GetMapname()
Definition: intermission.qc:18
float ServerProgsDB
Definition: world.qh:131
#define CTF_RECORD
Definition: util.qh:60
Definition: sv_ctf.qh:8
float ctf_captureshield_force
Definition: sv_ctf.qh:157
int autocvar_g_ctf_shield_min_negscore
Definition: sv_ctf.qc:85
string record_type
Definition: world.qh:49
spree_cen s1 spree_cen s1 spree_cen s1 spree_cen s1 spree_cen s1 spree_cen s1 spree_cen s1 f1 s1 strcat(_("Level %s: "), "^BG%s\3\, _("^BGPress ^F2%s^BG to enter the game"))
float autocvar_g_ctf_shield_max_ratio
Definition: sv_ctf.qc:84
#define NULL
Definition: post.qh:17
ERASEABLE string db_get(int db, string key)
Definition: map.qh:91
float ctf_captureshield_min_negscore
Definition: sv_ctf.qh:155
void ctf_DelayedInit(entity this)
Definition: sv_ctf.qc:2772
void InitializeEntity(entity e, void(entity this) func, int order)
Definition: world.qc:2146
float ctf_captimerecord
Definition: sv_ctf.qh:135
Flag CTF_FLAG
Definition: sv_ctf.qh:12
float ctf_captureshield_max_ratio
Definition: sv_ctf.qh:156
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ctf_RespawnFlag()

void ctf_RespawnFlag ( entity  flag)

Definition at line 1163 of file sv_ctf.qc.

References backtrace, CONTENT_EMPTY, ctf_CheckStalemate(), ctf_FakeTimeLimit(), DAMAGE_NO, FL_ITEM, FL_NOTARGET, FLAG_BASE, FLAG_DROPPED, FLAG_SCALE, GameRules_scoring_vip(), MOVETYPE_NONE, navigation_dynamicgoal_unset(), NULL, RES_HEALTH, set_movetype(), setorigin(), SetResourceExplicit(), SOLID_TRIGGER, and time.

Referenced by ctf_CheckFlagReturn(), ctf_Handle_Capture(), ctf_Handle_Return(), ctf_Handle_Throw(), ctf_Reset(), MUTATOR_HOOKFUNCTION(), and REGISTER_MUTATOR().

1164 {
1165  flag.watertype = CONTENT_EMPTY; // TODO: it is unclear why this workaround is needed, likely many other potential breakage points!!
1166  // check for flag respawn being called twice in a row
1167  if(flag.last_respawn > time - 0.5)
1168  { backtrace("flag respawn called twice quickly! please notify Samual about this..."); }
1169 
1170  flag.last_respawn = time;
1171 
1172  // reset the player (if there is one)
1173  if((flag.owner) && (flag.owner.flagcarried == flag))
1174  {
1175  WaypointSprite_Kill(flag.owner.wps_enemyflagcarrier);
1176  WaypointSprite_Kill(flag.owner.wps_flagreturn);
1177  WaypointSprite_Kill(flag.wps_flagcarrier);
1178 
1179  flag.owner.flagcarried = NULL;
1180  GameRules_scoring_vip(flag.owner, false);
1181 
1182  if(flag.speedrunning)
1183  ctf_FakeTimeLimit(flag.owner, -1);
1184  }
1185 
1186  if((flag.owner) && (flag.owner.vehicle))
1187  flag.scale = FLAG_SCALE;
1188 
1189  if(flag.ctf_status == FLAG_DROPPED)
1190  { WaypointSprite_Kill(flag.wps_flagdropped); }
1191 
1192  // reset the flag
1193  setattachment(flag, NULL, "");
1194  setorigin(flag, flag.ctf_spawnorigin);
1195 
1196  //set_movetype(flag, ((flag.noalign) ? MOVETYPE_NONE : MOVETYPE_TOSS)); // would be desired, except maps that want floating flags have it set to fall!
1197  set_movetype(flag, MOVETYPE_NONE); // match the initial setup handling (flag doesn't move when spawned)
1198  flag.takedamage = DAMAGE_NO;
1199  SetResourceExplicit(flag, RES_HEALTH, flag.max_health);
1200  flag.solid = SOLID_TRIGGER;
1201  flag.velocity = '0 0 0';
1202  flag.angles = flag.mangle;
1203  flag.flags = FL_ITEM | FL_NOTARGET;
1204 
1205  flag.ctf_status = FLAG_BASE;
1206  flag.owner = NULL;
1207  flag.pass_distance = 0;
1208  flag.pass_sender = NULL;
1209  flag.pass_target = NULL;
1210  flag.ctf_dropper = NULL;
1211  flag.ctf_pickuptime = 0;
1212  flag.ctf_droptime = 0;
1213  flag.ctf_flagdamaged_byworld = false;
1215 
1217 }
void ctf_FakeTimeLimit(entity e, float t)
Definition: sv_ctf.qc:93
float MOVETYPE_NONE
Definition: progsdefs.qc:246
bool SetResourceExplicit(entity e, Resource res_type, float amount)
Sets the resource amount of an entity without calling any hooks.
Definition: cl_resources.qc:15
const int FLAG_DROPPED
Definition: sv_ctf.qh:107
void GameRules_scoring_vip(entity player, bool value)
Mark a player as being 'important' (flag carrier, ball carrier, etc)
Definition: sv_rules.qc:98
float FL_ITEM
Definition: progsdefs.qc:239
const int FLAG_BASE
Definition: sv_ctf.qh:106
RES_HEALTH
Definition: ent_cs.qc:126
const float CONTENT_EMPTY
Definition: csprogsdefs.qc:236
#define NULL
Definition: post.qh:17
#define backtrace(msg)
Definition: log.qh:105
const float FLAG_SCALE
Definition: sv_ctf.qh:42
void navigation_dynamicgoal_unset(entity this)
Definition: navigation.qc:95
const float SOLID_TRIGGER
Definition: csprogsdefs.qc:245
setorigin(ent, v)
float FL_NOTARGET
Definition: progsdefs.qc:238
float time
Definition: csprogsdefs.qc:16
float DAMAGE_NO
Definition: progsdefs.qc:282
void set_movetype(entity this, int mt)
void ctf_CheckStalemate()
Definition: sv_ctf.qc:836
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ctf_Stalemate_Customize()

bool ctf_Stalemate_Customize ( entity  this,
entity  client 
)

Definition at line 822 of file sv_ctf.qc.

References entity(), IS_PLAYER, owner, and SAME_TEAM.

Referenced by ctf_CheckStalemate(), and ctf_FlagcarrierWaypoints().

823 {
824  // make spectators see what the player would see
825  entity e = WaypointSprite_getviewentity(client);
826  entity wp_owner = this.owner;
827 
828  // team waypoints
829  //if(CTF_SAMETEAM(wp_owner.flagcarried, wp_owner)) { return false; }
830  if(SAME_TEAM(wp_owner, e)) { return false; }
831  if(!IS_PLAYER(e)) { return false; }
832 
833  return true;
834 }
entity() spawn
entity owner
Definition: main.qh:73
#define SAME_TEAM(a, b)
Definition: teams.qh:239
#define IS_PLAYER(v)
Definition: utils.qh:9
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ havocbot_role_ctf_setrole()

void havocbot_role_ctf_setrole ( entity  bot,
int  role 
)

Definition at line 2102 of file sv_ctf.qc.

References HAVOCBOT_CTF_ROLE_CARRIER, HAVOCBOT_CTF_ROLE_DEFENSE, HAVOCBOT_CTF_ROLE_ESCORT, HAVOCBOT_CTF_ROLE_MIDDLE, HAVOCBOT_CTF_ROLE_OFFENSE, HAVOCBOT_CTF_ROLE_RETRIEVER, havocbot_role_ctf_carrier(), havocbot_role_ctf_defense(), havocbot_role_ctf_escort(), havocbot_role_ctf_middle(), havocbot_role_ctf_offense(), havocbot_role_ctf_retriever(), LOG_TRACE, navigation_goalrating_timeout_expire(), navigation_goalrating_timeout_force(), and time.

Referenced by havocbot_ctf_reset_role(), havocbot_role_ctf_defense(), havocbot_role_ctf_escort(), havocbot_role_ctf_middle(), havocbot_role_ctf_offense(), and havocbot_role_ctf_retriever().

2103 {
2104  string s = "(null)";
2105  switch(role)
2106  {
2108  s = "carrier";
2109  bot.havocbot_role = havocbot_role_ctf_carrier;
2110  bot.havocbot_role_timeout = 0;
2111  bot.havocbot_cantfindflag = time + 10;
2112  if (bot.havocbot_previous_role != bot.havocbot_role)
2114  break;
2116  s = "defense";
2117  bot.havocbot_role = havocbot_role_ctf_defense;
2118  bot.havocbot_role_timeout = 0;
2119  break;
2121  s = "middle";
2122  bot.havocbot_role = havocbot_role_ctf_middle;
2123  bot.havocbot_role_timeout = 0;
2124  break;
2126  s = "offense";
2127  bot.havocbot_role = havocbot_role_ctf_offense;
2128  bot.havocbot_role_timeout = 0;
2129  break;
2131  s = "retriever";
2132  bot.havocbot_previous_role = bot.havocbot_role;
2133  bot.havocbot_role = havocbot_role_ctf_retriever;
2134  bot.havocbot_role_timeout = time + 10;
2135  if (bot.havocbot_previous_role != bot.havocbot_role)
2137  break;
2139  s = "escort";
2140  bot.havocbot_previous_role = bot.havocbot_role;
2141  bot.havocbot_role = havocbot_role_ctf_escort;
2142  bot.havocbot_role_timeout = time + 30;
2143  if (bot.havocbot_previous_role != bot.havocbot_role)
2145  break;
2146  }
2147  LOG_TRACE(bot.netname, " switched to ", s);
2148 }
const int HAVOCBOT_CTF_ROLE_MIDDLE
Definition: sv_ctf.qh:165
const int HAVOCBOT_CTF_ROLE_RETRIEVER
Definition: sv_ctf.qh:168
void havocbot_role_ctf_defense(entity this)
Definition: sv_ctf.qc:2033
void navigation_goalrating_timeout_force(entity this)
Definition: navigation.qc:28
void havocbot_role_ctf_retriever(entity this)
Definition: sv_ctf.qc:1916
const int HAVOCBOT_CTF_ROLE_CARRIER
Definition: sv_ctf.qh:167
void havocbot_role_ctf_escort(entity this)
Definition: sv_ctf.qc:1770
void havocbot_role_ctf_offense(entity this)
Definition: sv_ctf.qc:1838
void havocbot_role_ctf_middle(entity this)
Definition: sv_ctf.qc:1974
const int HAVOCBOT_CTF_ROLE_ESCORT
Definition: sv_ctf.qh:169
const int HAVOCBOT_CTF_ROLE_OFFENSE
Definition: sv_ctf.qh:166
void havocbot_role_ctf_carrier(entity this)
Definition: sv_ctf.qc:1717
void navigation_goalrating_timeout_expire(entity this, float seconds)
Definition: navigation.qc:35
const int HAVOCBOT_CTF_ROLE_DEFENSE
Definition: sv_ctf.qh:164
#define LOG_TRACE(...)
Definition: log.qh:81
float time
Definition: csprogsdefs.qc:16
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ REGISTER_MUTATOR()

REGISTER_MUTATOR ( ctf  ,
false   
)

Definition at line 18 of file sv_ctf.qh.

References ctf_Initialize(), ctf_RespawnFlag(), entity(), GameRules_limit_lead(), GameRules_limit_score(), GameRules_teams(), MUTATOR_ONADD, and MUTATOR_STATIC.

19 {
22  {
23  GameRules_teams(true);
26 
28  }
29  return 0;
30 }
#define MUTATOR_STATIC()
Definition: base.qh:288
void ctf_Initialize()
Definition: sv_ctf.qc:2820
void GameRules_limit_score(int limit)
Definition: sv_rules.qc:34
void GameRules_teams(bool value)
Definition: sv_rules.qc:6
int autocvar_captureleadlimit_override
Definition: sv_ctf.qh:15
void GameRules_limit_lead(int limit)
Definition: sv_rules.qc:44
int autocvar_capturelimit_override
Definition: sv_ctf.qh:16
#define MUTATOR_ONADD
Definition: base.qh:284
+ Here is the call graph for this function:

Variable Documentation

◆ autocvar_captureleadlimit_override

int autocvar_captureleadlimit_override

Definition at line 15 of file sv_ctf.qh.

◆ autocvar_capturelimit_override

int autocvar_capturelimit_override

Definition at line 16 of file sv_ctf.qh.

◆ capeffect

string capeffect

Definition at line 87 of file sv_ctf.qh.

◆ CAPTURE_DROPPED

const int CAPTURE_DROPPED = 2

Definition at line 120 of file sv_ctf.qh.

Referenced by ctf_FlagThink(), and ctf_Handle_Capture().

◆ CAPTURE_NORMAL

const int CAPTURE_NORMAL = 1

Definition at line 119 of file sv_ctf.qh.

Referenced by ctf_FlagThink(), and ctf_Handle_Capture().

◆ ctf_captimerecord

float ctf_captimerecord

◆ ctf_captureshield_force

float ctf_captureshield_force

Definition at line 157 of file sv_ctf.qh.

Referenced by ctf_CaptureShield_Touch(), and ctf_Initialize().

◆ ctf_captureshield_max_ratio

float ctf_captureshield_max_ratio

Definition at line 156 of file sv_ctf.qh.

Referenced by ctf_CaptureShield_CheckStatus(), and ctf_Initialize().

◆ ctf_captureshield_min_negscore

float ctf_captureshield_min_negscore

Definition at line 155 of file sv_ctf.qh.

Referenced by ctf_CaptureShield_CheckStatus(), and ctf_Initialize().

◆ ctf_captureshielded

bool ctf_captureshielded

Definition at line 154 of file sv_ctf.qh.

◆ ctf_dropper

entity ctf_dropper

Definition at line 139 of file sv_ctf.qh.

◆ ctf_droptime

float ctf_droptime

Definition at line 137 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ CTF_FLAG

Flag CTF_FLAG

Definition at line 12 of file sv_ctf.qh.

Referenced by ctf_FlagSetup(), ctf_FlagTouch(), and ctf_Initialize().

◆ ctf_flagdamaged_byworld

bool ctf_flagdamaged_byworld

Definition at line 141 of file sv_ctf.qh.

Referenced by ctf_FlagDamage(), and ctf_FlagThink().

◆ ctf_oneflag

◆ ctf_pickuptime

float ctf_pickuptime

Definition at line 136 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ ctf_staleflagnext

entity ctf_staleflagnext

Definition at line 92 of file sv_ctf.qh.

◆ ctf_stalemate

◆ ctf_status

int ctf_status

Definition at line 138 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ ctf_teams

int ctf_teams

Definition at line 142 of file sv_ctf.qh.

Referenced by ctf_DelayedInit(), and MUTATOR_HOOKFUNCTION().

◆ ctf_worldflaglist

◆ ctf_worldflagnext

entity ctf_worldflagnext

Definition at line 91 of file sv_ctf.qh.

◆ DROP_NORMAL

const int DROP_NORMAL = 1

Definition at line 111 of file sv_ctf.qh.

Referenced by ctf_Handle_Throw(), ctf_RemovePlayer(), and MUTATOR_HOOKFUNCTION().

◆ DROP_PASS

const int DROP_PASS = 3

Definition at line 113 of file sv_ctf.qh.

Referenced by ctf_FlagThink(), ctf_Handle_Drop(), ctf_Handle_Throw(), and MUTATOR_HOOKFUNCTION().

◆ DROP_RESET

const int DROP_RESET = 4

Definition at line 114 of file sv_ctf.qh.

Referenced by ctf_Handle_Throw(), and ctf_Reset().

◆ DROP_THROW

const int DROP_THROW = 2

Definition at line 112 of file sv_ctf.qh.

Referenced by ctf_FlagThink(), ctf_Handle_Throw(), and MUTATOR_HOOKFUNCTION().

◆ enemy

◆ FLAG_BASE

◆ FLAG_CARRY

◆ FLAG_CARRY_OFFSET

const vector FLAG_CARRY_OFFSET = ('-16 0 8')

Definition at line 49 of file sv_ctf.qh.

Referenced by ctf_Handle_Pickup(), ctf_Handle_Retrieve(), and MUTATOR_HOOKFUNCTION().

◆ FLAG_DROP_OFFSET

const vector FLAG_DROP_OFFSET = ('0 0 32')

Definition at line 48 of file sv_ctf.qh.

Referenced by ctf_Handle_Throw().

◆ FLAG_DROPPED

◆ FLAG_FLOAT_OFFSET_Z

const int FLAG_FLOAT_OFFSET_Z = 32

Definition at line 52 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ FLAG_PASS_ARC_OFFSET_Z

const int FLAG_PASS_ARC_OFFSET_Z = -10

Definition at line 53 of file sv_ctf.qh.

Referenced by ctf_CalculatePassVelocity().

◆ FLAG_PASSING

const int FLAG_PASSING = 4

◆ FLAG_SCALE

const float FLAG_SCALE = 0.6

Definition at line 42 of file sv_ctf.qh.

Referenced by ctf_FlagSetup(), ctf_RespawnFlag(), and MUTATOR_HOOKFUNCTION().

◆ FLAG_THINKRATE

const float FLAG_THINKRATE = 0.2

Definition at line 44 of file sv_ctf.qh.

Referenced by ctf_FlagSetup(), and ctf_FlagThink().

◆ FLAG_TOUCHRATE

const float FLAG_TOUCHRATE = 0.5

Definition at line 45 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ FLAG_WAYPOINT_OFFSET

const vector FLAG_WAYPOINT_OFFSET = ('0 0 64')

◆ flagcarried

◆ havocbot_cantfindflag

bool havocbot_cantfindflag

Definition at line 171 of file sv_ctf.qh.

Referenced by havocbot_role_ctf_carrier().

◆ HAVOCBOT_CTF_ROLE_CARRIER

◆ HAVOCBOT_CTF_ROLE_DEFENSE

const int HAVOCBOT_CTF_ROLE_DEFENSE = 2

◆ HAVOCBOT_CTF_ROLE_ESCORT

const int HAVOCBOT_CTF_ROLE_ESCORT = 64

Definition at line 169 of file sv_ctf.qh.

Referenced by havocbot_role_ctf_offense(), and havocbot_role_ctf_setrole().

◆ HAVOCBOT_CTF_ROLE_MIDDLE

const int HAVOCBOT_CTF_ROLE_MIDDLE = 4

Definition at line 165 of file sv_ctf.qh.

Referenced by havocbot_ctf_reset_role(), and havocbot_role_ctf_setrole().

◆ HAVOCBOT_CTF_ROLE_NONE

const int HAVOCBOT_CTF_ROLE_NONE = 0

Definition at line 163 of file sv_ctf.qh.

◆ HAVOCBOT_CTF_ROLE_OFFENSE

const int HAVOCBOT_CTF_ROLE_OFFENSE = 8

Definition at line 166 of file sv_ctf.qh.

Referenced by havocbot_ctf_reset_role(), and havocbot_role_ctf_setrole().

◆ HAVOCBOT_CTF_ROLE_RETRIEVER

const int HAVOCBOT_CTF_ROLE_RETRIEVER = 32

◆ next_take_time

float next_take_time

Definition at line 140 of file sv_ctf.qh.

◆ pass_distance

float pass_distance

Definition at line 146 of file sv_ctf.qh.

◆ pass_sender

entity pass_sender

Definition at line 147 of file sv_ctf.qh.

◆ pass_target

entity pass_target

Definition at line 148 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ passeffect

string passeffect

Definition at line 86 of file sv_ctf.qh.

◆ PICKUP_BASE

const int PICKUP_BASE = 1

Definition at line 116 of file sv_ctf.qh.

Referenced by ctf_FlagThink(), and ctf_Handle_Pickup().

◆ PICKUP_DROPPED

const int PICKUP_DROPPED = 2

Definition at line 117 of file sv_ctf.qh.

Referenced by ctf_FlagThink(), and ctf_Handle_Pickup().

◆ RETURN_DAMAGE

const int RETURN_DAMAGE = 3

Definition at line 124 of file sv_ctf.qh.

Referenced by ctf_CheckFlagReturn(), and ctf_FlagDamage().

◆ RETURN_DROPPED

const int RETURN_DROPPED = 2

Definition at line 123 of file sv_ctf.qh.

Referenced by ctf_CheckFlagReturn(), and ctf_FlagThink().

◆ RETURN_NEEDKILL

const int RETURN_NEEDKILL = 5

Definition at line 126 of file sv_ctf.qh.

Referenced by ctf_CheckFlagReturn(), ctf_FlagDamage(), and ctf_FlagThink().

◆ RETURN_SPEEDRUN

const int RETURN_SPEEDRUN = 4

Definition at line 125 of file sv_ctf.qh.

Referenced by ctf_CheckFlagReturn(), and ctf_FlagThink().

◆ RETURN_TIMEOUT

const int RETURN_TIMEOUT = 1

Definition at line 122 of file sv_ctf.qh.

Referenced by ctf_CheckFlagReturn(), and ctf_FlagThink().

◆ score_assist

float score_assist

Definition at line 74 of file sv_ctf.qh.

◆ score_capture

float score_capture

Definition at line 75 of file sv_ctf.qh.

◆ score_drop

float score_drop

Definition at line 76 of file sv_ctf.qh.

◆ score_pickup

float score_pickup

Definition at line 77 of file sv_ctf.qh.

◆ score_return

float score_return

Definition at line 78 of file sv_ctf.qh.

◆ score_team_capture

float score_team_capture

Definition at line 79 of file sv_ctf.qh.

◆ snd_flag_dropped

string snd_flag_dropped

Definition at line 69 of file sv_ctf.qh.

Referenced by ctf_FlagSetup().

◆ snd_flag_pass

string snd_flag_pass

Definition at line 71 of file sv_ctf.qh.

Referenced by ctf_FlagSetup().

◆ snd_flag_touch

string snd_flag_touch

Definition at line 70 of file sv_ctf.qh.

Referenced by ctf_FlagSetup().

◆ ST_CTF_CAPS

const int ST_CTF_CAPS = 1

Definition at line 36 of file sv_ctf.qh.

Referenced by ctf_ScoreRules().

◆ throw_antispam

float throw_antispam

Definition at line 149 of file sv_ctf.qh.

◆ throw_count

int throw_count

Definition at line 151 of file sv_ctf.qh.

◆ throw_prevtime

float throw_prevtime

Definition at line 150 of file sv_ctf.qh.

◆ toucheffect

string toucheffect

Definition at line 85 of file sv_ctf.qh.

◆ VEHICLE_FLAG_OFFSET

const vector VEHICLE_FLAG_OFFSET = ('0 0 96')

Definition at line 55 of file sv_ctf.qh.

Referenced by ctf_Handle_Pickup(), ctf_Handle_Retrieve(), and MUTATOR_HOOKFUNCTION().

◆ VEHICLE_FLAG_SCALE

const float VEHICLE_FLAG_SCALE = 1.0

Definition at line 56 of file sv_ctf.qh.

Referenced by ctf_Handle_Pickup(), ctf_Handle_Retrieve(), and MUTATOR_HOOKFUNCTION().

◆ WPFE_THINKRATE

const float WPFE_THINKRATE = 0.5

Definition at line 46 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ wpforenemy_announced

bool wpforenemy_announced

Definition at line 102 of file sv_ctf.qh.

Referenced by ctf_CheckStalemate(), and Onslaught_CheckWinner().

◆ wpforenemy_nextthink

float wpforenemy_nextthink

Definition at line 103 of file sv_ctf.qh.

Referenced by ctf_FlagThink().

◆ wps_enemyflagcarrier

entity wps_enemyflagcarrier

Definition at line 100 of file sv_ctf.qh.

Referenced by ctf_CheckStalemate(), and ctf_FlagcarrierWaypoints().

◆ wps_flagbase

entity wps_flagbase

Definition at line 96 of file sv_ctf.qh.

Referenced by ctf_DelayedFlagSetup().

◆ wps_flagcarrier

entity wps_flagcarrier

Definition at line 97 of file sv_ctf.qh.

Referenced by ctf_FlagcarrierWaypoints().

◆ wps_flagdropped

entity wps_flagdropped

Definition at line 98 of file sv_ctf.qh.

Referenced by ctf_Handle_Drop().

◆ wps_flagreturn

entity wps_flagreturn

Definition at line 99 of file sv_ctf.qh.

Referenced by ctf_FlagcarrierWaypoints().

◆ wps_helpme

entity wps_helpme

Definition at line 95 of file sv_ctf.qh.

Referenced by MUTATOR_HOOKFUNCTION().

◆ wps_helpme_time

float wps_helpme_time

Definition at line 101 of file sv_ctf.qh.