|
Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
|
|
#include "main.qh"#include <client/command/cl_cmd.qh>#include <client/draw.qh>#include <client/hud/_mod.qh>#include <client/hud/panel/centerprint.qh>#include <client/hud/panel/chat.qh>#include <client/hud/panel/quickmenu.qh>#include <client/hud/panel/scoreboard.qh>#include <client/items/items.qh>#include <client/mapvoting.qh>#include <client/mutators/_mod.qh>#include <client/shownames.qh>#include <client/view.qh>#include <client/weapons/projectile.qh>#include <common/checkextension.qh>#include <common/deathtypes/all.qh>#include <common/effects/all.inc>#include <common/effects/all.qh>#include <common/effects/effect.qh>#include <common/effects/qc/_mod.qh>#include <common/ent_cs.qh>#include <common/gametypes/gametype/nexball/cl_nexball.qh>#include <common/items/_mod.qh>#include <common/mapinfo.qh>#include <common/mapobjects/_mod.qh>#include <common/minigames/cl_minigames.qh>#include <common/minigames/cl_minigames_hud.qh>#include <common/net_linked.qh>#include <common/net_notice.qh>#include <common/scores.qh>#include <common/vehicles/all.qh>#include <lib/csqcmodel/cl_model.qh>#include <lib/csqcmodel/interpolate.qh>#include <lib/warpzone/client.qh>Go to the source code of this file.
Macros | |
| #define | DP_CSQC_ENTITY_REMOVE_IS_B0RKED |
Variables | |
| bool | autocvar_r_drawfog |
| bool | autocvar_r_fog_exp2 |
| string | forcefog |
| float | has_team |
| int | survival_status |
Definition at line 1507 of file main.qc.
References argv(), autocvar_hud_showbinds, autocvar_hud_showbinds_limit, binddb, cmd_name, cons_mid(), cvar(), db_get(), db_put(), keynumtostring(), startsWith, stof(), tokenize(), and translate_key().
| void AuditLists | ( | ) |
Definition at line 225 of file main.qc.
References entity(), error, players, prev, strcat(), and teams.
Referenced by MoveToLast(), RegisterPlayer(), RegisterTeam(), RemovePlayer(), and RemoveTeam().
Definition at line 966 of file main.qc.
References autocvar_developer_csqcentities, Ent_Remove(), entity(), entnum, enttype, LOG_INFOF, and LOG_WARN.
Definition at line 884 of file main.qc.
References classname, clearentity(), Ent_Remove(), entity(), entnum, enttype, etof, FOREACH, LOG_FATALF, LOG_INFOF, ONREMOVE(), ReadByte(), serverdeltatime, serverprevtime, servertime, sourceLoc, STAT, STR, and time.
Definition at line 46 of file main.qc.
References autocvar_cl_lockview, autocvar_cl_reticle, autocvar_hud_skin, binddb, calledhooks, CheckEngineExtensions(), ClientProgsDB, ConsoleCommand_macro_init(), cvar_set(), cvar_settemp(), cvar_string(), CVAR_TYPEFLAG_EXISTS, db_create(), db_load(), draw_endBoldFont, gametype, get_mi_min_max_texcoords(), GetTeam(), hud_skin_path, LoadMenuSkinValues(), LOG_TRACEF, maxclients, mi_center, mi_max, mi_min, mi_scale, mi_shortname, minimapname, NULL, NUM_SPECTATOR, players, postinit, precache_pic(), prvm_language, registercvar(), Sort_Spawn(), static_init, static_init_late, static_init_precache, strcat(), strzone(), teams, tempdb, weapon_accuracy, WEP_FIRST, and WEP_LAST.
Definition at line 497 of file main.qc.
References autocvar_menu_gamemenu, cvar(), HUD_Minigame_InputEvent(), HUD_Panel_Chat_InputEvent(), HUD_Panel_InputEvent(), HUD_Radar_InputEvent(), HUD_Scoreboard_InputEvent(), hudShiftState, isdemo(), K_ALT, K_CTRL, K_ESCAPE, K_SHIFT, K_TAB, localcmd(), MapVote_InputEvent(), QuickMenu_InputEvent(), S_ALT, S_CTRL, S_SHIFT, S_TAB, Scoreboard_UI_Enable(), TC, and View_InputEvent().
Definition at line 1007 of file main.qc.
References autocvar_developer_csqcentities, centerprint_AddStandard(), and LOG_INFOF.
Definition at line 1000 of file main.qc.
References autocvar_developer_csqcentities, ColorTranslateRGB(), LOG_INFOF, and print().
Definition at line 993 of file main.qc.
References autocvar_developer_csqcentities, localcmd(), and LOG_INFOF.
| bool CSQC_Parse_TempEntity | ( | ) |
Definition at line 1016 of file main.qc.
References autocvar_developer_csqcentities, FOREACH, LOG_INFOF, and ReadByte().
Definition at line 943 of file main.qc.
References autocvar_cl_jetpack_attenuation, classname, entity(), enttype, func_null(), skeletonindex, snd_looping, sound, and VOL_BASE.
Referenced by CSQC_Ent_Remove(), CSQC_Ent_Update(), and NET_HANDLE().
Definition at line 570 of file main.qc.
References entity(), FOREACH, owner, and SetTeam().
Referenced by NET_HANDLE().
| void Fog_Force | ( | ) |
Definition at line 1037 of file main.qc.
References autocvar_cl_orthoview, autocvar_cl_orthoview_nofog, autocvar_r_drawfog, autocvar_r_fog_exp2, cvar_set(), forcefog, and localcmd().
Referenced by CSQC_UpdateView().
| void Gametype_Init | ( | ) |
Definition at line 978 of file main.qc.
References calledhooks, gametype, HOOK_START, isdemo(), localcmd(), and MapInfo_Type_ToString().
Referenced by NET_HANDLE().
Definition at line 1122 of file main.qc.
References strcat().
Referenced by HUD_Checkpoints(), HUD_Physics(), HUD_RaceTimer(), Scoreboard_Draw(), and StrafeHUD_DrawStartSpeed().
Definition at line 1109 of file main.qc.
Referenced by HUD_Checkpoints(), HUD_Physics(), HUD_RaceTimer(), Scoreboard_Draw(), and StrafeHUD_DrawStartSpeed().
Definition at line 332 of file main.qc.
References entity(), new_pure, NULL, NUM_SPECTATOR, RegisterTeam(), TC, team, and teamslots.
Referenced by CSQC_Init(), HUD_InfoMessages(), NET_HANDLE(), and SetTeam().
Definition at line 1368 of file main.qc.
References strcat().
Referenced by net_handle_ServerWelcome().
| void ignore_list_apply | ( | ) |
Definition at line 672 of file main.qc.
References entity(), FOREACH_WORD, ignore_list, ignore_list_apply_time, players, stoi, strfree, and time.
Referenced by CSQC_UpdateView(), and NET_HANDLE().
Definition at line 280 of file main.qc.
References AuditLists(), entity(), and SORT_SWAP.
| NET_HANDLE | ( | ENT_CLIENT_ACCURACY | , |
| bool | isnew ) |
Definition at line 856 of file main.qc.
References make_pure, ReadByte(), ReadInt24_t(), weapon_accuracy, WEP_FIRST, and WEP_LAST.
| NET_HANDLE | ( | ENT_CLIENT_CLIENTDATA | , |
| bool | isnew ) |
Definition at line 704 of file main.qc.
References autocvar_hud_panel_healtharmor_progressbar_gfx, BIT, hud_dynamic_shake_factor, ignore_list, ignore_list_apply(), make_pure, MAX_SPECTATORS, min(), num_spectators, observe_blocked, player_localnum, prev_health, prev_p_health, ReadByte(), ReadString, scoreboard_showscores_force, spectatee_status, spectatee_status_changed_time, spectatorbutton_zoom, spectatorlist, strcpy, teamnagger, and time.
| NET_HANDLE | ( | ENT_CLIENT_ELIMINATEDPLAYERS | , |
| bool | isnew ) |
Definition at line 821 of file main.qc.
References BIT, make_pure, maxclients, playerslots, and serialize.
| NET_HANDLE | ( | ENT_CLIENT_INIT | , |
| bool | isnew ) |
Definition at line 1080 of file main.qc.
References arc_shotorigin, armorblockpercent, damagepush_speedfactor, decompressShotOrigin(), forcefog, g_trueaim_minrange, hook_shotorigin, MUTATOR_CALLHOOK, nb_pb_period, PostInit(), postinit, ReadByte(), ReadInt24_t(), ReadString, serverflags, and strcpy.
| NET_HANDLE | ( | ENT_CLIENT_NAGGER | , |
| bool | isnew ) |
Definition at line 777 of file main.qc.
References BIT, make_pure, maxclients, playerslots, ReadByte(), ReadString, ready_waiting, ready_waiting_for_me, strcpy, strfree, vote_active, vote_called_vote, vote_highlighted, vote_needed, vote_nocount, vote_waiting, vote_waiting_for_me, vote_yescount, and warmup_stage.
| NET_HANDLE | ( | ENT_CLIENT_RANDOMSEED | , |
| bool | isnew ) |
Definition at line 847 of file main.qc.
References make_pure, prandom_debug, and psrandom().
| NET_HANDLE | ( | ENT_CLIENT_SCORES | , |
| bool | isnew ) |
Definition at line 587 of file main.qc.
References BIT, classname, Ent_Remove(), Ent_RemovePlayerScore(), entity(), etof, FOREACH, LOG_INFOF, make_pure, new_pure, owner, playerslots, ReadByte(), ReadInt24_t(), Scoreboard_UpdatePlayerPos(), and sv_entnum.
| NET_HANDLE | ( | ENT_CLIENT_SCORES_INFO | , |
| bool | isnew ) |
Definition at line 1056 of file main.qc.
References _MapInfo_GetTeamPlayBool(), FOREACH, gametype, gametype_custom_name, Gametype_Init(), HUD_ModIcons_SetFunc(), make_pure, MAX_TEAMSCORE, net_handle_ServerWelcome(), ReadByte(), ReadRegistered, ReadString, Scoreboard_InitScores(), scores_flags, scores_label, strcpy, teamplay, teamscores_flags, and teamscores_label.
| NET_HANDLE | ( | ENT_CLIENT_TEAMSCORES | , |
| bool | isnew ) |
Definition at line 643 of file main.qc.
References BIT, entity(), GetTeam(), make_pure, MAX_TEAMSCORE, owner, ReadByte(), ReadInt24_t(), Scoreboard_UpdateTeamPos(), and team.
| NET_HANDLE | ( | TE_CSQC_PINGPLREPORT | , |
| bool | isNew ) |
Definition at line 1305 of file main.qc.
References entity(), playerslots, and ReadByte().
| NET_HANDLE | ( | TE_CSQC_RACE | , |
| bool | isNew ) |
Definition at line 1136 of file main.qc.
References autocvar_cl_race_cptimes_onlyself, entcs_GetName(), grecordholder, grecordtime, min(), player_localnum, race_checkpoint, race_checkpointtime, race_laptime, race_mybestspeed, race_mybesttime, race_mycheckpoint, race_mycheckpointdelta, race_mycheckpointenemy, race_mycheckpointlapsdelta, race_mycheckpointtime, race_mypreviousbesttime, race_myrank, RACE_NET_CHECKPOINT_CLEAR, RACE_NET_CHECKPOINT_HIT_QUALIFYING, RACE_NET_CHECKPOINT_HIT_RACE, RACE_NET_CHECKPOINT_HIT_RACE_BY_OPPONENT, RACE_NET_CHECKPOINT_NEXT_QUALIFYING, RACE_NET_CHECKPOINT_NEXT_SPEC_QUALIFYING, RACE_NET_PENALTY_QUALIFYING, RACE_NET_PENALTY_RACE, RACE_NET_RANKINGS_CNT, RACE_NET_SERVER_RANKINGS, RACE_NET_SERVER_RECORD, RACE_NET_SERVER_STATUS, RACE_NET_SPEED_AWARD, RACE_NET_SPEED_AWARD_BEST, race_nextbestname, race_nextbestspeed, race_nextbesttime, race_nextcheckpoint, race_othercheckpoint, race_othercheckpointdelta, race_othercheckpointenemy, race_othercheckpointlapsdelta, race_othercheckpointtime, race_penaltyaccumulator, race_penaltyeventtime, race_penaltyreason, race_penaltytime, race_previousbestname, race_previousbesttime, race_server_record, race_speedaward, race_speedaward_alltimebest, race_speedaward_alltimebest_holder, race_speedaward_holder, race_status, race_status_name, race_time, race_timebestspeed, race_timespeed, RANKINGS_DISPLAY_CNT, ReadByte(), ReadFloat, ReadInt24_t(), ReadString, strcpy, strfree, and time.
| NET_HANDLE | ( | TE_CSQC_SERVERWELCOME | , |
| bool | isNew ) |
Definition at line 1502 of file main.qc.
References net_handle_ServerWelcome().
| NET_HANDLE | ( | TE_CSQC_WEAPONCOMPLAIN | , |
| bool | isNew ) |
Definition at line 1319 of file main.qc.
References complain_weapon, complain_weapon_time, complain_weapon_type, Local_Notification(), ReadByte(), REGISTRY_GET, time, Weapons, and weapontime.
| bool net_handle_ServerWelcome | ( | ) |
Definition at line 1386 of file main.qc.
References cache_mutatormsg, campaign, campaign_level, CCR(), cons_mid(), flags, gametype, getcommandkey, GetVersionMessage(), hostname, itos, localcmd(), M_ARGV, MakeConsoleSafe(), MapInfo_Map_author, MapInfo_Map_titlestring, MapInfo_Type_ToText(), MUTATOR_CALLHOOK, ReadByte(), ReadString, srv_maxplayers, srv_minplayers, strcat(), strcpy, time, translate_modifications(), translate_weaponarena(), welcome_msg, and welcome_msg_menu_check_maxtime.
Referenced by NET_HANDLE(), and NET_HANDLE().
Definition at line 421 of file main.qc.
References entcs_GetName(), entcs_GetScoreTeam(), entity(), maxclients, new_pure, nextthink, NULL, playerslots, RegisterPlayer(), RemovePlayer(), Scoreboard_UpdatePlayerPos(), SetTeam(), and time.
Referenced by PostInit().
| void PostInit | ( | ) |
Definition at line 463 of file main.qc.
References entity(), new_pure, Playerchecker_Think(), postinit, setthink, time, and TrueAim_Init().
Referenced by CSQC_UpdateView(), and NET_HANDLE().
Definition at line 245 of file main.qc.
References AuditLists(), entity(), error, and players.
Referenced by Playerchecker_Think().
Definition at line 292 of file main.qc.
References assert_once, AuditLists(), entity(), eprint(), error, NUM_SPECTATOR, team_count, and teams.
Referenced by GetTeam().
| void Release_Common_Keys | ( | ) |
Definition at line 477 of file main.qc.
References localcmd().
Referenced by HUD_Radar_Show_Maximized(), QuickMenu_Open(), and Scoreboard_UI_Enable().
Definition at line 261 of file main.qc.
References AuditLists(), entity(), error, parent, and players.
Referenced by Playerchecker_Think().
Definition at line 311 of file main.qc.
References AuditLists(), entity(), LOG_INFO, NUM_SPECTATOR, parent, team_count, and teams.
Definition at line 348 of file main.qc.
References entity(), GetTeam(), LOG_TRACEF, NULL, NUM_SPECTATOR, NUM_TEAM_1, NUM_TEAM_2, NUM_TEAM_3, NUM_TEAM_4, TC, and teamplay.
Referenced by Ent_RemovePlayerScore(), Playerchecker_Think(), and Scoreboard_UpdatePlayerTeams().
| void Shutdown | ( | ) |
Definition at line 162 of file main.qc.
References autocvar_chase_active, autocvar_cl_db_saveasdump, autocvar_r_drawviewmodel, binddb, calledhooks, camera_active, chase_active_backup, ClientProgsDB, cvar(), cvar_defstring(), cvar_set(), db_close(), db_dump(), db_save(), deactivate_minigame(), ftos(), gametype_custom_name, HOOK_END, HOOK_START, HUD_MinigameMenu_Close(), isdemo(), itos, localcmd(), NULL, players, ReplicateVars(), REPLICATEVARS_DESTROY, strcat(), strfree, teams, tempdb, and WarpZone_Shutdown().
Referenced by SV_Shutdown().
Definition at line 1337 of file main.qc.
Referenced by net_handle_ServerWelcome().
Definition at line 1342 of file main.qc.
References argv(), cons_mid(), LOG_INFO, Weapon::m_name, tokenizebyseparator, and Weapon_from_name().
Referenced by net_handle_ServerWelcome().
engine callback
Definition at line 1552 of file main.qc.
References Curl_URI_Get_Callback(), LOG_INFOF, TC, URI_GET_CURL, URI_GET_CURL_END, URI_GET_DISCARD, and url_URI_Get_Callback().
| void Welcome_Message_Show_Try | ( | ) |
Definition at line 1462 of file main.qc.
References autocvar_cl_welcome, cvar(), hostname, intermission, isdemo(), localcmd(), MakeConsoleSafe(), strcat(), strfree, time, welcome_msg, and welcome_msg_menu_check_maxtime.
Referenced by CSQC_UpdateView().
| bool autocvar_r_drawfog |
Definition at line 1034 of file main.qc.
Referenced by Fog_Force().
| bool autocvar_r_fog_exp2 |
Definition at line 1035 of file main.qc.
Referenced by Fog_Force().
| string forcefog |
Definition at line 1036 of file main.qc.
Referenced by Fog_Force(), and NET_HANDLE().
| int survival_status |
Definition at line 569 of file main.qc.
Referenced by surv_LastPlayerForTeam().