]> git.rm.cloudns.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
Remove the CSQC model hook macros (we use a parameter in them now that may cause...
authorMario <mario@smbclan.net>
Wed, 6 Jan 2016 05:11:35 +0000 (15:11 +1000)
committerMario <mario@smbclan.net>
Wed, 6 Jan 2016 05:11:35 +0000 (15:11 +1000)
qcsrc/common/csqcmodel_settings.qh
qcsrc/lib/csqcmodel/cl_model.qc
qcsrc/lib/csqcmodel/settings.qh

index 916fd88bcb7290e399a8cfd96178e9b17859802f..da2661b9c549e5d2b1f845c1cac73b2d901fdc62 100644 (file)
 // TODO get rid of colormod/glowmod here, find good solution for vortex charge glowmod hack; also get rid of some useless properties on non-players that only exist for CopyBody
 
 // add hook function calls here
-#define CSQCMODEL_HOOK_PREUPDATE \
-       CSQCModel_Hook_PreUpdate(this, isnew, isplayer, islocalplayer);
-#define CSQCMODEL_HOOK_POSTUPDATE \
-       CSQCModel_Hook_PostUpdate(this, isnew, isplayer, islocalplayer);
-#define CSQCMODEL_HOOK_PREDRAW \
-       CSQCModel_Hook_PreDraw(this, isplayer);
 #define CSQCPLAYER_HOOK_POSTCAMERASETUP() \
        CSQCPlayer_SetViewLocation()
 
index 53b58e6297be9dc07e6d6cfd72c8e2cbd5799d45..614e0d03702ede92311647d8e5b1983b42505a38 100644 (file)
@@ -192,7 +192,7 @@ void CSQCModel_Draw(entity this)
 
        CSQCModel_InterpolateAnimation_Do(this);
 
-       { CSQCMODEL_HOOK_PREDRAW }
+       CSQCModel_Hook_PreDraw(this, isplayer);
 
        // inherit draw flags easily
        entity root = this;
@@ -234,7 +234,7 @@ NET_HANDLE(ENT_CLIENT_MODEL, bool isnew)
        this.iflags |= IFLAG_ANGLES; // interpolate angles too
        this.iflags |= IFLAG_VELOCITY | IFLAG_AUTOVELOCITY; // let's calculate velocity automatically
 
-       { CSQCMODEL_HOOK_PREUPDATE }
+       CSQCModel_Hook_PreUpdate(this, isnew, isplayer, islocalplayer);
 
        CSQCPlayer_PreUpdate(this);
        InterpolateOrigin_Undo(this);
@@ -271,7 +271,7 @@ NET_HANDLE(ENT_CLIENT_MODEL, bool isnew)
        InterpolateOrigin_Note(this);
        CSQCPlayer_PostUpdate(this);
 
-       { CSQCMODEL_HOOK_POSTUPDATE }
+       CSQCModel_Hook_PostUpdate(this, isnew, isplayer, islocalplayer);
 
 #ifdef CSQCMODEL_SUPPORT_GETTAGINFO_BEFORE_DRAW
        InterpolateOrigin_Do(this);
index b365d2626e2d39a633eb66e68fc640048d1cd160..85b8a4fcbb80580059728230af0915e0096569b5 100644 (file)
@@ -12,9 +12,6 @@
        /* CSQCMODEL_PROPERTY(2, float, ReadInt24_t, WriteInt24_t, effects) */
 
 // add hook function calls here
-#define CSQCMODEL_HOOK_PREUPDATE
-#define CSQCMODEL_HOOK_POSTUPDATE
-#define CSQCMODEL_HOOK_PREDRAW
 #define CSQCPLAYER_HOOK_POSTCAMERASETUP
 
 // force updates of player entities this frequently (per second) even if unchanged