Ah ok a little misinterpretion
first
if (("Target1".Equals(shortName) && active) && ("Target1_1".Equals(shortName) && active))
couldnt work there is only one shortName it could be Target1 or Target1_1 but never both.
So you can create a global bool variable.
Example
bool Target1triggered = false;
bool Target1_1triggered = false;
then in Ontrigger you can set
if ("Target1".Equals(shortName) && active)
{
Target1triggered = true;
}
if ("Target1_1".Equals(shortName) && active)
{
Target1_1triggered = true;
}
if (Target1triggered && Target1_1triggered)
{
// Your code
}
Or you check if the Trigger is enabled, normaly the trigger will be disabled (not the PassThru-Trigger) after activation.
if (GamePlay.gpGetTrigger("Trigger1").Enable == false && GamePlay.gpGetTrigger("Target1_1").Enable == false)
should became true
|