-#ifndef CLIENT_ALL_H
-#define CLIENT_ALL_H
+#ifndef MENU_ALL_H
+#define MENU_ALL_H
+
+#include "draw.qh"
+#include "xonotic/util.qh"
#endif
entity e;
string s;
- for(i = 0, e = world; (e = nextent(e)); )
+ for(i = 0, e = NULL; (e = nextent(e)); )
if(e.classname != "vtbl" && e.name != "")
{
s = e.name;
#ifndef GAMESETTINGS_H
#define GAMESETTINGS_H
+#include "xonotic/tab.qc"
+
REGISTRY(Settings, BIT(3))
REGISTER_REGISTRY(RegisterSettings)
#define REGISTER_SETTINGS(id, impl) \
vector fs;
animating = 0;
- front = world;
+ front = NULL;
for(e = me.firstChild; e; e = e.nextSibling)
if(e.ModalController_state)
{
ATTRIB(Slider, value, float, 0)
ATTRIB(Slider, animated, float, 1)
ATTRIB(Slider, sliderValue, float, 0)
- ATTRIB(Slider, sliderAnim, entity, world)
+ ATTRIB(Slider, sliderAnim, entity, NULL)
ATTRIB(Slider, valueMin, float, 0)
ATTRIB(Slider, valueMax, float, 0)
ATTRIB(Slider, valueStep, float, 0)
if(me.sliderAnim.isFinished(me.sliderAnim))
{
anim.removeObjAnim(anim, me);
- me.sliderAnim = world;
+ me.sliderAnim = NULL;
}
me.setText(me, me.valueToText(me, me.value));
entity it;
entity best;
- best = world;
+ best = NULL;
it = root;
while(it.instanceOfContainer)
best = it;
else if(menu_tooltips == 2 && (it.cvarName || it.onClickCommand))
best = it;
- it = world;
+ it = NULL;
}
else if(it.instanceOfModalController)
it = it.focusedChild;
if (!menu_tooltips)
{
// don't return immediately, fade out the active tooltip first
- if (menuTooltipItem == world)
+ if (menuTooltipItem == NULL)
return;
- it = world;
+ it = NULL;
menu_tooltips_old = menu_tooltips;
}
else
if(f < 0.01)
it = m_findtooltipitem(main, pos);
else
- it = world;
+ it = NULL;
}
fontsize = '1 0 0' * (SKINFONTSIZE_TOOLTIP / conwidth) + '0 1 0' * (SKINFONTSIZE_TOOLTIP / conheight);
if(menuTooltipAlpha == 0)
{
menuTooltipState = 0;
- menuTooltipItem = world;
+ menuTooltipItem = NULL;
}
break;
}
- if(menuTooltipItem == world)
+ if(menuTooltipItem == NULL)
{
if (menuTooltipText)
{
if(menu_tooltips != menu_tooltips_old)
{
if (menu_tooltips != 0 && menu_tooltips_old != 0)
- menuTooltipItem = world; // reload tooltip next frame
+ menuTooltipItem = NULL; // reload tooltip next frame
menu_tooltips_old = menu_tooltips;
}
else if(menuTooltipOrigin.x < 0) // unallocated?
{
if (scan == K_MOUSE3 || ((shift & S_CTRL) && scan == K_SPACE))
{
- CvarList_Revert_Click(world, me);
+ CvarList_Revert_Click(NULL, me);
return 1;
}
else if(scan == K_ENTER)
// to press buttons while browsing with only the keyboard
if (shift & S_CTRL)
{
- toggleSlideShow_Click(world, me);
+ toggleSlideShow_Click(NULL, me);
return 1;
}
return SUPER(XonoticScreenshotViewerDialog).keyDown(me, key, ascii, shift);
if(me.dialogToShow)
{
- DialogOpenButton_Click_withCoords(world, me.dialogToShow, '0 0 0', eX * conwidth + eY * conheight);
+ DialogOpenButton_Click_withCoords(NULL, me.dialogToShow, '0 0 0', eX * conwidth + eY * conheight);
me.dialogToShow = NULL;
}
}
else
me.filterString = string_null;
- ScreenshotList_Refresh_Click(world, me);
+ ScreenshotList_Refresh_Click(NULL, me);
}
void ScreenshotList_Filter_Would_Change(entity box, entity me)
else
{
error(sprintf("RetrieveCategoryEnt(%d): Improper category number!\n", catnum));
- return world;
+ return NULL;
}
}
ATTRIB(XonoticSoundList, itemAbsSize, vector, '0 0 0')
ATTRIB(XonoticSoundList, filterString, string, string_null)
- ATTRIB(XonoticSoundList, playlist, entity, world)
+ ATTRIB(XonoticSoundList, playlist, entity, NULL)
ENDCLASS(XonoticSoundList)
entity makeXonoticSoundList();
#include "util.qh"
+
+#include "../item.qc"
+
#include "../menu.qh"
#include "../../common/campaign_common.qh"
#include "../../common/constants.qh"