]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blob - qcsrc/menu/xonotic/dialog_multiplayer_playersetup_waypoint.c
Merge remote branch 'origin/master' into samual/hud_updates
[xonotic/xonotic-data.pk3dir.git] / qcsrc / menu / xonotic / dialog_multiplayer_playersetup_waypoint.c
1 #ifdef INTERFACE
2 CLASS(XonoticWaypointDialog) EXTENDS(XonoticDialog)
3         METHOD(XonoticWaypointDialog, fill, void(entity))
4         METHOD(XonoticWaypointDialog, showNotify, void(entity))
5         ATTRIB(XonoticWaypointDialog, title, string, _("Waypoints"))
6         ATTRIB(XonoticWaypointDialog, color, vector, SKINCOLOR_DIALOG_WAYPOINTS)
7         ATTRIB(XonoticWaypointDialog, intendedWidth, float, 0.5)
8         ATTRIB(XonoticWaypointDialog, rows, float, 5)
9         ATTRIB(XonoticWaypointDialog, columns, float, 3)
10 ENDCLASS(XonoticWaypointDialog)
11 #endif
12
13 #ifdef IMPLEMENTATION
14 void XonoticWaypointDialog_showNotify(entity me)
15 {
16         loadAllCvars(me);
17 }
18 void XonoticWaypointDialog_fill(entity me)
19 {
20         entity e;
21
22         me.TR(me);
23                 me.TD(me, 1, 3, e = makeXonoticCheckBox(1, "cl_hidewaypoints", _("Show base waypoints")));
24         me.TR(me);
25                 me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Waypoint scale:")));
26                         me.TD(me, 1, 2, e = makeXonoticSlider(0.5, 1.5, 0.05, "g_waypointsprite_scale"));
27                                 setDependent(e, "cl_hidewaypoints", 0, 0);
28         me.TR(me);
29                 me.TD(me, 1, 1, e = makeXonoticTextLabel(0, _("Waypoint alpha:")));
30                         me.TD(me, 1, 2, e = makeXonoticSlider(0.1, 1, 0.05, "g_waypointsprite_alpha"));
31                                 setDependent(e, "cl_hidewaypoints", 0, 0);
32         me.TR(me);
33                 me.TD(me, 1, 3, e = makeXonoticCheckBox(1, "hud_shownames", _("Show names above players")));
34         me.gotoRC(me, me.rows - 1, 0);
35                 me.TD(me, 1, me.columns, e = makeXonoticButton(_("OK"), '0 0 0'));
36                         e.onClick = Dialog_Close;
37                         e.onClickEntity = me;
38 }
39 #endif