]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/menu/xonotic/dialog_multiplayer_playersetup_crosshair.c
Create hud settings dialog, and reorganize the setup in mainwindow.c with comments...
[xonotic/xonotic-data.pk3dir.git] / qcsrc / menu / xonotic / dialog_multiplayer_playersetup_crosshair.c
1 #ifdef INTERFACE
2 CLASS(XonoticCrosshairDialog) EXTENDS(XonoticDialog)
3         METHOD(XonoticCrosshairDialog, toString, string(entity))
4         METHOD(XonoticCrosshairDialog, fill, void(entity))
5         METHOD(XonoticCrosshairDialog, showNotify, void(entity))
6         ATTRIB(XonoticCrosshairDialog, title, string, _("Crosshair settings"))
7         ATTRIB(XonoticCrosshairDialog, color, vector, SKINCOLOR_DIALOG_CROSSHAIR)
8         ATTRIB(XonoticCrosshairDialog, intendedWidth, float, 0.5)
9         ATTRIB(XonoticCrosshairDialog, rows, float, 12)
10         ATTRIB(XonoticCrosshairDialog, columns, float, 3)
11 ENDCLASS(XonoticCrosshairDialog)
12 #endif
13
14 #ifdef IMPLEMENTATION
15 void XonoticCrosshairDialog_showNotify(entity me)
16 {
17         loadAllCvars(me);
18 }
19 string XonoticCrosshairDialog_toString(entity me)
20 {
21         return "hi"; // TODO: show status of crosshair dot and hittest and pickups and such here with text
22 }
23 void XonoticCrosshairDialog_fill(entity me)
24 {
25         entity e;
26         
27
28                 
29         me.gotoRC(me, me.rows - 1, 0);
30                 me.TD(me, 1, me.columns, e = makeXonoticButton(_("OK"), '0 0 0'));
31                         e.onClick = Dialog_Close;
32                         e.onClickEntity = me;
33 }
34 #endif