Home   Help Search Login Register  

Author Topic: POW Capture/Join Group Script Updated (ACCEPTED)  (Read 1526 times)

0 Members and 1 Guest are viewing this topic.

Offline norrin

  • Tutorial Writer
  • **
POW Capture/Join Group Script Updated (ACCEPTED)
« on: 23 Nov 2007, 05:23:05 »
POW Capture/Join Group Script Updated

Here's the revised script ready for testing.  It's been rationalised as you've suggested but its a bit of of hybrid as it still requires multiple instances (one for each POW) running on the group leader client's PC.

Description

The script adds an action to the group leader's action menu only when the group leader, a player within the group or an AI unit in the group is within 3 metres of a capturable/POW AI unit.  If the group leader then uses the action the AI unit joins his group and can be ordered around by the leader.

If the unit from your group moves away from the POW then the action will disappear but will reappear if the unit moves back to the POW.  If the group leader is killed and respawns then he will still get the action if a member of his group is within 3 metres of the POW.  Also if the POW dies or the POW joins your group or another friendly group the script exits and the action will not appear.

Test Mission
In the test mission there are four POWs including a BLUFOR pilot and OPFOR unit.  Make sure you choose the team leader role and then just send an AI unit from your group to any of the POW.  When your team member or yourself are within 3 meters of the capturable unit the capture action will appear in the action menu.   Activate it and the POW should join your group, an icon for the POW appears in the group list in the bottom left-hand corner of the screen, it run towards you and take its place in your groups formation.

To implement
1. Copy across the info from the init.sqf and the POW_sqf folder into your mission directory
2. Name your POW units in the editor something like POW1, POW2 etc.
3. You need to define the units you want to be POWs in the _NORRN_POW array in the init.sqf.

eg
Code: [Select]
_NORRN_POW = [POW1, POW2, POW3, POW4];

Limitations
* This script only works through the middle mouse scroll action menu, not when you use the action keys like: F2 (unit) + 6 (action) + 4 (Capture Pow).
* As each POW requires the group leader to run an instance of the script on his PC it maybe best not to use these scripts for too many capturable AI units.

Tested
Ver 1.08 with JIP.

OFPEC DOWNLOAD
« Last Edit: 10 Aug 2009, 20:49:09 by hoz »

Offline Spooner

  • Members
  • *
  • Mostly useless
    • Community Base Addons
Re: POW Capture/Join Group Script Updated
« Reply #1 on: 23 Nov 2007, 11:55:48 »
Please don't create a new thread every time you release a new version. Just add a new post to your original thread informing us that you have updated it, which will bring it to the top of the forum, and edit the text and attachments in the original post of that thread. There are two reasons for this: One is that unnecessarily creating new threads clutters up the forum and the other is that people who have subscribed to your old thread because they want to know about updates, but who don't regularly check the forum, won't see this update message.

LOCKED (Please release this in original thread for this script)
« Last Edit: 23 Nov 2007, 11:58:03 by Spooner »
[Arma 2] CBA: Community Base Addons
[Arma 1] SPON Core (including links to my other scripts)