EBass 0 Posted January 31, 2011 Hi guys, I'm making a mission that is far more advanced than anything I've attempted before and as such I've run into a few problems. Firstly is there a way to make the OPFOR side cease fire entirely until a trigger activates and then have them resume firing? Secondanly is there a way to make buildings invulnerable? I ask because in the mission I've got some ZSUs on rooftops and if the building is destroyed from under them which at the moment is frequently happening, they just sit in mid air which doesen't look great. Thirdly, how would one make a unit join one of three squads when a trigger is fired. Essentially how would you make a unit join the squad that activates the trigger? I've figured out a workout around where I place a trigger for each squad at each location and also a trigger to detect if the target is present and then when both fire have that linked to a game logic "and" which disables all the other triggers. But this means I need 24 triggers and 18 game logics to perform what should be a pretty simple operation. Additionally how would I make a radio operation only useable once a trigger has been fired? I know I could set the trigger status that fires the radio to false, but then the radio command is still useable it just won't do anything. I only want the radio to be allowed once another trigger has been fired. Also how would I make a unit go to its next waypoint when a specific unit has boarded it? I.e I have a helicopter "load" waypoint and I do not want it to leave until a specific unit enters it. I know I can achieve this generally with syncing the units "get in" waypoint with the load waypoint but in this situation the unit has joined another squad so setting a waypoint from the get go won't work as this waypoint would be cancelled when it joins the squad. I suppose I'd have to sync a trigger to the waypoint with the triggers condition line being something like "Escort1 ismoveincargo heli1" or something. Whats the command? Cheers for the help guys. Share this post Link to post Share on other sites
speeder 0 Posted January 31, 2011 Secondanly is there a way to make buildings invulnerable? I ask because in the mission I've got some ZSUs on rooftops and if the building is destroyed from under them which at the moment is frequently happening, they just sit in mid air which doesen't look great. BUILDING-ID Allowdamage false Thirdly, how would one make a unit join one of three squads when a trigger is fired. Essentially how would you make a unit join the squad that activates the trigger? I've figured out a workout around where I place a trigger for each squad at each location and also a trigger to detect if the target is present and then when both fire have that linked to a game logic "and" which disables all the other triggers. But this means I need 24 triggers and 18 game logics to perform what should be a pretty simple operation. Myunit Join (thislist select 0) Additionally how would I make a radio operation only useable once a trigger has been fired? I know I could set the trigger status that fires the radio to false, but then the radio command is still useable it just won't do anything. I only want the radio to be allowed once another trigger has been fired. Myunit1 showRadio false, and then just set it to true when your condition is meet It's just of the top of my head. Share this post Link to post Share on other sites
ffur2007slx2_5 11 Posted January 31, 2011 Hi guys, I'm making a mission that is far more advanced than anything I've attempted before and as such I've run into a few problems.Firstly is there a way to make the OPFOR side cease fire entirely until a trigger activates and then have them resume firing? Secondanly is there a way to make buildings invulnerable? I ask because in the mission I've got some ZSUs on rooftops and if the building is destroyed from under them which at the moment is frequently happening, they just sit in mid air which doesen't look great. Thirdly, how would one make a unit join one of three squads when a trigger is fired. Essentially how would you make a unit join the squad that activates the trigger? I've figured out a workout around where I place a trigger for each squad at each location and also a trigger to detect if the target is present and then when both fire have that linked to a game logic "and" which disables all the other triggers. But this means I need 24 triggers and 18 game logics to perform what should be a pretty simple operation. Additionally how would I make a radio operation only useable once a trigger has been fired? I know I could set the trigger status that fires the radio to false, but then the radio command is still useable it just won't do anything. I only want the radio to be allowed once another trigger has been fired. Also how would I make a unit go to its next waypoint when a specific unit has boarded it? I.e I have a helicopter "load" waypoint and I do not want it to leave until a specific unit enters it. I know I can achieve this generally with syncing the units "get in" waypoint with the load waypoint but in this situation the unit has joined another squad so setting a waypoint from the get go won't work as this waypoint would be cancelled when it joins the squad. I suppose I'd have to sync a trigger to the waypoint with the triggers condition line being something like "Escort1 ismoveincargo heli1" or something. Whats the command? Cheers for the help guys. Hey guy, really a long thread, lol. 1. You can cease the entire OPFOR side firing by creating a very large trigger which can cover all OPFOR units. And remember, you need to name the leader of each OPFOR squard like _A, _B, ect. Then, write such code in its on act: {(leader group _x) setCombatMode "BLUE"} forEach ((units group _A) + (units group _b)) After condition activated, {(leader group _x) setCombatMode "RED"} forEach ((units group _A) + (units group _b)) to enable OPFOR returning fire. And I'm sorry that I've to answer your following questions later. Share this post Link to post Share on other sites
EBass 0 Posted January 31, 2011 The allow damage thing doesen't work. "Building-8449 Allowdamage false" comes up with "Type number expected objected as does "8449 Allowdamage false". For the second one, so would a trigger sensing blufor presence work with onactivation line set to "Myunit Join (thislist select 0)" (with my unit being the unit I want to join up.) I'll test. Myunit1 Showradio False comes up as "Missing ;" Ffur thanks for that, I've got a LOT of squads in my mission but as long as it works I can put in the grind, cheers! Share this post Link to post Share on other sites
st_dux 26 Posted January 31, 2011 2. allowDamage should work, but you need to use nearestObject to get the building. The syntax is <position> nearestObject <ID>. 3. To make a unit join a squad that activates a trigger, use this for your On Activation code: <unit> join group (thisList select 0) 4. First, in your init.sqf or the init field of any object/vehicle/unit, write this: <index> setRadioMsg "NULL" This will make the radio trigger with the given index unavailable at the start of the mission. Replace <index> with a number corresponding to the radio trigger you wish to be invisible (1 for Alpha, 2 for Bravo, etc.). When you want to make the radio trigger available, use the same line as above, replacing "NULL" with whatever text you want to appear in the radio menu. 5. As a condition of the load waypoint, put the following: <unit> in (vehicle this) You may need to manually make the helicopter land, however. This can be achieved using either a very low flyInHeight value or with the land command. Share this post Link to post Share on other sites
Big Dawg KS 6 Posted January 31, 2011 The allow damage thing doesen't work. "Building-8449 Allowdamage false" comes up with "Type number expected objected as does "8449 Allowdamage false". You need a nearestObject search: (getPos player nearestObject [i]ID[/i]) allowDamage false Share this post Link to post Share on other sites
EBass 0 Posted January 31, 2011 The radio thing works great thanks, as does everything else but as for the OPFor not firing. "{(leader group _x) setCombatMode "BLUE"} forEach ((units group _A) + (units group _b))" Comes back as "local variable in global space" if I name something _A or _B. If I name it just B or A the error doesent come up, but even when I name the squad leaders they still open fire. Also will any trigger do? Currently I'm using a massive trigger with East Present as its trigger. Share this post Link to post Share on other sites