From 22f5546e0106c82601b8e92281cd34ec9d864423 Mon Sep 17 00:00:00 2001 From: TimePath Date: Sat, 5 Aug 2017 17:14:46 +1000 Subject: [PATCH] Lint --- qcsrc/common/minigames/minigame/bd.qc | 4 ++-- qcsrc/common/monsters/_mod.qh | 3 +++ qcsrc/common/monsters/sv_spawn.qc | 2 +- qcsrc/common/monsters/sv_spawner.qc | 1 + qcsrc/common/monsters/sv_spawner.qh | 1 + qcsrc/common/mutators/mutator/walljump/walljump.qc | 2 +- qcsrc/common/t_items.qc | 2 +- qcsrc/common/triggers/target/_mod.qh | 1 + qcsrc/common/triggers/target/kill.qc | 1 + qcsrc/common/triggers/target/kill.qh | 1 + qcsrc/common/turrets/sv_turrets.qc | 2 +- qcsrc/lib/warpzone/server.qc | 2 +- qcsrc/server/bot/default/havocbot/havocbot.qc | 2 +- qcsrc/server/client.qh | 2 +- 14 files changed, 17 insertions(+), 9 deletions(-) create mode 100644 qcsrc/common/monsters/sv_spawner.qh create mode 100644 qcsrc/common/triggers/target/kill.qh diff --git a/qcsrc/common/minigames/minigame/bd.qc b/qcsrc/common/minigames/minigame/bd.qc index 904b7772e..cda2e5d26 100644 --- a/qcsrc/common/minigames/minigame/bd.qc +++ b/qcsrc/common/minigames/minigame/bd.qc @@ -1020,7 +1020,7 @@ void bd_hud_board(vector pos, vector mySize) minigame_drawpic_centered( tile_pos, minigame_texture(thepiece), tile_size, '1 1 1', panel_fg_alpha, DRAWFLAG_NORMAL ); - } + } } else if ( e.classname == "minigame_board_piece" ) { @@ -1058,7 +1058,7 @@ void bd_hud_board(vector pos, vector mySize) default: case BD_DIR_DN: theang = M_PI; break; case BD_DIR_LF: theang = M_PI * 3 / 2; break; - case BD_DIR_RT: theang = M_PI / 2; break; + case BD_DIR_RT: theang = M_PI / 2; break; } drawrotpic(tile_pos, theang, minigame_texture("bd/dozer"), diff --git a/qcsrc/common/monsters/_mod.qh b/qcsrc/common/monsters/_mod.qh index 55204bd1a..7f726d640 100644 --- a/qcsrc/common/monsters/_mod.qh +++ b/qcsrc/common/monsters/_mod.qh @@ -6,5 +6,8 @@ #ifdef SVQC #include #endif +#ifdef SVQC + #include +#endif #include diff --git a/qcsrc/common/monsters/sv_spawn.qc b/qcsrc/common/monsters/sv_spawn.qc index 884fb3dea..4bbe2ce3d 100644 --- a/qcsrc/common/monsters/sv_spawn.qc +++ b/qcsrc/common/monsters/sv_spawn.qc @@ -19,7 +19,7 @@ entity spawnmonster (entity e, string monster, int monster_id, entity spawnedby, if(monster == "random") { - RandomSelection_Init(); + RandomSelection_Init(); FOREACH(Monsters, it != MON_Null && !(it.spawnflags & MONSTER_TYPE_PASSIVE) && !(it.spawnflags & MON_FLAG_HIDDEN), { RandomSelection_AddEnt(it, 1, 1); diff --git a/qcsrc/common/monsters/sv_spawner.qc b/qcsrc/common/monsters/sv_spawner.qc index 0b34d13e6..d3f4ee740 100644 --- a/qcsrc/common/monsters/sv_spawner.qc +++ b/qcsrc/common/monsters/sv_spawner.qc @@ -1,3 +1,4 @@ +#include "sv_spawner.qh" #include "sv_spawn.qh" void spawner_use(entity this, entity actor, entity trigger) diff --git a/qcsrc/common/monsters/sv_spawner.qh b/qcsrc/common/monsters/sv_spawner.qh new file mode 100644 index 000000000..6f70f09be --- /dev/null +++ b/qcsrc/common/monsters/sv_spawner.qh @@ -0,0 +1 @@ +#pragma once diff --git a/qcsrc/common/mutators/mutator/walljump/walljump.qc b/qcsrc/common/mutators/mutator/walljump/walljump.qc index 95a52185b..b0d95ea29 100644 --- a/qcsrc/common/mutators/mutator/walljump/walljump.qc +++ b/qcsrc/common/mutators/mutator/walljump/walljump.qc @@ -44,7 +44,7 @@ MUTATOR_HOOKFUNCTION(walljump, PlayerJump) if(!IS_DEAD(player)) { vector plane_normal = PlayerTouchWall(player); - + if(plane_normal != '0 0 0') { float wj_force = PHYS_WALLJUMP_FORCE(player); diff --git a/qcsrc/common/t_items.qc b/qcsrc/common/t_items.qc index 1e5f8284c..e674eff42 100644 --- a/qcsrc/common/t_items.qc +++ b/qcsrc/common/t_items.qc @@ -1373,7 +1373,7 @@ spawnfunc(item_rockets) spawnfunc(item_bullets) { - if(!weaponswapping && autocvar_sv_q3acompat_machineshotgunswap && + if(!weaponswapping && autocvar_sv_q3acompat_machineshotgunswap && (this.classname != "droppedweapon")) { weaponswapping = true; diff --git a/qcsrc/common/triggers/target/_mod.qh b/qcsrc/common/triggers/target/_mod.qh index 6b06b75f1..c59ee7976 100644 --- a/qcsrc/common/triggers/target/_mod.qh +++ b/qcsrc/common/triggers/target/_mod.qh @@ -1,6 +1,7 @@ // generated file; do not modify #include #include +#include #include #include #include diff --git a/qcsrc/common/triggers/target/kill.qc b/qcsrc/common/triggers/target/kill.qc index a086bb3c8..a821ac139 100644 --- a/qcsrc/common/triggers/target/kill.qc +++ b/qcsrc/common/triggers/target/kill.qc @@ -1,3 +1,4 @@ +#include "kill.qh" #include "location.qh" #ifdef SVQC diff --git a/qcsrc/common/triggers/target/kill.qh b/qcsrc/common/triggers/target/kill.qh new file mode 100644 index 000000000..6f70f09be --- /dev/null +++ b/qcsrc/common/triggers/target/kill.qh @@ -0,0 +1 @@ +#pragma once diff --git a/qcsrc/common/turrets/sv_turrets.qc b/qcsrc/common/turrets/sv_turrets.qc index b9250f0a8..cb69bf0ff 100644 --- a/qcsrc/common/turrets/sv_turrets.qc +++ b/qcsrc/common/turrets/sv_turrets.qc @@ -1254,7 +1254,7 @@ void turret_findtarget(entity this) setthink(e, turrets_manager_think); e.nextthink = time + 2; } - + entity targ = find(NULL, targetname, this.target); if(targ.classname == "turret_checkpoint") return; // turrets don't defend checkpoints? diff --git a/qcsrc/lib/warpzone/server.qc b/qcsrc/lib/warpzone/server.qc index 40c317a69..fa2478967 100644 --- a/qcsrc/lib/warpzone/server.qc +++ b/qcsrc/lib/warpzone/server.qc @@ -811,7 +811,7 @@ void WarpZone_StartFrame() WarpZone_StoreProjectileData(it); }); } - + FOREACH_CLIENT(true, { diff --git a/qcsrc/server/bot/default/havocbot/havocbot.qc b/qcsrc/server/bot/default/havocbot/havocbot.qc index cede62366..24d960284 100644 --- a/qcsrc/server/bot/default/havocbot/havocbot.qc +++ b/qcsrc/server/bot/default/havocbot/havocbot.qc @@ -363,7 +363,7 @@ void havocbot_bunnyhop(entity this, vector dir) if(checkdistance) { this.aistatus &= ~AI_STATUS_RUNNING; - // increase stop distance in case the goal is on a slope or a lower platform + // increase stop distance in case the goal is on a slope or a lower platform if(bunnyhopdistance > autocvar_bot_ai_bunnyhop_stopdistance + (this.origin.z - gco.z)) PHYS_INPUT_BUTTON_JUMP(this) = true; } diff --git a/qcsrc/server/client.qh b/qcsrc/server/client.qh index 8e8c8d71b..ee00c60ca 100644 --- a/qcsrc/server/client.qh +++ b/qcsrc/server/client.qh @@ -148,7 +148,7 @@ CLASS(Spectator, Client) ENDCLASS(Spectator) CLASS(Player, Client) - + // custom ATTRIB(Player, dual_weapons, vector, this.dual_weapons); // TODO: actually WepSet! -- 2.39.2