]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/server/command/common.qc
Merge branch 'terencehill/hud_cleanups' into 'master'
[xonotic/xonotic-data.pk3dir.git] / qcsrc / server / command / common.qc
index ee832bcc8529d3ec9ef3e104a96209c39fc588c4..8d804587232bb57bc1d03f6423969662a57586b8 100644 (file)
@@ -1,10 +1,11 @@
 #include "../../common/command/command.qh"
 #include "common.qh"
-#include "../_all.qh"
 
 #include "../scores.qh"
 
+#include "../../common/monsters/all.qh"
 #include "../../common/notifications.qh"
+#include "../../lib/warpzone/common.qh"
 
 
 // ====================================================
@@ -178,7 +179,7 @@ void print_to(entity to, string input)
 
 // used by CommonCommand_timeout() and CommonCommand_timein() to handle game pausing and messaging and such.
 void timeout_handler_reset()
-{
+{SELFPARAM();
        timeout_caller = world;
        timeout_time = 0;
        timeout_leadtime = 0;
@@ -187,7 +188,7 @@ void timeout_handler_reset()
 }
 
 void timeout_handler_think()
-{
+{SELFPARAM();
        entity tmp_player;
 
        switch(timeout_status)
@@ -312,7 +313,7 @@ void CommonCommand_cvar_purechanges(float request, entity caller)
 }
 
 void CommonCommand_editmob(int request, entity caller, int argc)
-{
+{SELFPARAM();
        switch(request)
        {
                case CMD_REQUEST_COMMAND:
@@ -392,7 +393,7 @@ void CommonCommand_editmob(int request, entity caller, int argc)
                                        if(mon.realowner != caller && autocvar_g_monsters_edit < 2) { print_to(caller, "This monster does not belong to you"); return; }
                                        if(!is_visible) { print_to(caller, "You must look at your monster to edit it"); return; }
 
-                                       Damage (mon, world, world, mon.health + mon.max_health + 200, DEATH_KILL, mon.origin, '0 0 0');
+                                       Damage (mon, world, world, mon.health + mon.max_health + 200, DEATH_KILL.m_id, mon.origin, '0 0 0');
                                        print_to(caller, strcat("Your pet '", mon.monster_name, "' has been brutally mutilated"));
                                        return;
                                }
@@ -424,7 +425,7 @@ void CommonCommand_editmob(int request, entity caller, int argc)
                                case "butcher":
                                {
                                        if(caller) { print_to(caller, "This command is not available to players"); return; }
-                                       if(g_invasion) { print_to(caller, "This command does not work during an invasion!"); return; }
+                                       if(MUTATOR_CALLHOOK(AllowMobButcher)) { LOG_INFO(ret_string, "\n"); return; }
 
                                        int tmp_remcount = 0;
                                        entity tmp_entity;