4 posts / 0 new
Last post
Wolffy.au
Offline
Joined: 24/06/2009
Random TaskPatrol Demo - v2.0

This mission is to demonstrate the use of the taskPatrol function (Binesi's improved version).


In range, Cached and Building Patrols


It includes random spawning of Infantry and Motorised groups, who patrol the areas displayed on the map (including inside buildings). Use the radio commands to use teleport and camera functions.


Created by: (AEF)Wolffy.au [2CAV]


Addons Required:
None


Installation:
It comes with a mission as a demo version. Extract the folder to your ArmA2\other Profiles\Yournick\Missions and load it in the editor.


Usage:
Put the following in the INIT of a Game Logic object:
0 = [position this, "Infantry", 100] execVM "crB_scripts\crB_taskPatrol.sqf";


Where the first parameter is the position of the centre of the patrol.
The second parameter is the group type, "Infantry", "Motorized", "Mechanized", "Armored" or "Air".
The third parameter is the radius you wish them to patrol.
There is an optional fourth parameter, which is passed to crB_randomGroup script, which is a side of a faction (east, west, resistance or civilian), a single faction eg "ACE_USARMY" or an array of factions eg ["ACE_USARMY_DESERT", "ACE_USMC_DESERT"].


Change Log:
v2.0
- Added: crB_randomGroup.sqf v2.0
- Changed: The purpose to always create random groups for patrolling
- Changed: INIT.SQF to minimum requirements
- Removed: AI unit caching from demo
- Removed: Dependency on ACE
v1.2
- Added: Random group spawning to keep things interesting.
- Added: CEP Unit Caching and radio functions to demonstrate their use.
- Changed: Now using Binesi's BIN_taskPatrol.sqf v1.3 instead of BIS's BIS_fnc_taskPatrol function. This includes an updated version of Binesi's taskPatrol which will enter buildings as part of their patrols.


Thanks to:
    Random Group Spawn code by Odin
    CEP Unit Caching by Myke
    Improved taskPatrol by Binesi


Visit us a http://creoBellum.org


Developer notes:
Here is a list of nifty components to be found in this mission.


Random Group Spawn code by Odin
- This piece of code has turned out to be the most important piece of my future mission making. Using GameLogic objects, this code will spawn random enemy groups of Infantry, Motorised, Mechanised, Armour and Air. In conjunction with Binesi's taskDefend and taskPatrol code, randomised mission making has never been simpler.


Improved taskDefend and taskPatrol by Binesi
- Binesi posted these improved BIS functions around the same time I was asking myself the same question. Placing patrols and defensive squads has never been simpler.


Syndicated:


AttachmentSize
cB_TaskPatrol_2-0.utes_.zip7.85 KB
Wolffy.au
Offline
Joined: 24/06/2009
Updated to v2.0- Added:

Updated to v2.0
- Added: crB_randomGroup.sqf v2.0
- Changed: The purpose to always create random groups for patrolling
- Changed: INIT.SQF to minimum requirements
- Removed: AI unit caching from demo
- Removed: Dependency on ACE

armaholicbr
Offline
Joined: 14/10/2010
Hello

Hello, first of all congratulations for this awesome script!

I'm creating a mission and the script didn't work adding a 4th parameter to limit units to takistan army or militia, simply didn't spawn anything. Could you please take a look at that? It may not be optimized for OA..

Btw, what is the respawn time for the patrols? Can it be customized? Tyvm..

Wolffy.au
Offline
Joined: 24/06/2009
Make sure you have a least

Make sure you have a least one unit of the faction you are trying to spawn in the editor, otherwise it will not create any units.


Once the patrol is dead, no respawn. As the group parameter is not passed anywhere, its not easy to monitor if they are all dead to respawn unfortunately.

 
Original Design by Gary Storey