Impulses: migration pathway
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / minigames / sv_minigames.qc
index f69fc15b548c39ef99759700247db76dfdfedd5f..672f7f0bdff3b6720263fb3e0360f7ade90732c9 100644 (file)
@@ -290,12 +290,13 @@ entity minigame_find_player(entity client)
        return world;
 }
 
-bool MinigameImpulse(int imp)
-{SELFPARAM();
-       entity e = minigame_find_player(self);
-       if ( imp && self.active_minigame && e )
+bool MinigameImpulse(entity this, int imp)
+{
+       if (!this.active_minigame) return false;
+       entity e = minigame_find_player(this);
+       if ( imp && this.active_minigame && e )
        {
-               return self.active_minigame.minigame_event(self.active_minigame,"impulse",e,imp);
+               return this.active_minigame.minigame_event(this.active_minigame,"impulse",e,imp);
        }
        return false;
 }