deathsai 0 Posted April 19, 2004 Ok, I have an idea for something, but I need to know this to make my life easier: Is there a way to make a trigger that is side specific instead of the unit name? For example, if I wanted all units on the WEST side to =setcaptive TRUE when they are in a trigger, so that if ANY West unit goes into the trigger area he is TRUE on setcaptive. Share this post Link to post Share on other sites
korax 4 Posted April 19, 2004 Create a trigger, set it to west present and repeatedly, and in the activation field put<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">"_x setcaptive true" Foreach Thislist Share this post Link to post Share on other sites
j-man 0 Posted April 19, 2004 create a trigger that covers the area that you want. Then make the trigger activated by WEST PRESENTand is activated repeatedly. Put <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">{_x setcaptive true} foreach thislist in the "ON ACTIVATION" field. Now, any soldier who is on the west side and enters the trigger, will be setcaptive = true, Share this post Link to post Share on other sites
j-man 0 Posted April 19, 2004 Damn, posted just a bit too late I'll get you next time Korax Share this post Link to post Share on other sites
deathsai 0 Posted April 19, 2004 Ah, thanks guys! Another question: If the unit that now has setcaptive= true, will he stay TRUE even if he leaves the trigger area? Will I have to create another trigger which has the exact same thing, except have it as setcaptive=FALSE? Share this post Link to post Share on other sites
j-man 0 Posted April 19, 2004 yes, the guy will stay a catpive until you use setcaptive false on him. Share this post Link to post Share on other sites
deathsai 0 Posted April 19, 2004 Ah, damn. Oh well, I guess I can make some grids on my beaches. The thing I am doing is making an Omaha beach mission. When you run behind a hedgehog, you get setcaptive=true, to simulate cover. When you leave from behind the hedgehog, you get setcaptive=false, to simulate...Omaha beach Share this post Link to post Share on other sites
MrZig 0 Posted April 19, 2004 on deactivation: <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">"_x setcaptive false" Foreach Thislist Share this post Link to post Share on other sites
Chris Death 0 Posted April 19, 2004 hmm - there's only one little thing, noone seems having thought about here: A trigger with the suggested settings: activation: west - present - repeatedly onActivation: "_x setcaptive true" forEach thislist ...should normally do, what it looks like -> it set's each west guy inside it's area to captive state - works fine for the first time - - but: it will only work a second time (or more), if the trigger gets deactivated again. This means: as long as there is still one single WEST unit inside the trigger area, not one new WEST unit who enters the trigger will be set to captive. All WEST units need to leave the trigger's area (to deactivate it), before it can be activated again. Well, at least this has been fact before the 1.9x patch series, and i wouldn't see any reason, why it should have changed as it's just logic. So if this could be a problem for you, could simply use another trigger + a boolean condition to instantly setcaptive true everybody inside the list(s) of the side specific trigger(s). Ah yeah, btw - and don't ask me this time again what i want you to do Quote[/b] ]on deactivation:"_x setcaptive false" Foreach Thislist This will do nothing, if you think about it again. onDeactivation = trigger's list is empty now "_x setcaptive false" forEach thislist = every unit, who isn't there anymore will be setcaptive false => nobody The secret here is: use two WEST present triggers One for the captive true area, and the other one a little bit taller for the captive false stuff (inner & outer trigger). Now you only need to to subtract the guys inside the inner trigger from the guys inside the outer trigger, and you'll have access to both parties again - the captives and the noncaptives. just thought this could help to prevent you from later troubles, if it becomes more complex and you don't know why it doesn't work anymore as supposed to. ~S~ CD Share this post Link to post Share on other sites
deathsai 0 Posted April 19, 2004 just thought this could help to prevent you from later troubles, if it becomes more complex and you don't know why it doesn't work anymore as supposed to.~S~ CD I do believe that you have gotten me more confused with all of that complexity than anything else Share this post Link to post Share on other sites
MrZig 0 Posted April 20, 2004 oh yeah, haha, I was in a rush so I didn't think lol Share this post Link to post Share on other sites