Home   Help Search Login Register  

Author Topic: Guard  (Read 2771 times)

0 Members and 1 Guest are viewing this topic.

Offline SaintPier

  • Members
  • *
Guard
« on: 15 Jul 2012, 15:45:40 »
Hi all,
Another question from an amateur mission builder. ;-)

I have set some OPFOR groups with one waypoint set on "Guard".
When BLUFOR troups are near and fighting another group, this first group starts to move towards the fighting.
But i want them to stay put, and defend their current location.
I tried "HOLD" to, but that does the same.
How can i let the OPFOR units to defend their location, instead of moving?

Thanks,
SaintPier

Offline Gruntage

  • Missions Depot
  • Administrator
  • *****
  • How do I get outta this chickensh*t outfit?
Re: Guard
« Reply #1 on: 15 Jul 2012, 15:55:06 »
You could try using the 'stop' and 'dostop' commands:

Code: [Select]

leader group1 stop true


Or maybe something like this:

Code: [Select]

group this stop true


The second code can be put in the group leader's init line.

It's been awhile since I last scripted anything for ArmA, but hopefully those commands will work.

Surprisingly, the 'stop' and 'dostop' commands are not in the 'ArmA only' comref, despite those commands being present in the game.

Hope this helps
Gruntage
"But one thing I can tell you from not just OFP but life in general:  criticism is directly proportional to quality. The more criticism a mission receives, the better the outcome" - macguba

Offline SaintPier

  • Members
  • *
Re: Guard
« Reply #2 on: 15 Jul 2012, 16:25:16 »
Thanks Gruntage,

I have put "{_X stop true} forEach units group this" in the init of the group leader and that seems to work.
Thanks a lot.

gr,
SaintPier

Offline savedbygrace

  • Intel Depot
  • Administrator
  • *****
  • Be swift to hear...slow to speak...slow to wrath.
Re: Guard
« Reply #3 on: 04 Sep 2012, 07:06:53 »
A note on Hold waypoints: Group moves to the waypoint and holds until the enemy is spotted where they then engage until the threat is eliminated OR no longer known. They then return to the hold position until more enemy has been spotted. To break a hold waypoint, a switch trigger can be implemented. Hold waypoints never complete (anything put into a HOLD waypoint's activation field will never be executed!). Timeouts also are ignored.

A note on Guard waypoints: Group moves to the waypoint and holds position. When the enemy is spotted, the group will behave as if it were a Hold waypoint (see above). When Guarded by side triggers are placed on the map, groups at guard waypoints will move to the guarded by side trigger upon reaching their guard waypoint. If more than one guarded by side trigger is placed, the group will defend the highest priority trigger (The first trigger placed) If more than one group has guard waypoints, the groups move to any unoccupied guarded by side triggers until all are occupied. Once all triggers are defended by a group, any groups remaining with guard waypoints will hold at their guard waypoint until a guarded by side trigger is no longer defended. When the enemy is spotted anywhere on the map, the group at the lowest priority trigger responds and any groups waiting at guard waypoints will move to fill their spot. Timeouts and conditions in guard waypoints are ignored and the waypoint never completes.