+#include "multi.qh"
// NOTE: also contains trigger_once at bottom
#ifdef SVQC
multi_wait(this); // waiting finished
}
else
- { // we can't just remove (this) here, because this is a touch function
- // called wheil C code is looping through area links...
+ { // we can't just delete(this) here, because this is a touch function
+ // called while C code is looping through area links...
settouch(this, func_null);
}
}
}
// if the trigger has pressed keys, check that the player is pressing those keys
- if(this.pressedkeys)
- if(IS_PLAYER(toucher)) // only for players
- if(!(toucher.pressedkeys & this.pressedkeys))
+ if(this.pressedkeys && IS_PLAYER(toucher)) // only for players
+ if(!(CS(toucher).pressedkeys & this.pressedkeys))
return;
EXACTTRIGGER_TOUCH(this, toucher);
if(this.spawnflags & DOOR_NOSPLASH)
if(!(DEATH_ISSPECIAL(deathtype)) && (deathtype & HITTYPE_SPLASH))
return;
+ if(this.team)
+ if(((this.spawnflags & 4) == 0) == (this.team != attacker.team))
+ return;
this.health = this.health - damage;
if (this.health <= 0)
{
EXACTTRIGGER_INIT;
this.team_saved = this.team;
+ IL_PUSH(g_saved_team, this);
if (this.health)
{
if (this.spawnflags & SPAWNFLAG_NOTOUCH)
objerror (this, "health and notouch don't make sense\n");
+ this.canteamdamage = true;
this.max_health = this.health;
this.event_damage = multi_eventdamage;
this.takedamage = DAMAGE_YES;