Xonotic
dialog_settings_game_hudconfirm.qc
Go to the documentation of this file.
1
#include "
dialog_settings_game_hudconfirm.qh
"
2
3
#include "
textlabel.qh
"
4
#include "
button.qh
"
5
6
void
HUDSetup_Start
(
entity
me,
entity
btn)
7
{
8
if
(!(
gamestatus
& (
GAME_CONNECTED
|
GAME_ISSERVER
)))
9
localcmd
(
"map _hudsetup\n"
);
10
else
11
localcmd
(
"togglemenu 0\n"
);
12
13
localcmd
(
"_hud_configure 1\n"
);
14
}
15
16
void
XonoticHUDConfirmDialog_fill
(
entity
me)
17
{
18
entity
e;
19
20
me.TR(me);
21
me.TD(me, 1, 2, e =
makeXonoticTextLabel
(0.5, _(
"In order for the HUD editor to show, you must first be in game."
)));
22
me.TR(me);
23
me.TD(me, 1, 2, e =
makeXonoticTextLabel
(0.5, _(
"Do you wish to start a local game to set up the HUD?"
)));
24
me.TR(me);
25
me.TR(me);
26
me.TD(me, 1, 1, e =
makeXonoticButton
(_(
"Yes"
),
'1 0 0'
));
27
e.onClick =
HUDSetup_Start
;
28
e.onClickEntity = me;
29
me.TD(me, 1, 1, e =
makeXonoticButton
(_(
"No"
),
'0 1 0'
));
30
e.onClick =
Dialog_Close
;
31
e.onClickEntity = me;
32
}
GAME_ISSERVER
const int GAME_ISSERVER
Definition:
menu.qh:11
HUDSetup_Start
void HUDSetup_Start(entity me, entity btn)
Definition:
dialog_settings_game_hudconfirm.qc:6
makeXonoticButton
entity makeXonoticButton(string theText, vector theColor)
Definition:
button.qc:10
Dialog_Close
void Dialog_Close(entity button, entity me)
Definition:
dialog.qc:7
localcmd
#define localcmd
Definition:
menudefs.qh:21
entity
entity() spawn
makeXonoticTextLabel
entity makeXonoticTextLabel(float theAlign, string theText)
Definition:
textlabel.qc:3
XonoticHUDConfirmDialog_fill
void XonoticHUDConfirmDialog_fill(entity me)
Definition:
dialog_settings_game_hudconfirm.qc:16
dialog_settings_game_hudconfirm.qh
gamestatus
int gamestatus
Definition:
menu.qh:16
GAME_CONNECTED
const int GAME_CONNECTED
Definition:
menu.qh:12
textlabel.qh
button.qh
menu
xonotic
dialog_settings_game_hudconfirm.qc
Generated on Thu Mar 17 2022 17:26:29 for Xonotic by
1.8.13