]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/commitdiff
fix more issues... still doesn't compile
authorRudolf Polzer <divVerent@xonotic.org>
Wed, 23 Feb 2011 19:55:13 +0000 (20:55 +0100)
committerRudolf Polzer <divVerent@xonotic.org>
Wed, 23 Feb 2011 19:55:13 +0000 (20:55 +0100)
qcsrc/server/mutators/base.qc
qcsrc/server/mutators/base.qh

index 8c0c9439cdb3c7a2a06f6b46178817aa02f2d486..6f42ff8e908514443eaaefa83fdf8a7ebcba09b1 100644 (file)
@@ -88,8 +88,8 @@ float CallbackChain_Call(entity cb)
 }
 
 #define MAX_MUTATORS 8
-float(float) mutators[MAX_MUTATORS];
-float Mutator_Add(float(float) func)
+var mutatorfunc_t mutators[MAX_MUTATORS];
+float Mutator_Add(mutatorfunc_t func)
 {
        float i, j;
        j = -1;
@@ -125,7 +125,7 @@ void Mutator_Remove(float(float) func)
        if(i >= MAX_MUTATORS)
        {
                backtrace("WARNING: removing not-added mutator\n");
-               return 0;
+               return;
        }
        mutators[i] = func_null;
 
index aa581228bd474fc32a12bc885291d0ae9a0c9775..f150d1ea995597f80afdb1c2c248210e2d47bf37 100644 (file)
@@ -16,8 +16,9 @@ float CallbackChain_Call(entity cb);
 
 #define MUTATOR_REMOVING 0
 #define MUTATOR_ADDING 1
-float Mutator_Add(float(float) func);
-void Mutator_Remove(float(float) func); // calls error() on fail
+typedef float(float) mutatorfunc_t;
+float Mutator_Add(mutatorfunc_t func);
+void Mutator_Remove(mutatorfunc_t func); // calls error() on fail
 
 #define MUTATOR_ADD(name) Mutator_Add(MUTATOR_##name)
 #define MUTATOR_REMOVE(name) Mutator_Remove(MUTATOR_##name)