Jump to content
cool=azroul13

UPSMON Updated to ArmaIII

Recommended Posts

As to find the last UPSMON link become complicated in The previous thread, I start a new thread.

I continue to work on the UPSMON script, created by Monsada for Arma2, improved by Rafalsky,Nordin and Shay_Gman and ported to Arma 3 by Ollem.

Presentation (written by Monsada) :

Wiki:http://dev-heaven.net/projects/upsmon/wiki

FAQ

To turn of messages and marks on map edit init_upsmon.sqf and set debug to 0

UPSMON_Debug = 0;

With upsmon I don´t need to put any waypoints. My work area is in CHS Comunity so I will be pleased to meet you there

http://www.simulacion-esp.com/v3/top...87entry60687

//AI improvements

* There is a General commander that organize the attack and defence of all UPSMON squads in the same side:

o Squads of AI fights together as an army, so they comunicate each other by radio the enemy known positions.

o flanking manauvers are taken depending on friendly position.

o General commander can order to surrender entire side if army is seriously damaged

* AI has enhanced actions and movements in combat:

o AI can use smoke grenades.

o AI run crouched when enemy is near or under fire.

o AI does fire suppression and squad movement can be supressed by fire too.

o AI moves are influenced by morale, so in low morale they can retreat.

o AI can lay mines if enemy tanks are near.

o AI avoid snipers when fired by uknown enemy.

o AI paratroop near objectives if they take an hely.

* AI take use of enviroment:

o AI may use static weapons you place on map.

o AI may use empty land vehicles for moving and or to attack.

o AI may use empty helys for moving and or to attack.

o AI uses buildings to take defence position and patrol them when leader thinks than enemy is near or using it.

// Performance

UPSMON Script runs 1 time every 20 seconds for every group of IA, new movements calculates every 60 s or less depending of under fire, enemy knowns...

I have been implementing some functions in spawn mode to exploit the multithread of processors with very fast results.

UPSMON has been tested in CHS comunity with more than 30 people and more than 25 groups of IA with UPSMON and the conclusion was perfect performance.

Installation:

Copy folder "scripts" into your folder mission.

How to Implement

In your init.sqf, add this line:

//Init UPSMON script

call compile preprocessFileLineNumbers "scripts\Init_UPSMON.sqf";

Mandatory Parameters:

You must add the group leader name as first parameter then the area marker.

nul=[this,"Marker"] execVm "scripts\UPSMON.sqf";

In this configuration, your group will patrol randomly in your marker area, with his default behaviour and formation.

Warning:

Do not copy/paste the parameter line from the Pdf to ArmaIII, it will not work for some weird reason (thanks Rambler).

Optionnal Parameters:

Behaviour and formation parameter:

You can modify the behaviour and formation of the group just by adding in the array the type of behaviour or formation you want like:

[this,"Marker","SAFE","COLUMN"] execvm "scripts\UPSMON.sqf";

"showmarker" parameter:

By default, the group area marker will turn invisible when an UPSMON is initialized, if you want that the marker will stay on his zone then add this parameter:

[this,"Marker","SHOWMARKER"] execvm "scripts\UPSMON.sqf";

Random position parameter:

You can randomize the position of your group in the marker area with this parameter: "RANDOM"

[this,"Marker","RANDOM"] execvm "scripts\UPSMON.sqf";

Unit of the group can be placed randomly in building position (in all the marker area) with these parameters:

"RANDOMUP" --> only highest position of the building will be choose.

"RANDOMDN" --> only down position.

"RANDOMA" --> all positions of the building.

The larger the area will be the longer it will take for units to found their positions.

It is recommended to use these last parameter with "NOWP" parameter.

No waypoints parameters:

Mainly usefull with "RANDOMUP/DN/A" parameter, "NOWP" parameter will the unit to create any waypoint with UPSMON but the group will communicate with other UPSMON and can ask for artillery or reinforcement.

You can add your proper waypoint for the group or add to some units a combat animation, or place each unit of the group where you want.

There are three types of "NOWP".

"NOWP" --> the group will act as UPSMON unit when the group is aware of an enemy.

"NOWP2" --> the group will act as UPSMON unit when one of the unit of the is wounded or dead.

"NOWP3" --> the group will never create any wayppoint.

Communication parameters:

You can set if a group will communicate his information with another UPSMON (activate by default) or if a group can ask for reinforcement or artillery in his sector.

"NOSHARE" --> add this parameter if you want that the group not share any information with nearest UPSMON group.

