]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/common/mapobjects/trigger/gravity.qc
Use gender-neutral pronouns when referring to the player
[xonotic/xonotic-data.pk3dir.git] / qcsrc / common / mapobjects / trigger / gravity.qc
index 1ac0f8768d5d355b1a4b0d8d7cea8f97935c6cf5..0582e708cf047b06dde9b087179c5b4bf8318f7b 100644 (file)
@@ -15,7 +15,7 @@ void trigger_gravity_remove(entity own)
 }
 void trigger_gravity_check_think(entity this)
 {
-       // This spawns when a player enters the gravity zone and checks if he left.
+       // This spawns when a player enters the gravity zone and checks if they left.
        // Each frame, this.count is set to 2 by trigger_gravity_touch() and decreased by 1 here.
        // It the player has left the gravity trigger, this will be allowed to reach 0 and indicate that.
        if(this.count <= 0)
@@ -68,7 +68,7 @@ void trigger_gravity_touch(entity this, entity toucher)
                        else
                                return;
                }
-               toucher.trigger_gravity_check = spawn();
+               toucher.trigger_gravity_check = new_pure(trigger_gravity_checker);
                toucher.trigger_gravity_check.enemy = this;
                toucher.trigger_gravity_check.owner = toucher;
                toucher.trigger_gravity_check.gravity = toucher.gravity;
@@ -100,7 +100,7 @@ spawnfunc(trigger_gravity)
 
        this.active = ACTIVE_ACTIVE;
        this.setactive = generic_setactive;
-       IFTARGETED
+       if(this.targetname && this.targetname != "")
        {
                // legacy use
                this.use = trigger_gravity_use;