camera_active = false;
}
}
+ else
#ifdef CAMERATEST
- else if(autocvar_camera_enable)
+ if(autocvar_camera_enable)
#else
- else if(autocvar_camera_enable && isdemo())
+ if(autocvar_camera_enable && isdemo())
#endif
{
// Enable required Darkplaces cvars
#define CLIENT_COMMAND(name,function,description) \
{ if(strtolower(description) != "") { print(" ^2", name, "^7: ", description, "\n"); } }
- CLIENT_COMMANDS(0, 0)
+ CLIENT_COMMANDS(0, 0);
#undef CLIENT_COMMAND
return;
#define CLIENT_COMMAND(name,function,description) \
{ if(name == strtolower(argv(0))) { function; return true; } }
- CLIENT_COMMANDS(CMD_REQUEST_COMMAND, argc)
+ CLIENT_COMMANDS(CMD_REQUEST_COMMAND, argc);
#undef CLIENT_COMMAND
return false;
#define CLIENT_COMMAND(name,function,description) \
{ if(name == strtolower(argv(1))) { function; return true; } }
- CLIENT_COMMANDS(CMD_REQUEST_USAGE, argc)
+ CLIENT_COMMANDS(CMD_REQUEST_USAGE, argc);
#undef CLIENT_COMMAND
return false;
#define CLIENT_COMMAND(name,function,description) \
{ if(strtolower(description) != "") { CMD_Write_Alias("qc_cmd_cl", name, description); } }
- CLIENT_COMMANDS(0, 0)
+ CLIENT_COMMANDS(0, 0);
#undef CLIENT_COMMAND
return;
// These functions are here specifically to add special + - commands to the game, and are not really normal commands.
// Please add client commands to the function above this, as this is only for special reasons.
-#define CONSOLE_COMMANDS_NORMAL \
+#define CONSOLE_COMMANDS_NORMAL() \
CONSOLE_COMMAND("+showscores", { scoreboard_showscores = true; }) \
CONSOLE_COMMAND("-showscores", { scoreboard_showscores = false; }) \
CONSOLE_COMMAND("+showaccuracy", { scoreboard_showaccuracy = true; }) \
CONSOLE_COMMAND("-showaccuracy", { scoreboard_showaccuracy = false; }) \
/* nothing */
-#define CONSOLE_COMMANDS_MOVEMENT \
+#define CONSOLE_COMMANDS_MOVEMENT() \
CONSOLE_COMMAND("+forward", { ++camera_direction.x; }) \
CONSOLE_COMMAND("-forward", { --camera_direction.x; }) \
CONSOLE_COMMAND("+back", { --camera_direction.x; }) \
#define CONSOLE_COMMAND(name,execution) \
{ registercommand(name); }
- CONSOLE_COMMANDS_NORMAL
+ CONSOLE_COMMANDS_NORMAL();
#undef CONSOLE_COMMAND
// then init movement commands
#define CONSOLE_COMMAND(name,execution) \
{ registercommand(name); }
- CONSOLE_COMMANDS_MOVEMENT
+ CONSOLE_COMMANDS_MOVEMENT();
#undef CONSOLE_COMMAND
#ifndef CAMERATEST
}
#define CONSOLE_COMMAND(name,execution) \
{ if(name == strtolower(argv(0))) { { execution } return true; } }
- CONSOLE_COMMANDS_NORMAL
+ CONSOLE_COMMANDS_NORMAL();
#undef CONSOLE_COMMAND
return false;
#define CONSOLE_COMMAND(name,execution) \
{ if(name == strtolower(argv(0))) { { execution } return true; } }
- CONSOLE_COMMANDS_MOVEMENT
+ CONSOLE_COMMANDS_MOVEMENT();
#undef CONSOLE_COMMAND
}
// player "pops in"
if(isnew)
{
-#define FIX_FRAMETIME(f,ft) \
- if(IS_DEAD_FRAME(self.f) && self.ft != 0 && self.death_time != 0) \
- { \
- self.ft = self.death_time; \
- }
- FIX_FRAMETIME(frame, frame1time)
- FIX_FRAMETIME(frame2, frame2time)
+#define FIX_FRAMETIME(f,ft) do { \
+ if(IS_DEAD_FRAME(self.f) && self.ft != 0 && self.death_time != 0) \
+ self.ft = self.death_time; \
+} while(0)
+ FIX_FRAMETIME(frame, frame1time);
+ FIX_FRAMETIME(frame2, frame2time);
#ifdef CSQCMODEL_HAVE_TWO_FRAMES
- FIX_FRAMETIME(frame3, frame3time)
- FIX_FRAMETIME(frame4, frame4time)
+ FIX_FRAMETIME(frame3, frame3time);
+ FIX_FRAMETIME(frame4, frame4time);
#endif
}
self.csqcmodel_isdead = IS_DEAD_FRAME(self.frame);
*/
// draw the background/borders
-#define HUD_Panel_DrawBg(theAlpha)\
-if(panel.current_panel_bg != "0" && panel.current_panel_bg != "")\
- draw_BorderPicture(panel_pos - '1 1 0' * panel_bg_border, panel.current_panel_bg, panel_size + '1 1 0' * 2 * panel_bg_border, panel_bg_color, panel_bg_alpha * theAlpha, '1 1 0' * (panel_bg_border/BORDER_MULTIPLIER))
+#define HUD_Panel_DrawBg(theAlpha) do { \
+ if(panel.current_panel_bg != "0" && panel.current_panel_bg != "") \
+ draw_BorderPicture(panel_pos - '1 1 0' * panel_bg_border, panel.current_panel_bg, panel_size + '1 1 0' * 2 * panel_bg_border, panel_bg_color, panel_bg_alpha * theAlpha, '1 1 0' * (panel_bg_border/BORDER_MULTIPLIER));\
+} while(0)
//basically the same code of draw_ButtonPicture and draw_VertButtonPicture for the menu
void HUD_Panel_DrawProgressBar(vector theOrigin, vector theSize, string pic, float length_ratio, float vertical, float baralign, vector theColor, float theAlpha, float drawflag)
// Info messages panel (#14)
//
-#define drawInfoMessage(s)\
- if(autocvar_hud_panel_infomessages_flip)\
- o_x = pos.x + mySize.x - stringwidth(s, true, fontsize);\
- drawcolorcodedstring(o, s, fontsize, a, DRAWFLAG_NORMAL);\
- o.y += fontsize.y;
+#define drawInfoMessage(s) do { \
+ if(autocvar_hud_panel_infomessages_flip) \
+ o_x = pos.x + mySize.x - stringwidth(s, true, fontsize); \
+ drawcolorcodedstring(o, s, fontsize, a, DRAWFLAG_NORMAL); \
+ o.y += fontsize.y; \
+} while(0)
void HUD_InfoMessages(void)
{
if(!autocvar__hud_configure)
s = _("^1Observing");
else
s = sprintf(_("^1Spectating: ^7%s"), GetPlayerName(player_localentnum - 1));
- drawInfoMessage(s)
+ drawInfoMessage(s);
if(spectatee_status == -1)
s = sprintf(_("^1Press ^3%s^1 to spectate"), getcommandkey("primary fire", "+fire"));
else
s = sprintf(_("^1Press ^3%s^1 or ^3%s^1 for next or previous player"), getcommandkey("next weapon", "weapnext"), getcommandkey("previous weapon", "weapprev"));
- drawInfoMessage(s)
+ drawInfoMessage(s);
if(spectatee_status == -1)
s = sprintf(_("^1Use ^3%s^1 or ^3%s^1 to change the speed"), getcommandkey("next weapon", "weapnext"), getcommandkey("previous weapon", "weapprev"));
else
s = sprintf(_("^1Press ^3%s^1 to observe"), getcommandkey("secondary fire", "+fire2"));
- drawInfoMessage(s)
+ drawInfoMessage(s);
s = sprintf(_("^1Press ^3%s^1 for gamemode info"), getcommandkey("server info", "+show_info"));
- drawInfoMessage(s)
+ drawInfoMessage(s);
if(gametype == MAPINFO_TYPE_LMS)
{
}
else
s = sprintf(_("^1Press ^3%s^1 to join"), getcommandkey("jump", "+jump"));
- drawInfoMessage(s)
+ drawInfoMessage(s);
//show restart countdown:
if (time < getstatf(STAT_GAMESTARTTIME)) {
if(warmup_stage && !intermission)
{
s = _("^2Currently in ^1warmup^2 stage!");
- drawInfoMessage(s)
+ drawInfoMessage(s);
}
string blinkcolor;
else
s = _("^2Waiting for others to ready up...");
}
- drawInfoMessage(s)
+ drawInfoMessage(s);
}
else if(warmup_stage && !intermission && !spectatee_status)
{
s = sprintf(_("^2Press ^3%s^2 to end warmup"), getcommandkey("ready", "ready"));
- drawInfoMessage(s)
+ drawInfoMessage(s);
}
if(teamplay && !intermission && !spectatee_status && gametype != MAPINFO_TYPE_CA && teamnagger)
if (tm.team != NUM_SPECTATOR)
if (tm.team_size == ts_max)
s = strcat(s, sprintf(_(" Press ^3%s%s to adjust"), getcommandkey("team menu", "menu_showteamselect"), blinkcolor));
- drawInfoMessage(s)
+ drawInfoMessage(s);
}
}
}
else
{
s = _("^7Press ^3ESC ^7to show HUD options.");
- drawInfoMessage(s)
+ drawInfoMessage(s);
s = _("^3Doubleclick ^7a panel for panel-specific options.");
- drawInfoMessage(s)
+ drawInfoMessage(s);
s = _("^3CTRL ^7to disable collision testing, ^3SHIFT ^7and");
- drawInfoMessage(s)
+ drawInfoMessage(s);
s = _("^3ALT ^7+ ^3ARROW KEYS ^7for fine adjustments.");
- drawInfoMessage(s)
+ drawInfoMessage(s);
}
}
{
if(self.count & 0x10)
{
- trace_endpos = self.velocity,
+ trace_endpos = self.velocity;
trace_dphitq3surfaceflags = 0;
}
else
drawpic_aspect_skin_expanding(position, pic, theScale, rgb, theAlpha, flag, fadelerp);
drawpic_skin(position, pic, theScale, rgb, theAlpha * fadelerp, flag);
}
-#define SET_POS_AND_SZ_Y_ASPECT(allow_colors)\
- float textaspect, oldsz;\
- textaspect = stringwidth(text, allow_colors, '1 1 1' * sz.y) / sz.y;\
- if(sz.x/sz.y > textaspect) {\
- oldsz = sz.x;\
- sz_x = sz.y * textaspect;\
- pos.x += (oldsz - sz.x) * 0.5;\
- } else {\
- oldsz = sz.y;\
- sz_y = sz.x / textaspect; \
- pos.y += (oldsz - sz.y) * 0.5;\
- }
+#define SET_POS_AND_SZ_Y_ASPECT(allow_colors) do { \
+ float textaspect, oldsz; \
+ textaspect = stringwidth(text, allow_colors, '1 1 1' * sz.y) / sz.y; \
+ if(sz.x/sz.y > textaspect) { \
+ oldsz = sz.x; \
+ sz_x = sz.y * textaspect; \
+ pos.x += (oldsz - sz.x) * 0.5; \
+ } else { \
+ oldsz = sz.y; \
+ sz_y = sz.x / textaspect; \
+ pos.y += (oldsz - sz.y) * 0.5; \
+ } \
+} while(0)
// drawstring wrapper to draw a string as large as possible with preserved aspect ratio into a box
void drawstring_aspect(vector pos, string text, vector sz, vector color, float theAlpha, float drawflag) {
- SET_POS_AND_SZ_Y_ASPECT(false)
+ SET_POS_AND_SZ_Y_ASPECT(false);
drawstring(pos, text, '1 1 0' * sz.y, color, theAlpha, drawflag);
}
// drawstring wrapper to draw a colorcodedstring as large as possible with preserved aspect ratio into a box
void drawcolorcodedstring_aspect(vector pos, string text, vector sz, float theAlpha, float drawflag) {
- SET_POS_AND_SZ_Y_ASPECT(true)
+ SET_POS_AND_SZ_Y_ASPECT(true);
drawcolorcodedstring(pos, text, '1 1 0' * sz.y, theAlpha, drawflag);
}
// drawstring wrapper to draw a string as large as possible with preserved aspect ratio into a box
void drawstring_aspect_expanding(vector pos, string text, vector sz, vector color, float theAlpha, float drawflag, float fadelerp) {
- SET_POS_AND_SZ_Y_ASPECT(false)
+ SET_POS_AND_SZ_Y_ASPECT(false);
drawstring_expanding(pos, text, '1 1 0' * sz.y, color, theAlpha, drawflag, fadelerp);
}
}
void drawcolorcodedstring_aspect_expanding(vector pos, string text, vector sz, float theAlpha, float drawflag, float fadelerp) {
- SET_POS_AND_SZ_Y_ASPECT(true)
+ SET_POS_AND_SZ_Y_ASPECT(true);
drawcolorcodedstring_expanding(pos, text, '1 1 0' * sz.y, theAlpha, drawflag, fadelerp);
}
#define GENERIC_COMMAND(name,function,description) \
{ print(" ^2", name, "^7: ", description, "\n"); }
- GENERIC_COMMANDS(0, 0, "")
+ GENERIC_COMMANDS(0, 0, "");
#undef GENERIC_COMMAND
return;
#define GENERIC_COMMAND(name,function,description) \
{ if(name == strtolower(argv(0))) { function; return true; } }
- GENERIC_COMMANDS(CMD_REQUEST_COMMAND, argc, command)
+ GENERIC_COMMANDS(CMD_REQUEST_COMMAND, argc, command);
#undef GENERIC_COMMAND
return false;
#define GENERIC_COMMAND(name,function,description) \
{ if(name == strtolower(argv(1))) { function; return true; } }
- GENERIC_COMMANDS(CMD_REQUEST_USAGE, argc, "")
+ GENERIC_COMMANDS(CMD_REQUEST_USAGE, argc, "");
#undef GENERIC_COMMAND
return false;
#define GENERIC_COMMAND(name,function,description) \
{ CMD_Write_Alias("qc_cmd_svmenu", name, description); }
- GENERIC_COMMANDS(0, 0, "")
+ GENERIC_COMMANDS(0, 0, "");
#undef GENERIC_COMMAND
return;
entity notif;
int i;
- #define DESTROY_LOOP(type,count) \
+ #define DESTROY_LOOP(type,count) do { \
for(i = 1; i <= count; ++i) \
{ \
notif = Get_Notif_Ent(type, i); \
if (!notif) { backtrace("Destroy_All_Notifications(): Missing notification entity!\n"); return; } \
Destroy_Notification_Entity(notif); \
- }
+ } \
+ } while(0)
// kill all networked notifications and centerprints
#ifdef SVQC
#endif
// kill all real notification entities
- DESTROY_LOOP(MSG_ANNCE, NOTIF_ANNCE_COUNT)
- DESTROY_LOOP(MSG_INFO, NOTIF_INFO_COUNT)
- DESTROY_LOOP(MSG_CENTER, NOTIF_CENTER_COUNT)
- DESTROY_LOOP(MSG_MULTI, NOTIF_MULTI_COUNT)
- DESTROY_LOOP(MSG_CHOICE, NOTIF_CHOICE_COUNT)
+ DESTROY_LOOP(MSG_ANNCE, NOTIF_ANNCE_COUNT);
+ DESTROY_LOOP(MSG_INFO, NOTIF_INFO_COUNT);
+ DESTROY_LOOP(MSG_CENTER, NOTIF_CENTER_COUNT);
+ DESTROY_LOOP(MSG_MULTI, NOTIF_MULTI_COUNT);
+ DESTROY_LOOP(MSG_CHOICE, NOTIF_CHOICE_COUNT);
#undef DESTROY_LOOP
}
// ======================
// Process Notif String
// ======================
- #define SET_NOTIF_STRING(string,stringname) \
+ #define SET_NOTIF_STRING(string,stringname) do { \
notif.nent_string = strzone(CCR( \
Process_Notif_Line( \
typeId, \
namestring, \
stringname \
)) \
- );
+ ); \
+ } while(0)
if(GENTLE)
{
- if(gentle != "") { SET_NOTIF_STRING(gentle, "GENTLE") }
- else if(normal != "") { SET_NOTIF_STRING(normal, "NORMAL") }
+ if(gentle != "") { SET_NOTIF_STRING(gentle, "GENTLE"); }
+ else if(normal != "") { SET_NOTIF_STRING(normal, "NORMAL"); }
}
- else if(normal != "") { SET_NOTIF_STRING(normal, "NORMAL") }
-
+ else if(normal != "") { SET_NOTIF_STRING(normal, "NORMAL"); }
#undef SET_NOTIF_STRING
// Check to make sure a string was chosen
for(sel_num = 0;(args != "");)
{
selected = car(args); args = cdr(args);
- NOTIF_HIT_MAX(NOTIF_MAX_ARGS, "Local_Notification_sprintf")
+ NOTIF_HIT_MAX(NOTIF_MAX_ARGS, "Local_Notification_sprintf");
switch(strtolower(selected))
{
#ifdef CSQC
for(sel_num = 0;(hudargs != "");)
{
selected = car(hudargs); hudargs = cdr(hudargs);
- NOTIF_HIT_MAX(NOTIF_MAX_HUDARGS, "Local_Notification_HUD_Notify_Push")
+ NOTIF_HIT_MAX(NOTIF_MAX_HUDARGS, "Local_Notification_HUD_Notify_Push");
switch(strtolower(selected))
{
#define ARG_CASE_ARG_CS_SV_HA(selected,result) case selected: { arg_slot[sel_num] = result; ++sel_num; break; }
for(sel_num = 0;(durcnt != "");)
{
selected = car(durcnt); durcnt = cdr(durcnt);
- NOTIF_HIT_MAX(NOTIF_MAX_DURCNT, "Local_Notification_centerprint_generic")
+ NOTIF_HIT_MAX(NOTIF_MAX_DURCNT, "Local_Notification_centerprint_generic");
switch(strtolower(selected))
{
#define ARG_CASE_ARG_CS_SV_HA(selected,result)
ARG_CASE(ARG_SV, "death_team", Team_ColoredFullName(f1)) \
ARG_CASE(ARG_CS, "death_team", Team_ColoredFullName(f1 - 1))
-#define NOTIF_HIT_MAX(count,funcname) if(sel_num == count) { backtrace(sprintf("%s: Hit maximum arguments!\n", funcname)); break; }
+#define NOTIF_HIT_MAX(count,funcname) do { \
+ if(sel_num == count) { backtrace(sprintf("%s: Hit maximum arguments!\n", funcname)); break; } \
+} while(0)
#define NOTIF_HIT_UNKNOWN(token,funcname) { backtrace(sprintf("%s: Hit unknown token in selected string! '%s'\n", funcname, selected)); break; }
#define KILL_SPREE_LIST \
i,
WEP_NAME(i),
(((get_weaponinfo(i)).spawnflags & WEP_FLAG_MUTATORBLOCKED) ? " (MUTATOR WEAPON)" : "")
- ))
- for(x = 0; x <= WEP_CONFIG_COUNT; ++x) { WEP_CONFIG_WRITETOFILE(wep_config_queue[x]) }
- WEP_CONFIG_WRITETOFILE("// }}}\n")
+ ));
+ for(x = 0; x <= WEP_CONFIG_COUNT; ++x) { WEP_CONFIG_WRITETOFILE(wep_config_queue[x]); }
+ WEP_CONFIG_WRITETOFILE("// }}}\n");
// step 5: debug info
print(sprintf("#%d: %s: %d settings...\n", i, WEP_NAME(i), WEP_CONFIG_COUNT));
wep_config_queue[WEP_CONFIG_COUNT] = a; \
++WEP_CONFIG_COUNT; }
-#define WEP_CONFIG_WRITETOFILE(a) { \
+#define WEP_CONFIG_WRITETOFILE(a) do { \
fputs(wep_config_file, a); \
- if(wep_config_alsoprint) { print(a); } }
+ if(wep_config_alsoprint) { print(a); } \
+} while(0)
#define WEP_CONFIG_WRITE_CVARS_NONE(wepname,name) \
{ WEP_CONFIG_QUEUE( \
arc_shotorigin[2] = shotorg_adjust_values(CL_Weapon_GetShotOrg(WEP_ARC), false, false, 3);
arc_shotorigin[3] = shotorg_adjust_values(CL_Weapon_GetShotOrg(WEP_ARC), false, false, 4);
}
- ARC_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ ARC_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- ARC_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ ARC_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_KILLMESSAGE:
precache_model("models/weapons/v_laser.md3");
precache_model("models/weapons/h_laser.iqm");
precache_sound("weapons/lasergun_fire.wav");
- BLASTER_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ BLASTER_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CONFIG:
{
- BLASTER_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ BLASTER_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
precache_sound("weapons/crylink_fire.wav");
precache_sound("weapons/crylink_fire2.wav");
precache_sound("weapons/crylink_linkjoin.wav");
- CRYLINK_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ CRYLINK_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- CRYLINK_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ CRYLINK_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
precache_sound("weapons/rocket_fire.wav");
precache_sound("weapons/rocket_mode.wav");
//}
- DEVASTATOR_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ DEVASTATOR_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_SETUP:
}
case WR_CONFIG:
{
- DEVASTATOR_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ DEVASTATOR_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RESETPLAYER:
precache_sound("weapons/electro_fire2.wav");
precache_sound("weapons/electro_impact.wav");
precache_sound("weapons/electro_impact_combo.wav");
- ELECTRO_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ ELECTRO_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- ELECTRO_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ ELECTRO_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RESETPLAYER:
precache_sound("weapons/fireball_fire.wav");
precache_sound("weapons/fireball_fire2.wav");
precache_sound("weapons/fireball_prefire2.wav");
- FIREBALL_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ FIREBALL_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_SETUP:
}
case WR_CONFIG:
{
- FIREBALL_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ FIREBALL_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RESETPLAYER:
precache_sound("weapons/hagar_fire.wav");
precache_sound("weapons/hagar_load.wav");
precache_sound("weapons/hagar_beep.wav");
- HAGAR_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ HAGAR_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_SETUP:
}
case WR_CONFIG:
{
- HAGAR_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ HAGAR_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RESETPLAYER:
precache_model("models/weapons/v_hlac.md3");
precache_model("models/weapons/h_hlac.iqm");
precache_sound("weapons/lasergun_fire.wav");
- HLAC_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ HLAC_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- HLAC_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ HLAC_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
precache_model ("models/weapons/v_ok_hmg.md3");
precache_model ("models/weapons/h_ok_hmg.iqm");
precache_sound ("weapons/uzi_fire.wav");
- HMG_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ HMG_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- HMG_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ HMG_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
precache_sound("weapons/hook_impact.wav"); // done by g_hook.qc
precache_sound("weapons/hook_fire.wav");
precache_sound("weapons/hookbomb_fire.wav");
- HOOK_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ HOOK_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_SETUP:
}
case WR_CONFIG:
{
- HOOK_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ HOOK_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RESETPLAYER:
precache_model("models/weapons/v_uzi.md3");
precache_model("models/weapons/h_uzi.iqm");
precache_sound("weapons/uzi_fire.wav");
- MACHINEGUN_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ MACHINEGUN_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- MACHINEGUN_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ MACHINEGUN_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
precache_sound("weapons/mine_fire.wav");
precache_sound("weapons/mine_stick.wav");
precache_sound("weapons/mine_trigger.wav");
- MINELAYER_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ MINELAYER_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- MINELAYER_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ MINELAYER_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RESETPLAYER:
precache_sound("weapons/grenade_bounce6.wav");
precache_sound("weapons/grenade_stick.wav");
precache_sound("weapons/grenade_fire.wav");
- MORTAR_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ MORTAR_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- MORTAR_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ MORTAR_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
}
case WR_CONFIG:
{
- PORTO_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ PORTO_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_THINK:
precache_sound("porto/explode.wav");
precache_sound("porto/fire.wav");
precache_sound("porto/unsupported.wav");
- PORTO_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ PORTO_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_SETUP:
precache_model("models/weapons/h_campingrifle.iqm");
precache_sound("weapons/campingrifle_fire.wav");
precache_sound("weapons/campingrifle_fire2.wav");
- RIFLE_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ RIFLE_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- RIFLE_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ RIFLE_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RESETPLAYER:
precache_model("models/weapons/v_ok_rl.md3");
precache_model("models/weapons/g_ok_rl.md3");
precache_sound ("weapons/rocket_fire.wav");
- RPC_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ RPC_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- RPC_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ RPC_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
precache_sound("weapons/tag_fire.wav");
precache_sound("weapons/flac_fire.wav");
precache_sound("weapons/seeker_fire.wav");
- SEEKER_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ SEEKER_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- SEEKER_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ SEEKER_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
precache_sound("misc/itempickup.wav");
precache_sound("weapons/lasergun_fire.wav");
precache_sound("weapons/shotgun_melee.wav");
- SHOCKWAVE_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ SHOCKWAVE_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- SHOCKWAVE_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ SHOCKWAVE_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_SUICIDEMESSAGE:
precache_sound("misc/itempickup.wav");
precache_sound("weapons/shotgun_fire.wav");
precache_sound("weapons/shotgun_melee.wav");
- SHOTGUN_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ SHOTGUN_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_SETUP:
}
case WR_CONFIG:
{
- SHOTGUN_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ SHOTGUN_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
precache_model("models/weapons/h_akordeon.iqm");
precache_model("models/weapons/v_kleinbottle.md3");
precache_model("models/weapons/h_kleinbottle.iqm");
- TUBA_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ TUBA_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_SETUP:
}
case WR_CONFIG:
{
- TUBA_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ TUBA_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_SUICIDEMESSAGE:
precache_sound("weapons/nexwhoosh2.wav");
precache_sound("weapons/nexwhoosh3.wav");
//W_Blaster(WR_INIT); // Samual: Is this really the proper thing to do? Didn't we already run this previously?
- VAPORIZER_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ VAPORIZER_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_SETUP:
}
case WR_CONFIG:
{
- VAPORIZER_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ VAPORIZER_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RESETPLAYER:
precache_sound("weapons/nexwhoosh1.wav");
precache_sound("weapons/nexwhoosh2.wav");
precache_sound("weapons/nexwhoosh3.wav");
- VORTEX_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP)
+ VORTEX_SETTINGS(WEP_SKIP_CVAR, WEP_SET_PROP);
return true;
}
case WR_CHECKAMMO1:
}
case WR_CONFIG:
{
- VORTEX_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS)
+ VORTEX_SETTINGS(WEP_CONFIG_WRITE_CVARS, WEP_CONFIG_WRITE_PROPS);
return true;
}
case WR_RELOAD:
#define BAN_COMMAND(name,function,description) \
{ if(strtolower(description) != "") { print(" ^2", name, "^7: ", description, "\n"); } }
- BAN_COMMANDS(0, 0, "")
+ BAN_COMMANDS(0, 0, "");
#undef BAN_COMMAND
return;
#define BAN_COMMAND(name,function,description) \
{ if(name == strtolower(argv(0))) { function; return true; } }
- BAN_COMMANDS(CMD_REQUEST_COMMAND, argc, command)
+ BAN_COMMANDS(CMD_REQUEST_COMMAND, argc, command);
#undef BAN_COMMAND
return false;
#define BAN_COMMAND(name,function,description) \
{ if(name == strtolower(argv(1))) { function; return true; } }
- BAN_COMMANDS(CMD_REQUEST_USAGE, argc, "")
+ BAN_COMMANDS(CMD_REQUEST_USAGE, argc, "");
#undef BAN_COMMAND
return false;
#define BAN_COMMAND(name,function,description) \
{ if(strtolower(description) != "") { CMD_Write_Alias("qc_cmd_sv", name, description); } }
- BAN_COMMANDS(0, 0, "")
+ BAN_COMMANDS(0, 0, "");
#undef BAN_COMMAND
return;
#define CLIENT_COMMAND(name,function,description) \
{ sprint(self, " ^2", name, "^7: ", description, "\n"); }
- CLIENT_COMMANDS(0, 0, "")
+ CLIENT_COMMANDS(0, 0, "");
#undef CLIENT_COMMAND
return;
#define CLIENT_COMMAND(name,function,description) \
{ if(name == strtolower(argv(0))) { function; return true; } }
- CLIENT_COMMANDS(CMD_REQUEST_COMMAND, argc, command)
+ CLIENT_COMMANDS(CMD_REQUEST_COMMAND, argc, command);
#undef CLIENT_COMMAND
return false;
#define CLIENT_COMMAND(name,function,description) \
{ if(name == strtolower(argv(1))) { function; return true; } }
- CLIENT_COMMANDS(CMD_REQUEST_USAGE, argc, "")
+ CLIENT_COMMANDS(CMD_REQUEST_USAGE, argc, "");
#undef CLIENT_COMMAND
return false;
#define CLIENT_COMMAND(name,function,description) \
{ CMD_Write_Alias("qc_cmd_cmd", name, description); }
- CLIENT_COMMANDS(0, 0, "")
+ CLIENT_COMMANDS(0, 0, "");
#undef CLIENT_COMMAND
return;
#define COMMON_COMMAND(name,function,description) \
{ print_to(caller, strcat(" ^2", name, "^7: ", description)); }
- COMMON_COMMANDS(0, caller, 0, "")
+ COMMON_COMMANDS(0, caller, 0, "");
#undef COMMON_COMMAND
return;
#define COMMON_COMMAND(name,function,description) \
{ if(name == strtolower(argv(0))) { function; return true; } }
- COMMON_COMMANDS(CMD_REQUEST_COMMAND, caller, argc, command)
+ COMMON_COMMANDS(CMD_REQUEST_COMMAND, caller, argc, command);
#undef COMMON_COMMAND
return false;
#define COMMON_COMMAND(name,function,description) \
{ if(name == strtolower(argv(1))) { function; return true; } }
- COMMON_COMMANDS(CMD_REQUEST_USAGE, caller, argc, "")
+ COMMON_COMMANDS(CMD_REQUEST_USAGE, caller, argc, "");
#undef COMMON_COMMAND
return false;
#define COMMON_COMMAND(name,function,description) \
{ CMD_Write_Alias("qc_cmd_svcmd", name, description); }
- COMMON_COMMANDS(0, world, 0, "")
+ COMMON_COMMANDS(0, world, 0, "");
#undef COMMON_COMMAND
return;
#define SERVER_COMMAND(name,function,description) \
{ print(" ^2", name, "^7: ", description, "\n"); }
- SERVER_COMMANDS(0, 0, "")
+ SERVER_COMMANDS(0, 0, "");
#undef SERVER_COMMAND
return;
#define SERVER_COMMAND(name,function,description) \
{ if(name == strtolower(argv(0))) { function; return true; } }
- SERVER_COMMANDS(CMD_REQUEST_COMMAND, argc, command)
+ SERVER_COMMANDS(CMD_REQUEST_COMMAND, argc, command);
#undef SERVER_COMMAND
return false;
#define SERVER_COMMAND(name,function,description) \
{ if(name == strtolower(argv(1))) { function; return true; } }
- SERVER_COMMANDS(CMD_REQUEST_USAGE, argc, "")
+ SERVER_COMMANDS(CMD_REQUEST_USAGE, argc, "");
#undef SERVER_COMMAND
return false;
#define SERVER_COMMAND(name,function,description) \
{ CMD_Write_Alias("qc_cmd_sv", name, description); }
- SERVER_COMMANDS(0, 0, "")
+ SERVER_COMMANDS(0, 0, "");
#undef SERVER_COMMAND
return;
#define VOTE_COMMAND(name,function,description,assignment) \
{ if(Votecommand_check_assignment(caller, assignment)) { print_to(caller, strcat(" ^2", name, "^7: ", description)); } }
- VOTE_COMMANDS(0, caller, 0, "")
+ VOTE_COMMANDS(0, caller, 0, "");
#undef VOTE_COMMAND
print_to(caller, strcat("\nUsage:^3 ", command_origin, " vote COMMAND...^7, where possible commands are listed above.\n"));
#define VOTE_COMMAND(name,function,description,assignment) \
{ if(Votecommand_check_assignment(caller, assignment)) { if(name == strtolower(argv(2))) { function; return; } } }
- VOTE_COMMANDS(CMD_REQUEST_USAGE, caller, argc, "")
+ VOTE_COMMANDS(CMD_REQUEST_USAGE, caller, argc, "");
#undef VOTE_COMMAND
}
#define VOTE_COMMAND(name,function,description,assignment) \
{ if(Votecommand_check_assignment(caller, assignment)) { if(name == strtolower(argv(1))) { function; return true; } } }
- VOTE_COMMANDS(CMD_REQUEST_COMMAND, caller, argc, vote_command)
+ VOTE_COMMANDS(CMD_REQUEST_COMMAND, caller, argc, vote_command);
#undef VOTE_COMMAND
return false;