"RADIORANGE:",_number --> You can set the radio range (in meter) of each UPSMON group, the radio range is linked to the reinforcement and artillery module. (by default:10000)

[this,"Marker","RADIORANGE:",800] execvm "scripts\UPSMON.sqf";

"NOVEH" parameters:

By default if the waypoint of an UPSMON infantry is far away from their position they will try to search for vehicle (200m around the leader position).

You have two solutions to prevent an UPSMON to use a vehicle: you can lock it or you can add "NOVEH" in the leader init parameter.

In combat they will search for combat vehicle even if you add this parameter. If you don't want them to use any vehicle, no matter the situation, then add "NOVEH2" parameter.

Ambush parameters:

You have many parameters, first of all you can add one of these parameters:

"AMBUSH" --> the group will lay down mines and then take ambush position.

"AMBUSH2" --> same as the previous but the unit will not lay down mines.

["AMBUSHDIR:",direction] or ["AMBUSHDIR2:",direction] --> with these parameters you can set the orientation of the ambush ("NORTH","NORTHWEST","NORTHEAST","SOUTH","SOUTHEAST")

Then you can add some more parameters:

["AMBUSHDIST:",_nbr] --> you can set the distance between the ambush point and the ambush position.

["MINE:",_nbr] --> you can set the number of mines used for the aambush. (3 by default)

["MINEtype:",_nbr] --> you can set the type of the mines, 1-for only AT mine, 2-AT mines and AP mines, 3-only AP mines. (2 by default)

Reinforcement parameters:

You have two reinforcement types:

1-

The reinforcement group that can be called by another UPSMON group.

First of all you need to add to the reinforcement group this parameter:

[this,"Marker","REINFORCEMENT"] execVM "scripts\upsmon.sqf";

Then you need to activate the reinforcement module by adding in a trigger or script this command line:

UPSMON_reinforcement = true; publicvariable "UPSMON_reinforcement";

2-

the reinforcement group controlled by the mission maker.

you need to add to the reinforcement group this parameter:

[this,"Marker","REINFORCEMENT:",1] execVM "scripts\upsmon.sqf";

The number is the id of your reinforcement group.

Then Like the precedent you need to activate the reinforcement module and add a position where the group will move to.

UPSMON_reinforcement1 = true; publicvariable "UPSMON_reinforcement";UPSMON_reinforcement1_pos = getMarkerPos "mkr1";

The id number must match with the id of the reinforcement group.

Artillery module:

You need to add this line to your artillery unit:

[_artillery,(_rounds,_range,_area,_cadence,_mincade nce)] execvm "scripts\UPSMON\MON_artillery_add.sqf";

<- _artillery object to attach artillery script, must be an object with gunner.

<- ( _rounds ) number of munition for the artillery [FLARE,SMOKE,HE]

<- ( _area ) Dispersion area, 150m by default

<- ( _maxcadence ) Cadence of fire, is random between min, default 10s

<- ( _mincadence ) Minimum cadence, default 5s

Then you need to activate the artillery system:

UPSMON_ARTILLERY_(SIDEOFTHEARTILLERY)_FIRE = true;

This list is just a part of the manual that contains all parameters reference. Check the info folder. (Thanks to Grumpy Old man who made some corrections to the manual.)

There are two test missions in the folder.

Link to UPSMON 6.0.9.5:

UPSMON - Urban Patrol Script v6.0.9.5

Edited by Cool=Azroul13
  • Like 1

Share this post


Link to post
Share on other sites

Good to see that upsmon finally has its own thread!

Thumbs up for the good work, definitely one of my favorite scripts out there!

Share this post


Link to post
Share on other sites

Firstly may I thank you for your ongoing development of UPSMON.

However, may I suggest not to be adding new scripts (TWPCAS) for example. While there is nothing wrong with TWPCAS and you may prefer to use it, it is a separate script and should NOT be included in UPSMON by default.

I for example am getting errors when my mission starts with TWPCAS, and I had to sort these issues by reffering to the TWPCAS thread. But TWPCAS is not UPSMON and should be kept separate. Of course by all means provide compatibility.

With regard to any new options you may be adding, can you also please default these to OFF. (surrender for example is defaulted to on). I know you are providing help on how to use these new feature, but they should still be off by default. This means existing missions will work with the script without having to add/change their UPSMON inits.

This is after all Monsada's script.

Otherwise, keep up the great work

Share this post


Link to post
Share on other sites
Guest

Updated version frontpaged on the Armaholic homepage.

