42#define PlayerScore_Get(player, scorefield) PlayerScore_Add(player, scorefield, 0)
116#define WINNINGCONDITIONHELPER_LOWERISBETTER_WORST 999999999
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
float WinningConditionHelper_secondscore
second highest score
void PlayerScore_Detach(entity player)
Detaches a PlayerScore entity from the player.
string GetTeamScoreString(int tm, float shortString)
float TeamScore_Add(entity player, float scorefield, float score)
Adds a score to the player's team's scores.
entity WinningConditionHelper_second
the second player, or NULL if none
float TeamScore_GetCompareValue(float t)
Returns a value indicating the team score (and higher is better).
void WinningConditionHelper(entity this)
Sets the following results for the current scores entities.
entity scores_initialized
void ScoreInfo_Init(int teams)
Initialize the scores info for the given number of teams.
void Score_ClearAll()
Clear ALL scores (for ready-restart).
void ScoreInfo_SetLabel_PlayerScore(PlayerScoreField i, string label, float scoreflags)
Set the label of a player score item, as well as the scoring flags.
float WinningConditionHelper_winnerteam
the color of the winning team, or -1 if none
float TeamScore_AddToTeam(int t, float scorefield, float score)
Adds a score to the given team.
entity WinningConditionHelper_winner
the winning player, or NULL if none
float WinningConditionHelper_topscore
highest score
float WinningConditionHelper_equality
we have no winner
float PlayerTeamScore_Add(entity player, PlayerScoreField pscorefield, float tscorefield, float score)
Adds a score to both the player and the team.
void PlayerScore_Attach(entity player)
Attaches a PlayerScore entity to a player.
void Score_NicePrint(entity to)
Prints the scores to the console of a player.
bool autocvar_g_full_getstatus_responses
float WinningConditionHelper_lowerisbetter
lower is better, duh
float WinningConditionHelper_zeroisworst
zero is worst, duh
void ScoreInfo_SetLabel_TeamScore(int i, string label, float scoreflags)
Set the label of a team score item, as well as the scoring flags.
string GetPlayerScoreString(entity pl, float shortString)
Returns score strings for eventlog etc.
entity PlayerScore_Sort(.float field, int teams, bool strict, bool nospectators)
Sorts the players and stores their place in the given field, starting with.
float WinningConditionHelper_secondteam
the color of the second team, or -1 if none
float PlayerScore_Add(entity player, PlayerScoreField scorefield, float score)
Adds a score to the player's scores.
float PlayerScore_Set(entity player, PlayerScoreField scorefield, float score)
Sets the player's score to the score parameter.
bool PlayerScore_Clear(entity player)
Initialize the score of this player if needed.