Xonotic
dialog_disconnect.qc
Go to the documentation of this file.
1
#include "
dialog_disconnect.qh
"
2
3
#include "
textlabel.qh
"
4
#include "
button.qh
"
5
6
void
Disconnect_Click
(
entity
btn,
entity
me)
7
{
8
localcmd
(
"disconnect\n"
);
9
Dialog_Close
(btn, me);
10
}
11
12
void
XonoticDisconnectDialog_fill
(
entity
me)
13
{
14
entity
e;
15
me.TR(me);
16
me.TD(me, 1, 2,
makeXonoticTextLabel
(0.5, _(
"Are you sure to disconnect from server?"
)));
17
me.TR(me);
18
me.TR(me);
19
me.TD(me, 1, 1, e =
makeXonoticButton_T
(_(
"Yes"
),
'1 0 0'
, _(
"I would disconnect from server..."
)));
20
e.onClick =
Disconnect_Click
;
21
e.onClickEntity = me;
22
me.TD(me, 1, 1, e =
makeXonoticButton_T
(_(
"No"
),
'0 1 0'
, _(
"I would play more!"
)));
23
e.onClick =
Dialog_Close
;
24
e.onClickEntity = me;
25
}
dialog_disconnect.qh
makeXonoticButton_T
entity makeXonoticButton_T(string theText, vector theColor, string theTooltip)
Definition:
button.qc:3
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
Disconnect_Click
void Disconnect_Click(entity btn, entity me)
Definition:
dialog_disconnect.qc:6
textlabel.qh
button.qh
XonoticDisconnectDialog_fill
void XonoticDisconnectDialog_fill(entity me)
Definition:
dialog_disconnect.qc:12
menu
xonotic
dialog_disconnect.qc
Generated on Thu Mar 17 2022 17:26:29 for Xonotic by
1.8.13