Quote:
Originally Posted by GambiT
ok, heres a task. this is for rock2.
i have 2 triggers(for each team), one for wo entry(call it "wolight"[red/bluewolight]) and one for yard entry spotlight(call it "yardlight"[red/blueyardlight]). heres the thing, when a "disguised" enemy spy goes through the trigger i do NOT want it to light up, but for all other enemies i do.
|
From base_teamplay... involving respawn door triggers:
Code:
function respawndoor:allowed( allowed_entity )
if IsPlayer( allowed_entity ) then
local player = CastToPlayer( allowed_entity )
if player:GetTeamId() == self.team then
return EVENT_ALLOWED
end
if self.allowdisguised then
if player:IsDisguised() and player:GetDisguisedTeam() == self.team then
return EVENT_ALLOWED
end
end
end
return EVENT_DISALLOWED
end
So maybe... trigger_ff_script that with an ontrigger callback that looks for enemies (and also do a check for disguised spies that match the allied team) and then have it fail same as if regular allies touch it