|
Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
|
|
#include "menu.qh"#include "item.qh"#include "anim/animhost.qh"#include "item/dialog.qh"#include "item/listbox.qh"#include "item/nexposee.qh"#include "xonotic/commandbutton.qh"#include "xonotic/mainwindow.qh"#include "xonotic/serverlist.qh"#include "xonotic/slider_resolution.qh"#include "xonotic/util.qh"#include <common/checkextension.qh>#include <common/items/_mod.qh>#include <common/weapons/_all.qh>#include <common/mapinfo.qh>#include <common/mutators/base.qh>Go to the source code of this file.
Enumerations | |
| enum | { SCALEMODE_CROP , SCALEMODE_LETTERBOX , SCALEMODE_WIDTH , SCALEMODE_HEIGHT , SCALEMODE_STRETCH } |
| anonymous enum |
| Enumerator | |
|---|---|
| SCALEMODE_CROP | |
| SCALEMODE_LETTERBOX | |
| SCALEMODE_WIDTH | |
| SCALEMODE_HEIGHT | |
| SCALEMODE_STRETCH | |
Definition at line 300 of file menu.qc.
Definition at line 307 of file menu.qc.
References draw_Picture(), draw_PictureSize(), draw_scale, eX, eY, org, SCALEMODE_CROP, SCALEMODE_HEIGHT, SCALEMODE_LETTERBOX, SCALEMODE_STRETCH, SCALEMODE_WIDTH, and vector.
Referenced by drawBackground().
| void draw_reset_cropped | ( | ) |
Definition at line 110 of file menu.qc.
References conheight, conwidth, draw_reset(), realconheight, and realconwidth.
Referenced by m_draw(), m_init_delayed(), m_keydown(), m_keyup(), preMenuInit(), and UpdateConWidthHeight().
| void draw_reset_full | ( | ) |
Definition at line 114 of file menu.qc.
References draw_reset(), realconheight, and realconwidth.
Referenced by m_draw().
Definition at line 337 of file menu.qc.
References draw_Picture_Aligned(), ftos(), GAME_CONNECTED, GAME_ISSERVER, gamestatus, LABEL, main, random(), SCALEMODE_CROP, SCALEMODE_HEIGHT, SCALEMODE_LETTERBOX, SCALEMODE_STRETCH, SCALEMODE_WIDTH, strcat(), strlen, substring(), and vector.
Referenced by m_draw().
| string gettooltip | ( | ) |
Definition at line 524 of file menu.qc.
References BIT, cvar1_setDependent, cvar1Max_setDependent, cvar1Min_setDependent, cvar2_setDependent, cvar2Max_setDependent, cvar2Min_setDependent, cvar3_setDependent, cvar3Max_setDependent, cvar3Min_setDependent, cvar_defstring(), cvar_string(), getCvarsMulti(), gettooltip_dependency_string_numeric(), menu_tooltips, menuTooltipItem, rgb_to_hexcolor(), and strcat().
Referenced by m_tooltip().
| string gettooltip_dependency_string_numeric | ( | entity | e, |
| .string | cvarStr, | ||
| .float | cvarMin, | ||
| .float | cvarMax, | ||
| float | not_if_equal ) |
Definition at line 510 of file menu.qc.
References entity(), and ftos_mindecimals().
Referenced by gettooltip().
Definition at line 1010 of file menu.qc.
References Container_setFocus(), entity(), m_activate_window(), NULL, and TabButton_Click().
Referenced by m_activate_window(), and m_goto().
Definition at line 439 of file menu.qc.
References conheight, conwidth, m_testtooltipbox(), menuTooltipSize, and vector.
Referenced by m_tooltip().
| void m_display | ( | ) |
Definition at line 949 of file menu.qc.
References KEY_MENU, main, Menu_Active, menuInitialized, menuMouseMode, menuMousePos, mouseButtonsPressed, MT_CLIENT, MT_MENU, setkeydest(), and setmousetarget().
Referenced by m_goto(), m_init(), m_init_delayed(), m_toggle(), and preMenuDraw().
Definition at line 748 of file menu.qc.
References anim, autocvar_g_campaign, autocvar_menu_no_music_nor_welcome, bound(), clientstate(), CS_DISCONNECTED, cvar(), cvar_set(), draw_alpha, draw_drawMousePointer(), draw_Fill(), draw_reset_cropped(), draw_reset_full(), draw_scale, draw_shift, drawBackground(), eX, execute_next_frame(), eY, frametime, ftos(), GAME_CONNECTED, GAME_ISSERVER, gamestatus, getkeydest(), getmousepos(), getmousetarget(), gettime(), globalToBox(), globalToBoxSize(), height, IL_ENDFRAME(), KEY_MENU, KEY_MENU_GRABBED, keyGrabber, localcmd(), m_gamestatus(), m_hide(), m_init_delayed(), m_sync(), m_toggle, m_tooltip(), main, max(), Menu_Active, menuAlpha, menuInitialized, menuLogoAlpha, menuMouseMode, menuMousePos, menuNotTheFirstFrame, menuPrevTime, min(), MIN_DISCONNECTION_TIME, mouseButtonsPressed, MT_CLIENT, MT_MENU, postMenuDraw(), preMenuDraw(), prevMenuAlpha, realconheight, realconwidth, setkeydest(), time, UpdateConWidthHeight(), and vector.
Definition at line 477 of file menu.qc.
References best, entity(), globalToBox(), menu_tooltips, NULL, and vector.
Referenced by m_tooltip().
Definition at line 1004 of file menu.qc.
References entity(), and m_focus_item_chain().
Referenced by m_focus_item_chain(), and m_setpointerfocus().
| void m_gamestatus | ( | ) |
Definition at line 53 of file menu.qc.
References clientstate(), CS_CONNECTED, cvar(), GAME_CONNECTED, GAME_DEVELOPER, GAME_ISSERVER, gamestatus, isdemo(), and isserver().
Referenced by m_draw().
Definition at line 1051 of file menu.qc.
References entity(), find(), GAME_CONNECTED, GAME_ISSERVER, gamestatus, m_activate_window(), m_display(), m_goto_buffer, m_hide(), m_setpointerfocus(), main, menuInitialized, name, NULL, and strcpy.
Referenced by Dialog_close(), GameCommand(), m_init_delayed(), XonoticNexposee_close(), and XonoticRootDialog_close().
| void m_hide | ( | ) |
Definition at line 964 of file menu.qc.
References KEY_GAME, main, Menu_Active, menuInitialized, MT_CLIENT, setkeydest(), and setmousetarget().
Referenced by m_draw(), m_goto(), m_init(), m_keydown(), m_toggle(), and Shutdown().
| void m_init | ( | ) |
Definition at line 61 of file menu.qc.
References CheckEngineExtensions(), cvar(), cvar_set(), cvar_string(), localcmd(), LOG_TRACEF, m_display(), m_hide(), prvm_language, registercvar(), RegisterSLCategories(), static_init, static_init_late, static_init_precache, strzone(), and updateCompression().
| void m_init_delayed | ( | ) |
Definition at line 160 of file menu.qc.
References anim, argv(), argv_end_index, argv_start_index, conheight, conwidth, cvar_defstring(), cvar_set(), cvar_string(), draw_reset_cropped(), draw_setMousePointer(), error, eX, eY, fclose(), fgets(), FILE_READ, fopen(), m_display(), m_goto(), m_goto_buffer, m_sync(), main, Menu_Active, menuInitialized, menuMousePos, menuShiftState, NEW, precache_pic(), preMenuInit(), search_begin(), search_end(), search_getfilename(), search_getsize(), strcat(), strfree, strzone(), substring(), and tokenize_console.
Referenced by m_draw().
Definition at line 251 of file menu.qc.
References draw_reset_cropped(), entity(), GAME_CONNECTED, GAME_ISSERVER, gamestatus, getmousepos(), K_ALT, K_CTRL, K_ESCAPE, K_MOUSE1, K_MOUSE3, K_SHIFT, keyGrabber, LOG_TRACE, m_hide(), main, Menu_Active, menuInitialized, menuMouseMode, menuMousePos, menuShiftState, mouseButtonsPressed, NULL, realconheight, realconwidth, S_ALT, S_CTRL, S_SHIFT, and vector.
Definition at line 230 of file menu.qc.
References draw_reset_cropped(), K_ALT, K_CTRL, K_MOUSE1, K_MOUSE3, K_SHIFT, LOG_TRACE, main, Menu_Active, menuInitialized, menuMousePos, menuShiftState, mouseButtonsPressed, S_ALT, S_CTRL, and S_SHIFT.
Definition at line 1106 of file menu.qc.
References cvar(), and localsound().
Referenced by Button_playClickSound(), CheckBox_playClickSound(), Dialog_keyDown(), GameCommand(), InputBox_keyDown(), InputBox_mouseRelease(), KeyBinder_Bind_Clear(), Nexposee::mousePress(), Nexposee_keyDown(), ServerList_Favorite_Click(), Slider_keyUp(), Slider_mouseRelease(), XonoticColorpicker_mouseRelease(), XonoticColorpickerString_mouseRelease(), XonoticGametypeList_clickListBoxItem(), XonoticGametypeList_keyDown(), XonoticHUDSkinList_doubleClickListBoxItem(), XonoticKeyBinder_keyGrabbed(), XonoticLanguageList_doubleClickListBoxItem(), XonoticLanguageList_keyDown(), XonoticMapList_clickListBoxItem(), XonoticMapList_doubleClickListBoxItem(), XonoticMapList_keyDown(), XonoticServerList_keyDown(), XonoticSkinList_doubleClickListBoxItem(), XonoticSkinList_keyDown(), XonoticTopicList_clickListBoxItem(), XonoticTopicList_keyDown(), and XonoticWinnerDialog_focusEnter().
| void m_play_focus_sound | ( | ) |
Definition at line 1097 of file menu.qc.
References cvar(), localsound(), MENU_SOUND_FOCUS, and time.
Referenced by MenuItem::focusEnter().
Definition at line 1038 of file menu.qc.
References conheight, conwidth, entity(), m_focus_item_chain(), and menuMousePos.
Referenced by m_goto().
| void m_sync | ( | ) |
Definition at line 45 of file menu.qc.
References loadAllCvars(), main, updateCompression(), vidheight_s, vidpixelheight_s, and vidwidth_s.
Referenced by GameCommand(), m_draw(), and m_init_delayed().
Definition at line 423 of file menu.qc.
References menuTooltipOrigin, menuTooltipSize, and vector.
Referenced by m_tooltip().
Definition at line 430 of file menu.qc.
References menuTooltipOrigin, menuTooltipSize, and vector.
Referenced by m_allocatetooltipbox().
Definition at line 976 of file menu.qc.
References GAME_CONNECTED, gamestatus, m_display(), m_hide(), and Menu_Active.
Definition at line 581 of file menu.qc.
References argv(), bound(), conheight, conwidth, cvar(), draw_BorderPicture(), draw_Text(), draw_TextWidth_WithColors(), entity(), frametime, gettooltip(), getWrappedLine(), getWrappedLine_remaining, m_allocatetooltipbox(), m_findtooltipitem(), m_testmousetooltipbox(), main, menu_tooltips, menu_tooltips_old, menuTooltipAlpha, menuTooltipAveragedMousePos, menuTooltipItem, menuTooltipOrigin, menuTooltipSize, menuTooltipState, menuTooltipText, NULL, strcpy, strfree, tokenizebyseparator, vdist, and vector.
Referenced by m_draw().
| void Shutdown | ( | ) |
Definition at line 994 of file menu.qc.
References cvar_set(), FOREACH_ENTITY_ORDERED, and m_hide().
Definition at line 119 of file menu.qc.
References conheight, conheight_s, conwidth, conwidth_s, cvar(), cvar_string(), draw_reset_cropped(), eX, eY, localcmd(), main, MENU_ASPECT, menuNotTheFirstFrame, realconheight, realconwidth, updateConwidths(), vidheight_s, vidpixelheight_s, and vidwidth_s.
Referenced by m_draw().
| bool autocvar_g_campaign |
Definition at line 747 of file menu.qc.
Referenced by bot_setnameandstuff(), bot_think(), ClientCommand_clientversion(), CommonCommand_editmob(), DoNextMapOverride(), GameCommand_warp(), GameRules_limit_lead(), GameRules_limit_score(), GameRules_limit_time(), GameRules_limit_time_qualifying(), GetWinningCode(), InitiateSuddenDeath(), Join(), m_draw(), Monster_Move(), Monster_Move_2D(), MUTATOR_HOOKFUNCTION(), MUTATOR_HOOKFUNCTION(), NextLevel(), Onslaught_CheckWinner(), Player_DetermineForcedTeam(), PlayerPreThink(), QueueNeeded(), rc_SetLimits(), readlevelcvars(), ReadyRestart(), ReadyRestart_force(), round_handler_Think(), SendWelcomeMessage(), ShowTeamSelection(), spawnfunc(), target_changelevel_use(), target_levelwarp_use(), TeamBalance_GetTeamCounts(), TeamBalance_RemoveExcessPlayers(), WinningCondition_Assault(), and WinningCondition_LMS().
| bool autocvar_menu_no_music_nor_welcome |
| float conheight_s |
Definition at line 41 of file menu.qc.
Referenced by UpdateConWidthHeight().
| string controlledCvar |
Definition at line 16 of file menu.qc.
Referenced by XonoticCampaignList::ATTRIB(), XonoticCheckBox::ATTRIB(), XonoticCheckBoxString::ATTRIB(), XonoticColorButton::ATTRIB(), XonoticColorpickerString::ATTRIB(), XonoticInputBox::ATTRIB(), XonoticMixedSlider::ATTRIB(), XonoticRadioButton::ATTRIB(), XonoticSlider::ATTRIB(), and XonoticTextSlider::ATTRIB().
| float conwidth_s |
Definition at line 41 of file menu.qc.
Referenced by UpdateConWidthHeight().
| string m_goto_buffer |
Definition at line 159 of file menu.qc.
Referenced by m_goto(), and m_init_delayed().
| const float MENU_ASPECT = 1280 / 1024 |
Definition at line 108 of file menu.qc.
Referenced by UpdateConWidthHeight().
| int menu_tooltips |
Definition at line 414 of file menu.qc.
Referenced by gettooltip(), m_findtooltipitem(), and m_tooltip().
| int menu_tooltips_old |
Definition at line 415 of file menu.qc.
Referenced by m_tooltip().
| bool menuInitialized |
Definition at line 33 of file menu.qc.
Referenced by m_display(), m_draw(), m_goto(), m_hide(), m_init_delayed(), m_keydown(), and m_keyup().
| int menuMouseMode |
Definition at line 34 of file menu.qc.
Referenced by m_display(), m_draw(), and m_keydown().
| vector menuMousePos |
Definition at line 27 of file menu.qc.
Referenced by m_display(), m_draw(), m_init_delayed(), m_keydown(), m_keyup(), and m_setpointerfocus().
| int menuNotTheFirstFrame |
Definition at line 38 of file menu.qc.
Referenced by m_draw(), and UpdateConWidthHeight().
| int menuShiftState |
Definition at line 28 of file menu.qc.
Referenced by m_init_delayed(), m_keydown(), and m_keyup().
| float menuTooltipAlpha |
Definition at line 420 of file menu.qc.
Referenced by m_tooltip().
| vector menuTooltipAveragedMousePos |
Definition at line 416 of file menu.qc.
Referenced by m_tooltip().
| entity menuTooltipItem |
Definition at line 417 of file menu.qc.
Referenced by gettooltip(), and m_tooltip().
| vector menuTooltipOrigin |
Definition at line 418 of file menu.qc.
Referenced by m_testmousetooltipbox(), m_testtooltipbox(), and m_tooltip().
| vector menuTooltipSize |
Definition at line 419 of file menu.qc.
Referenced by m_allocatetooltipbox(), m_testmousetooltipbox(), m_testtooltipbox(), and m_tooltip().
| int menuTooltipState |
Definition at line 422 of file menu.qc.
Referenced by m_tooltip().
| string menuTooltipText |
Definition at line 421 of file menu.qc.
Referenced by m_tooltip().
| const int MIN_DISCONNECTION_TIME = 1 |
| int mouseButtonsPressed |
Definition at line 26 of file menu.qc.
Referenced by m_display(), m_draw(), m_keydown(), and m_keyup().
| float realconheight |
Definition at line 43 of file menu.qc.
Referenced by draw_reset_cropped(), draw_reset_full(), m_draw(), m_keydown(), and UpdateConWidthHeight().
| float realconwidth |
Definition at line 43 of file menu.qc.
Referenced by draw_reset_cropped(), draw_reset_full(), m_draw(), m_keydown(), and UpdateConWidthHeight().
| float vidheight_s |
Definition at line 42 of file menu.qc.
Referenced by m_sync(), and UpdateConWidthHeight().
| float vidpixelheight_s |
Definition at line 42 of file menu.qc.
Referenced by m_sync(), and UpdateConWidthHeight().
| float vidwidth_s |
Definition at line 42 of file menu.qc.
Referenced by m_sync(), and UpdateConWidthHeight().