X-Git-Url: http://git.xonotic.org/?a=blobdiff_plain;ds=sidebyside;f=qcsrc%2Fserver%2Fworld.qh;h=3bbaad68246e942d4288f379d326686a6cb970ae;hb=HEAD;hp=706c931c83c9897f41fba8b874bd3b529d93536f;hpb=dc02e4d78fb0e67b47a0c1e150b4c18c0711b8bf;p=xonotic%2Fxonotic-data.pk3dir.git diff --git a/qcsrc/server/world.qh b/qcsrc/server/world.qh index 706c931c8..024a36da9 100644 --- a/qcsrc/server/world.qh +++ b/qcsrc/server/world.qh @@ -2,21 +2,61 @@ #include +bool autocvar__sv_init; +bool autocvar__endmatch; +bool autocvar_g_use_ammunition; +bool autocvar_g_jetpack; +int autocvar_g_warmup; +int autocvar_g_warmup_allguns; +bool autocvar_g_warmup_allow_timeout; +#define autocvar_g_weaponarena cvar_string("g_weaponarena") +string autocvar_quit_and_redirect; +float autocvar_quit_and_redirect_timer; +bool autocvar_quit_when_empty; +string autocvar_sessionid; +bool autocvar_sv_curl_serverpackages_auto; +bool autocvar_sv_db_saveasdump; +bool autocvar_sv_logscores_bots; +bool autocvar_sv_logscores_console; +bool autocvar_sv_logscores_file; +string autocvar_sv_logscores_filename; +float autocvar_sv_mapchange_delay; +float autocvar_timelimit_increment; +float autocvar_timelimit_decrement; +float autocvar_timelimit_min; +float autocvar_timelimit_max; +float autocvar_timelimit_overtime; +int autocvar_timelimit_overtimes; +float autocvar_timelimit_suddendeath; + +bool autocvar_sv_mapformat_is_quake3; +bool autocvar_sv_mapformat_is_quake2; + float checkrules_equality; float checkrules_suddendeathwarning; float checkrules_suddendeathend; -float checkrules_overtimesadded; //how many overtimes have been already added +int checkrules_overtimesadded; //how many overtimes have been already added // flag set on worldspawn so that the code knows if it is dedicated or not bool server_is_dedicated; +int world_initialized; + string cvar_changes; string cvar_purechanges; float cvar_purechanges_count; string modname; -string gamemode_name; +string autocvar__sv_vote_gametype_custom; +bool gametype_custom_enabled; +string loaded_gametype_custom_string; + +string record_type; + +string autocvar_sv_termsofservice_url; +// only escape the terms of service url on map change +string sv_termsofservice_url_escaped; string clientstuff; @@ -77,22 +117,13 @@ float warmup_start_health; float warmup_start_armorvalue; float g_weapon_stay; -float want_weapon(entity weaponinfo, float allguns); // WEAPONTODO: what still needs done? +int want_weapon(entity weaponinfo, int allguns); // WEAPONTODO: what still needs done? float g_grappling_hook; -float warmup_stage; +int warmup_stage; bool sv_ready_restart_after_countdown; -const int INITPRIO_FIRST = 0; -const int INITPRIO_GAMETYPE = 0; -const int INITPRIO_GAMETYPE_FALLBACK = 1; -const int INITPRIO_FINDTARGET = 10; -const int INITPRIO_DROPTOFLOOR = 20; -const int INITPRIO_SETLOCATION = 90; -const int INITPRIO_LINKDOORS = 91; -const int INITPRIO_LAST = 99; - .void(entity this) initialize_entity; .int initialize_entity_order; .entity initialize_entity_next; @@ -114,9 +145,14 @@ const int WINNING_STARTSUDDENDEATHOVERTIME = 3; // no winner, enter suddendeath float WinningCondition_Scores(float limit, float leadlimit); void SetWinners(.float field, float value); -void ReadyRestart(); +void ReadyRestart(bool forceWarmupEnd); void DumpStats(float final); + +bool MoveToRandomLocationWithinBounds(entity e, vector boundmin, vector boundmax, float goodcontents, float badcontents, float badsurfaceflags, int attempts, float maxaboveground, float minviewdistance, bool frompos); + +float MoveToRandomMapLocation(entity e, float goodcontents, float badcontents, float badsurfaceflags, float attempts, float maxaboveground, float minviewdistance); + void CheckRules_World(); float RedirectionThink(); @@ -125,7 +161,12 @@ void readplayerstartcvars(); void readlevelcvars(); .vector dropped_origin; -void droptofloor(entity this); +void DropToFloor_QC_DelayedInit(entity this); IntrusiveList g_moveables; STATIC_INIT(g_moveables) { g_moveables = IL_NEW(); } + +bool observe_blocked_if_eliminated = false; // forbids eliminated players from observing + +void MatchEnd_RestoreSpectatorAndTeamStatus(.int prev_team_field); +void MatchEnd_RestoreSpectatorStatus();