43 float old_delay, old_team, real_team;
55 this.
model = head.mdl;
57 this.
skin = head.skin;
59 float points, wait_time;
67 wait_time = this.
wait;
70 bprint(sprintf(
"^3%s^3%s\n", head.netname,
this.message));
72 Send_Notification(NOTIF_ALL,
NULL, MSG_INFO, INFO_DOMINATION_CAPTURE_TIME, head.netname,
this.message, points, wait_time);
74 if(this.
enemy.playerid ==
this.enemy_playerid)
86 if (head.noise1 !=
"")
92 old_delay = this.
delay;
94 this.
team = real_team;
97 this.
delay = old_delay;
122 switch(it.goalentity.team)
182 fragamt = this.
frags;
187 if (this.
enemy.playerid ==
this.enemy_playerid)
214 while (head && head.team !=
toucher.team)
216 if (!head || head.netname ==
"" || head ==
this.goalentity)
234 while (head && head.netname !=
"")
244 this.
model = head.mdl;
246 this.
skin = head.skin;
258 while(head && head.netname !=
"")
261 objerror(
this,
"no spawnfunc_dom_team with netname \"\" found\n");
265 _setmodel(
this, head.mdl);
266 this.
skin = head.skin;
271 this.
message =
" has captured a control point";
278 float points, waittime;
286 waittime = this.
wait;
302 setsize(
this,
'-48 -48 -32',
'48 48 32');
303 setorigin(
this, this.
origin +
'0 0 20');
327 ++num_control_points;
346 if (winner_team == -1)
378 navigation_routerating(this, it, ratingscale, 5000);
379 else if(it.goalentity.cnt == 0)
380 navigation_routerating(this, it, ratingscale, 5000);
381 else if(it.goalentity.team != this.team)
382 navigation_routerating(this, it, ratingscale, 5000);
408 string ret_string =
"dom_team";
413 if(head.netname !=
"")
437 it.player_blocked = 1;
506 spawnfunc_dom_controlpoint(
this);
542 precache_model(this.
model);
543 if (this.
noise !=
"")
547 _setmodel(
this, this.
model);
564 field(SP_DOM_TAKES,
"takes", 0);
569 float sp_domticks, sp_score;
570 sp_score = sp_domticks = 0;
577 field(SP_DOM_TICKS,
"ticks", sp_domticks);
578 field(SP_DOM_TAKES,
"takes", 0);
584void dom_spawnteam(
string teamname,
float teamcolor,
string pointmodel,
float pointskin,
Sound capsound,
string capnarration,
string capmessage)
590 e.model = pointmodel;
593 e.noise1 =
strzone(capnarration);
594 e.message =
strzone(capmessage);
597 _setmodel(e, e.model);
599 e.dmg = e.modelindex;
611 setthink(e, spawnfunc_dom_controlpoint);
614 spawnfunc_dom_controlpoint(e);
627 dom_spawnteam(
"", 0,
"models/domination/dom_unclaimed.md3", 0, SND_Null,
"",
"");
635 LOG_TRACE(
"No \"dom_team\" entities found on this map, creating them anyway.");
float frame
primary framegroup animation (strength = 1 - lerpfrac - lerpfrac3 - lerpfrac4)
void havocbot_goalrating_waypoints(entity this, float ratingscale, vector org, float sradius)
void waypoint_spawnforitem(entity e)
void navigation_goalrating_start(entity this)
void navigation_goalrating_timeout_set(entity this)
bool navigation_goalrating_timeout(entity this)
void navigation_goalrating_end(entity this)
#define MUTATOR_HOOKFUNCTION(...)
#define BIT(n)
Only ever assign into the first 24 bits in QC (so max is BIT(23)).
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
#define colormapPaletteColor(c, isPants)
const int SFL_SORT_PRIO_PRIMARY
const int INITPRIO_GAMETYPE
const float SOLID_TRIGGER
const float EF_FULLBRIGHT
void GameLogEcho(string s)
bool autocvar_sv_eventlog
ERASEABLE entity IL_PUSH(IntrusiveList this, entity it)
Push to tail.
#define IL_EACH(this, cond, body)
void SUB_UseTargets(entity this, entity actor, entity trigger)
#define PutClientInServer
strcat(_("^F4Countdown stopped!"), "\n^BG", _("Teams are too unbalanced."))
void Send_Notification(NOTIF broadcast, entity client, MSG net_type, Notification net_name,...count)
#define APP_TEAM_NUM(num, prefix)
#define new_pure(class)
purely logical entities (not linked to the area grid)
void round_handler_Init(float the_delay, float the_count, float the_round_timelimit)
void round_handler_Spawn(bool() canRoundStart_func, bool() canRoundEnd_func, void() roundStart_func)
#define round_handler_IsActive()
#define round_handler_GetEndTime()
#define round_handler_IsRoundStarted()
float TeamScore_AddToTeam(int t, float scorefield, float score)
Adds a score to the given team.
#define IS_INDEPENDENT_PLAYER(e)
#define Sound_fixpath(this)
#define _sound(e, c, s, v, a)
void play2all(string samp)
float autocvar_g_domination_round_timelimit
void dom_DelayedInit(entity this)
void dom_controlpoint_setup(entity this)
bool autocvar_g_domination_point_fullbright
void Domination_count_controlpoints()
int autocvar_g_domination_default_teams
void set_dom_state(entity e)
void havocbot_role_dom(entity this)
bool autocvar_g_domination_disable_frags
void Domination_RoundStart()
int autocvar_g_domination_point_amt
void dompointtouch(entity this, entity toucher)
void dom_spawnteams(int teams)
void dom_spawnpoint(vector org)
bool Domination_CheckPlayers()
void havocbot_goalrating_controlpoints(entity this, float ratingscale, vector org, float sradius)
void ScoreRules_dom(int teams)
void dom_spawnteam(string teamname, float teamcolor, string pointmodel, float pointskin, Sound capsound, string capnarration, string capmessage)
int autocvar_g_domination_teams_override
float autocvar_g_domination_point_rate
void dompointthink(entity this)
void dom_EventLog(string mode, float team_before, entity actor)
void AnimateDomPoint(entity this)
bool Domination_CheckWinner()
void dompoint_captured(entity this)
float autocvar_g_domination_warmup
float domination_roundbased
bool autocvar_g_domination_roundbased
IntrusiveList g_dompoints
void havocbot_goalrating_items(entity this, float ratingscale, vector org, float sradius)
#define GameRules_scoring_add(client, fld, value)
#define GameRules_scoring(teams, spprio, stprio, fields)
int Team_GetWinnerTeam_WithOwnedItems(int min_control_points)
Returns the winner team.
void TeamBalance_Destroy(entity balance)
Destroy the team balance entity.
entity Entity_GetTeam(entity this)
Returns the team entity of the given entity.
void Team_SetNumberOfOwnedItems(entity team_ent, int number)
Sets the number of items owned by a team.
int Team_GetNumberOfOwnedItems(entity team_ent)
Returns the number of items owned by a team.
bool Entity_HasValidTeam(entity this)
Returns whether the given entity belongs to a valid team.
int TeamBalance_GetAllowedTeams(entity balance)
Returns the bitmask of allowed teams.
entity TeamBalance_CheckAllowedTeams(entity for_whom)
Checks whether the player can join teams according to global configuration and mutator settings.
entity Team_GetTeamFromIndex(int index)
Returns the global team entity at the given index.
bool Team_IsValidTeam(int team_num)
Returns whether team value is valid.
int Team_TeamToBit(int team_num)
Converts team value into bit value that is used in team bitmasks.
#define Team_ColoredFullName(teamid)
const int NUM_TEAMS
Number of teams in the game.
#define IS_REAL_CLIENT(v)
#define FOREACH_CLIENT(cond, body)
#define vdist(v, cmp, f)
Vector distance comparison, avoids sqrt()
void WaypointSprite_UpdateTeamRadar(entity e, entity icon, vector col)
void WaypointSprite_UpdateSprites(entity e, entity _m1, entity _m2, entity _m3)
void WaypointSprite_Ping(entity e)
entity WaypointSprite_SpawnFixed(entity spr, vector ofs, entity own,.entity ownfield, entity icon)
void DropToFloor_QC_DelayedInit(entity this)
void InitializeEntity(entity e, void(entity this) func, int order)