From 4fad2ac3d9b6d7c8ad54fe195914da4de225b16b Mon Sep 17 00:00:00 2001 From: Walter Julius Hennecke Date: Sun, 30 Dec 2012 19:38:00 +0100 Subject: [PATCH] Linux fixes (excludes Makefile which still has to be modified) --- Shared/qcommon/quaternion.h | 2 +- dlls/game/UseData.h | 2 +- dlls/game/archive.h | 8 ++++++++ dlls/game/beam.h | 5 ++++- dlls/game/container.h | 1 + dlls/game/listener.h | 17 +++++++---------- 6 files changed, 22 insertions(+), 13 deletions(-) diff --git a/Shared/qcommon/quaternion.h b/Shared/qcommon/quaternion.h index 774b33d..88f141e 100644 --- a/Shared/qcommon/quaternion.h +++ b/Shared/qcommon/quaternion.h @@ -18,7 +18,7 @@ #define _QUATERNION_H_ #include -#include "vector.h" +#include //#include "Matrix.h" #define UNUSED_ARG (void) diff --git a/dlls/game/UseData.h b/dlls/game/UseData.h index 6930f31..88ffec5 100644 --- a/dlls/game/UseData.h +++ b/dlls/game/UseData.h @@ -55,7 +55,7 @@ class UseData : public Class int _useCount; public: - UseData::UseData() + UseData() :_useAnim(""), _useType(""), _useThread(""), diff --git a/dlls/game/archive.h b/dlls/game/archive.h index a136a65..2c95ae4 100644 --- a/dlls/game/archive.h +++ b/dlls/game/archive.h @@ -182,6 +182,7 @@ inline qboolean Archiver::NoErrors return ( !fileerror ); } +template <> inline void Container::Archive ( Archiver &arc @@ -206,6 +207,7 @@ inline void Container::Archive } } +template <> inline void Container::Archive ( Archiver &arc @@ -230,6 +232,7 @@ inline void Container::Archive } } +template <> inline void Container::Archive ( Archiver &arc @@ -254,6 +257,7 @@ inline void Container::Archive } } +template <> inline void Container::Archive ( Archiver &arc @@ -296,6 +300,7 @@ inline void Container::Archive // Returns: None // //=============================================================== +template <> inline void Container::Archive ( Archiver &arc @@ -327,6 +332,7 @@ inline void Container::Archive // Returns: None // //=============================================================== +template <> inline void Container::Archive ( Archiver &arc @@ -388,6 +394,7 @@ inline void Container< SafePtr >::Archive // Returns: None // //=============================================================== +template <> inline void Container::Archive ( Archiver &arc @@ -406,6 +413,7 @@ inline void Container::Archive } } +template <> inline void Container::Archive ( Archiver &arc diff --git a/dlls/game/beam.h b/dlls/game/beam.h index 99d7bb2..6553c5d 100644 --- a/dlls/game/beam.h +++ b/dlls/game/beam.h @@ -40,6 +40,9 @@ extern Event EV_FuncBeam_ToggleDelay; extern Event EV_FuncBeam_FindEndpoint; extern Event EV_FuncBeam_EndAlpha; +class FuncBeam; +FuncBeam *CreateBeam( const char *model, const char *shader, const Vector &start, const Vector &end, int numsegments = 4, float scale = 1.0f, float life = 1.0f, float damage = 0.0f, Entity *origin_target=NULL ); + class FuncBeam : public ScriptSlave { protected: @@ -90,7 +93,7 @@ class FuncBeam : public ScriptSlave virtual void setAngles( const Vector &ang ); virtual void Archive( Archiver &arc ); - friend FuncBeam *CreateBeam( const char *model, const char *shader, const Vector &start, const Vector &end, int numsegments = 4, float scale = 1.0f, float life = 1.0f, float damage = 0.0f, Entity *origin_target=NULL ); + friend FuncBeam *CreateBeam( const char *model, const char *shader, const Vector &start, const Vector &end, int numsegments, float scale, float life, float damage, Entity *origin_target); }; inline void FuncBeam::Archive diff --git a/dlls/game/container.h b/dlls/game/container.h index 8229343..e699e8f 100644 --- a/dlls/game/container.h +++ b/dlls/game/container.h @@ -35,6 +35,7 @@ // #include "g_local.h" +extern game_import_t gi; #define CONTAINER_Error gi.Error #define CONTAINER_DPrintf gi.DPrintf #define CONTAINER_WDPrintf gi.WDPrintf diff --git a/dlls/game/listener.h b/dlls/game/listener.h index 778e423..4e74c21 100644 --- a/dlls/game/listener.h +++ b/dlls/game/listener.h @@ -338,16 +338,13 @@ inline qboolean EventArgDef::isOptional return optional; } -#ifndef GAME_DLL -extern "C" - { - // interface functions - void L_ProcessPendingEvents( void ); - void L_ClearEventList( void ); - void L_InitEvents( void ); - void L_ShutdownEvents( void ); - } -#endif +// interface functions +void L_ProcessPendingEvents( void ); +void L_ClearEventList( void ); +void L_InitEvents( void ); +void L_ShutdownEvents( void ); +void L_ArchiveEvents(Archiver& arc); +void L_UnarchiveEvents(Archiver& arc); class Listener;