==================================================

You are not registered on Armaholic, or at least not that we are aware of. In the future we offer the possibility to authors to maintain their own pages.

If you wish to be able to do this as well please register on Armaholic and let me know about it.

This is not mandatory at all! Only if you wish to control your own content you are welcome to join, otherwise we will continue to follow your work like we have always done ;)

When you have any questions already feel free to PM or email me!

Share this post


Link to post
Share on other sites

Thank you for another update!

Now for the questions:

1. do we still need to identify playable units in the init_upsmon?

2. my patrolling units seem to be walking not in SAFE mode (with the weapon lowered) but in either aware or some other mode: with the weapon at the ready, constantly aiming. Is it normal or is the problem on my end?

Share this post


Link to post
Share on other sites

@Beerkan

I always forget to put it off. :rolleyes: after testing the different module.

It will be corrected.

@Foxhound

Thanks.

@GvsE

1.Yes

2.Does they know of any enemy in the zone ?

Does it happen at the beginning ?

Try to put the bottom line in the leader init:

nul=[this,"area","SAFE"] execVM "scripts\upsmon.sqf";

Share this post


Link to post
Share on other sites

On Armaholic is states "It comes with a mission as a demo version". But I do not see anything. I really think it would be immensely helpful if it did have a test mission of the complicated portions of it such as the artillery, reinforcement with vehicles, ambushes (mine never work), and so forth. Thanks for the mod

Secondly, how do you spawn units with a trigger? For instance if I want to the patrols to only spawn when players are about 500 meters away from the area marker, in order to save cache and prevent lag, how do I do that?

Edited by chondo999

Share this post


Link to post
Share on other sites

No sorry, it doesn't come with any mission, but I'll make some for the next version ;) .

About Reinforcement and SPAWN module you can check UPSMON wiki that I link in the first post, it always the same way.

About Ambush module, have you try to only put "Ambush" or "ambush2" as init parameter ? it doesn't need more, all the other parameter are optionnal.

[this,"mk1","AMBUSH"] execvm "scripts\UPSMON.sqf";

Share this post


Link to post
Share on other sites
.... how do you spawn units with a trigger? For instance if I want to the patrols to only spawn when players are about 500 meters away from the area marker, in order to save cache and prevent lag, how do I do that?
Create an area and call it "area0". Set it to the size of the area you want the spawned units to patrol. Now create a trigger 500m away from "area0" with Activation BLUFOR and Once and put this in the On Act:
_nul = ["area0", "area0"] execVM "Spawn_Grp1.sqf";

See this.

Untitled.jpg

Now create a spawn script. Let UPSMON know the units are spawned by using the "SPAWNED" variable. In the example below, units will be spawned randomly in "area0" on the ground and will patrol it not waiting at each waypoint.

The units will also be deleted 300 seconds after death.

Spawn_Grp1.sqf

if (!isServer) exitWith {};
_spawnPoint = _this select 0;
_patrolArea = _this select 1;
_side = EAST;
_pos = getMarkerPos _spawnPoint;
_spawngrp = [_pos , _side, (configfile >> "CfgGroups" >> "East" >> "OPF_F" >> "Infantry" >> "OIA_InfSquad")] call BIS_fnc_spawnGroup;
sleep 3;// Let units initialise
_leader = leader _spawngrp;
nul = [_leader,_patrolArea,"NOWAIT","RANDOM","SPAWNED","DELETE:",300] execVM "scripts\upsmon.sqf";

You can also customise the units.

Here's the same script with custom units.

if (!isServer) exitWith {};
_spawnPoint = _this select 0;
_patrolArea = _this select 1;
_side = EAST;
_skill = [0.1, 0.4];
_units = ["O_Soldier_SL_F","O_Soldier_A_F","O_Soldier_AA_F","O_Soldier_AT_F","O_soldier_AR_F","O_soldier_GL_F","O_soldier_M_F","O_medic_F"];
_pos = getMarkerPos _spawnPoint;
_spawngrp = [_pos, _side, _units, [], [], _skill] call BIS_fnc_spawnGroup;
sleep 3;// Let units initialise
_leader = leader _spawngrp;
nul = [_leader,_patrolArea,"NOWAIT","RANDOM","SPAWNED","DELETE:",300] execVM "scripts\upsmon.sqf";

Edited by Beerkan
fixed script for latest UPSMON

Share this post


Link to post
Share on other sites

Thanks for keeping this up-to-date (and for a new thread!)

Share this post


