Robert1983NL Posted May 13, 2013 Posted May 13, 2013 Hey guys, I'm working on a mission. It's basicly a CSAR mission. You have a friendly squad running away from the enemy, and the clients have to find and pick up that squad. I've got it all sorted out with a client coming near, squad popping flares, client starting approach, squad popping smoke... But at that point I want the squad to stop moving, so they can be picked up. For some reason this won't work. The trigger does work, because they pop smoke, but in that same trigger the action should also be to have the group stopped. What I have done right now is: Flag(11) is ON at mission start The to-be-rescued-squad has a triggered action: 1. Hold -/? The END CONDITION for this: IS USER FLAG 11 (checked) This should have the squad moving until Flag 11 is OFF, correct? When a client comes near (inside the moving trigger zone), they'll pop smoke and the other action is FLAG(11) OFF. At this point I would expect the squad to stop moving, but they won't. Does anyone know what the problem is? Or how would you guys do this? FYI, this is just a small part of all my triggers/conditions etc, because I've made a couple of random squads to be rescued so you won't always find them in the same area. Also, I want all 4 Huey clients to be able to pick up the troops, I've got that implemented as well. Just need the squad to stop moving...
dave4002000 Posted May 13, 2013 Posted May 13, 2013 The 'Hold' task can only be associated with a waypoint. The "quick and dirty" method would be to set numerous waypoints along their route with the same hold and stop conditions. Then once your clients get inside the zone that sets flag 11 off, the infantry will continue to the closest waypoint and then stop there. Like i said, that's a very dirty method of doing it. There is, most likely, a more elegant solution available from lua but that's over my head. USAF Bomber Avionics Specialist, Ret. (2A5) Water-cooled i7-8700k @ 5.0GHz Nvidia GTX1080 32 GB DDR4-3200 M.2 NVMe Drive Warthog HOTAS Oculus Rift CV1
AlaskanGrizzly Posted May 16, 2013 Posted May 16, 2013 Have you tried just turning the squad's AI off to see if that would stop them from moving?
Puddlemonkey Posted May 16, 2013 Posted May 16, 2013 You can try this - not sure whether it will work as I haven't used it for months. Substitute strGroupName with the name of the group or put it inside a function with strGroupName as a parameter. local objGroup local strGroupName local tabTask objGroup = Group.getByName(strGroupName) if objGroup ~= nil then objController = objGroup:getController() tabTask = { id = 'Hold', params = { }, } Controller.setTask( objController, tabTask) rawset(self._private, "task", "hold") if self._private.onHold ~= nil then self._private.onHold() end end
Joyride Posted May 16, 2013 Posted May 16, 2013 Hey guys, I'm working on a mission. It's basicly a CSAR mission. You have a friendly squad running away from the enemy, and the clients have to find and pick up that squad. I've got it all sorted out with a client coming near, squad popping flares, client starting approach, squad popping smoke... But at that point I want the squad to stop moving, so they can be picked up. For some reason this won't work. The trigger does work, because they pop smoke, but in that same trigger the action should also be to have the group stopped. What I have done right now is: Flag(11) is ON at mission start The to-be-rescued-squad has a triggered action: 1. Hold -/? The END CONDITION for this: IS USER FLAG 11 (checked) This should have the squad moving until Flag 11 is OFF, correct? When a client comes near (inside the moving trigger zone), they'll pop smoke and the other action is FLAG(11) OFF. Easier ways to do this. You are ending the hold condition at mission start by making 11 true, so at some point another Hold action needed to be executed. All you need is a triggered action Hold for that group to occur when they pop smoke. At that point they are waiting for pickup and not expected to move anymore, right? If so, then it doesn't even need an end condition flag used.
Recommended Posts