From cecae3473b79a457a2bd385938eea2f7e0037dee Mon Sep 17 00:00:00 2001 From: TimePath Date: Wed, 30 Dec 2015 22:34:37 +1100 Subject: [PATCH] Add missing include guards --- qcsrc/client/hud/all.qh | 2 ++ qcsrc/common/items/item/powerup.qh | 6 ++---- qcsrc/common/minigames/minigame/all.qh | 2 ++ qcsrc/common/state.qh | 2 ++ qcsrc/common/triggers/func/door.qh | 2 ++ qcsrc/common/triggers/func/ladder.qh | 2 ++ qcsrc/common/triggers/func/train.qh | 2 ++ qcsrc/common/triggers/trigger/keylock.qh | 2 ++ qcsrc/common/triggers/trigger/multi.qh | 2 ++ qcsrc/menu/gamesettings.qh | 5 ++--- 10 files changed, 20 insertions(+), 7 deletions(-) diff --git a/qcsrc/client/hud/all.qh b/qcsrc/client/hud/all.qh index 4f8cee5c84..2e458e6dd5 100644 --- a/qcsrc/client/hud/all.qh +++ b/qcsrc/client/hud/all.qh @@ -1,2 +1,4 @@ +#pragma once + #include "hud.qh" #include "hud_config.qh" diff --git a/qcsrc/common/items/item/powerup.qh b/qcsrc/common/items/item/powerup.qh index fd477354f1..0a3d907288 100644 --- a/qcsrc/common/items/item/powerup.qh +++ b/qcsrc/common/items/item/powerup.qh @@ -1,10 +1,10 @@ +#pragma once + #ifdef SVQC // For FL_POWERUP #include #endif -#ifndef POWERUP_H -#define POWERUP_H #include "pickup.qh" CLASS(Powerup, Pickup) #ifdef SVQC @@ -16,5 +16,3 @@ CLASS(Powerup, Pickup) ATTRIB(Powerup, m_respawntimejitter, float(), GET(g_pickup_respawntimejitter_powerup)) #endif ENDCLASS(Powerup) - -#endif diff --git a/qcsrc/common/minigames/minigame/all.qh b/qcsrc/common/minigames/minigame/all.qh index f552db98b5..5567b25681 100644 --- a/qcsrc/common/minigames/minigame/all.qh +++ b/qcsrc/common/minigames/minigame/all.qh @@ -1,3 +1,5 @@ +#pragma once + #if defined(SVQC) #include "../sv_minigames.qh" #elif defined(CSQC) diff --git a/qcsrc/common/state.qh b/qcsrc/common/state.qh index 177935445d..e2ba5f3858 100644 --- a/qcsrc/common/state.qh +++ b/qcsrc/common/state.qh @@ -1,3 +1,5 @@ +#pragma once + /** * Purpose: common player state, usable on client and server * Client: singleton representing the viewed player diff --git a/qcsrc/common/triggers/func/door.qh b/qcsrc/common/triggers/func/door.qh index f7ed28c5bb..84a9d6aa23 100644 --- a/qcsrc/common/triggers/func/door.qh +++ b/qcsrc/common/triggers/func/door.qh @@ -1,3 +1,5 @@ +#pragma once + // door constants const int DOOR_START_OPEN = 1; const int DOOR_DONT_LINK = 4; diff --git a/qcsrc/common/triggers/func/ladder.qh b/qcsrc/common/triggers/func/ladder.qh index 774e7cf408..26cbbda032 100644 --- a/qcsrc/common/triggers/func/ladder.qh +++ b/qcsrc/common/triggers/func/ladder.qh @@ -1,2 +1,4 @@ +#pragma once + .float ladder_time; .entity ladder_entity; diff --git a/qcsrc/common/triggers/func/train.qh b/qcsrc/common/triggers/func/train.qh index d42d8a8a0c..8b6f7c02da 100644 --- a/qcsrc/common/triggers/func/train.qh +++ b/qcsrc/common/triggers/func/train.qh @@ -1,3 +1,5 @@ +#pragma once + #ifdef CSQC .float dmgtime; #endif diff --git a/qcsrc/common/triggers/trigger/keylock.qh b/qcsrc/common/triggers/trigger/keylock.qh index a59cb3f695..756d3b25a5 100644 --- a/qcsrc/common/triggers/trigger/keylock.qh +++ b/qcsrc/common/triggers/trigger/keylock.qh @@ -1,3 +1,5 @@ +#pragma once + #ifdef CSQC bool item_keys_usekey(entity l, entity p) { diff --git a/qcsrc/common/triggers/trigger/multi.qh b/qcsrc/common/triggers/trigger/multi.qh index 32a3c3131e..1a67dfd358 100644 --- a/qcsrc/common/triggers/trigger/multi.qh +++ b/qcsrc/common/triggers/trigger/multi.qh @@ -1,3 +1,5 @@ +#pragma once + #ifdef SVQC void multi_trigger(); void multi_reset(entity this); diff --git a/qcsrc/menu/gamesettings.qh b/qcsrc/menu/gamesettings.qh index 0db9f77f2e..868ac0fe31 100644 --- a/qcsrc/menu/gamesettings.qh +++ b/qcsrc/menu/gamesettings.qh @@ -1,6 +1,6 @@ +#pragma once + #ifdef MENUQC -#ifndef GAMESETTINGS_H -#define GAMESETTINGS_H #include "xonotic/tab.qc" @@ -12,4 +12,3 @@ REGISTER_REGISTRY(Settings) REGISTER(Settings, MENU, id, m_id, NEW(Lazy, LAZY(id))) #endif -#endif -- 2.39.2