Link to post
Share on other sites

Two things I noticed after some testing.

1: The debug console does not always work. Of the 8 times I restarted the mission, the console came up only once. Yes, I have turned in on via the Init_UPSMON.

2: The UPSMON units act as if they are under attack within 5 seconds of moving; they go into combat mode and just stay in one position, negating the purpose of a patrol script. There is absolutely no one else on the map other than myself, who is a friendly to them, nor are there optional parameters; indeed, all in have is the basic [this,"town"].... Any help on this would be most appreciated.

Edited by chondo999

Share this post


Link to post
Share on other sites

I have a request :

why dont you use the playableUnits command to manage list of all playable slot in a mission ?

thx for your work.

Share this post


Link to post
Share on other sites

@Chondo999

Sorry I can't reproduce your problem. Do you use any addon ? Is the group been spawned ?

@GToF

Thank I will update it.

Share this post


Link to post
Share on other sites

2.Does they know of any enemy in the zone ?

Does it happen at the beginning ?

Try to put the bottom line in the leader init:

nul=[this,"area","SAFE"] execVM "scripts\upsmon.sqf";

Hey man,

no, they do not know of any enemy (I have a trigger which tells me if I am detected or not). I disabled other mods to check if AiA was perhaps interfering but no, they still patrol in combat stance (they do walk slowly, but aiming down the sights).

Adding "safe" parameter has had no impact.

Btw, Im running the dev build of the game.

Share this post


Link to post
Share on other sites

This one is still above my head but I'm very interested in running Drongo's DRIrregulars vs Massi's NATO stuff on maps brought over from AiA. Definitely keeping an eye on this thread and maybe I'll understand some of it one day :)

Share this post


Link to post
Share on other sites

have you made any changes to how reinforcements work? With the latest script pack the group with the reinforcement command does nothing after the KRON_UPS_reinforcement==true is triggered. I just need to swap the latest script folder for an older pack and voila, all is good.

Share this post


Link to post
Share on other sites

@GvsE

It will work now ;)

So new version (6.0.6.1):

I add one parameter for ambush module ("LINKED:")

I remove TPWCAS from the folder so if you want to use it you need to download it separately.

Set all new variable off by default.

Add Some little corrections.

And I add two test missions for Ambush and artillery module.

Share this post


Link to post
Share on other sites
Guest

Updated version frontpaged on the Armaholic homepage.

==================================================

You are not registered on Armaholic, or at least not that we are aware of. In the future we offer the possibility to authors to maintain their own pages.

If you wish to be able to do this as well please register on Armaholic and let me know about it.

This is not mandatory at all! Only if you wish to control your own content you are welcome to join, otherwise we will continue to follow your work like we have always done ;)

When you have any questions already feel free to PM or email me!

Share this post


Link to post
Share on other sites

Thanks for the updates :)

Would it be possible to make the UPSMON AI enhancements optional, so that UPSMON could be used in conjunction with AI enhancement scripts or addons like bCombat and potential future mods?

It would be awesome to have the UPSMON capablility for waypoint creation and target-sharing, patrol, ambush, fortify functions etc. and combine it with other great mods.

I would like to underline that I find UPSMON and your continued work on it awesome! I'm just hoping for some compatibility, also mods like bCombat seems to evolve quickly and will probably be on the list of must-have mods soon.

Share this post


Link to post
Share on other sites

@Thanks Foxhound

@Malkekoen

bcombat is a really great AI mod which enhance individual AI behaviour. The main problem will be on morale and supression system that we both use in our script. The other will be the smoke screening that you can remove in Init_UPSMON (line 81 and 82).

But I will look how to make both compatible.

Share this post


Link to post
Share on other sites

@Malkekoen

bcombat is a really great AI mod which enhance individual AI behaviour. The main problem will be on morale and supression system that we both use in our script. The other will be the smoke screening that you can remove in Init_UPSMON (line 81 and 82).

That would be great. I tried it with both mods yesterday, and there was some error messages, all relating to an UPSMON function called "react" or something like that. Guess both bCombat and UPSMON tried to do something... It happended when units got under fire. I haven't checked the logs though. But it worked without any serious problems as far I could tell during my quick run.

But I will look how to make both compatible.

:yay:

Share this post


Link to post
Share on other sites
Thanks for the updates :)

Would it be possible to make the UPSMON AI enhancements optional, so that UPSMON could be used in conjunction with AI enhancement scripts or addons like bCombat and potential future mods?

You could try the "noAI" parameter.

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×