]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/command/cmd.qc
Merge branch 'master' into Mario/vehicles
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / command / cmd.qc
index eec507f07e71033de427af4001a1fef4385721f6..8672c3a292ac324fcf1f81c03a150a3e58149099 100644 (file)
@@ -16,7 +16,7 @@
 #include "../mutators/mutators_include.qh"
 
 #ifdef SVQC
-       #include "../vehicles/vehicle.qh"
+       #include "../../common/vehicles/sv_vehicles.qh"
 #endif
 
 #include "../../common/constants.qh"
@@ -232,7 +232,7 @@ void ClientCommand_mobedit(float request, float argc)
                                WarpZone_TraceLine(self.origin + self.view_ofs, self.origin + self.view_ofs + v_forward * 100, MOVE_NORMAL, self);
 
                                if(!autocvar_g_monsters_edit) { sprint(self, "Monster property editing is not enabled.\n"); return; }
-                               if(trace_ent.flags & FL_MONSTER)
+                               if(IS_MONSTER(trace_ent))
                                {
                                        if(trace_ent.realowner != self) { sprint(self, "That monster does not belong to you.\n"); return; }
                                        switch(argv(1))
@@ -273,7 +273,7 @@ void ClientCommand_mobkill(float request)
                        makevectors(self.v_angle);
                        WarpZone_TraceLine(self.origin + self.view_ofs, self.origin + self.view_ofs + v_forward * 100, MOVE_NORMAL, self);
 
-                       if(trace_ent.flags & FL_MONSTER)
+                       if(IS_MONSTER(trace_ent))
                        {
                                if(trace_ent.realowner != self)
                                {
@@ -888,11 +888,6 @@ void SV_ParseClientCommand(string command)
 
        float argc = tokenize_console(command);
 
-       // for the mutator hook system
-       cmd_name = strtolower(argv(0));
-       cmd_argc = argc;
-       cmd_string = command;
-
        // Guide for working with argc arguments by example:
        // argc:   1    - 2      - 3     - 4
        // argv:   0    - 1      - 2     - 3
@@ -941,7 +936,7 @@ void SV_ParseClientCommand(string command)
                        return;
                }
        }
-       else if(MUTATOR_CALLHOOK(SV_ParseClientCommand))
+       else if(MUTATOR_CALLHOOK(SV_ParseClientCommand, strtolower(argv(0)), argc, command))
        {
                return; // handled by a mutator
        }