Jump to content

Monsada

Member
  • Content Count

    228
  • Joined

  • Last visited

  • Medals

Everything posted by Monsada

  1. Versión 5.0.7 Project Space for Monsadas UPSMON at Dev-Heaven now available! Please Register for an account at Dev-heaven.net and post all your suggestions, bug-reports, support-request, etc. in the UPSMON Project Space under "Issues" Please open one Ticket for Feature-Request/Bug-Report/Support-Request only! Wiki:http://dev-heaven.net/projects/upsmon/wiki FAQ Changes in version: This is a personal projet to enhance IA in combat and making easier mission edition. I have used the version 2.0.3 of Urban Patrol Script de Kronzky. I have to congratulate Kromzky for his script UPS.sqf that has inspired me for doing UPSMON. 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/topic/18360-urban-patrol-script-version-monsada/page__gopid__60687entry60687 //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. //Download Dev-heaven //Installation Copy folder "scripts" into your folder mission. //How to Implement In init.sqf you need to load init_upsmon.sqf //Init UPSMON scritp call compile preprocessFileLineNumbers "scripts\Init_UPSMON.sqf"; In the mission editor run UPSMON script in the lider of each group exec UPSMON, sample: nul=[this,"town", "move","reinforcement", "delete:",600] execVM "scripts\upsmon.sqf"; //Global variables of Init_UPSMON.sqf //1=Enable or 0=disable debug. in debug could see a mark positioning de leader and another mark of the destinity of movement, very useful for editing mision KRON_UPS_Debug = 1; //Time that lider wait until doing another movement, this time reduced dinamically under fire, and on new targets KRON_UPS_react = 60; //Min time to wait for doing another reaction KRON_UPS_minreact = 30; //Max waiting is the maximum time patrol groups will wait when arrived to target for doing another target. KRON_UPS_maxwaiting = 30; // how long AI units should be in alert mode after initially spotting an enemy KRON_UPS_alerttime = 90; // how far opfors should move away if they're under attack KRON_UPS_safedist = 300; // how close unit has to be to target to generate a new one target or to enter stealth mode KRON_UPS_closeenough = 300; // how close units have to be to each other to share information, over this, will lose target KRON_UPS_sharedist = 800; //If enabled IA comunicating between them with radio defined sharedist distance, KRON_UPS_comradio = 2; //Sides that are enemies of resistance KRON_UPS_Res_enemy = [east]; //Frequency for doin calculations for each squad. KRON_UPS_Cycle = 20; //Height that heli will fly this input will be randomiced in a 10% KRON_UPS_flyInHeight = 100; //Max distance to target for doing paradrop, will be randomiced between 0 and 100% of this value. KRON_UPS_paradropdist = 250; //Enables or disables AI to use static weapons KRON_UPS_useStatics = true; //Enables or disables AI to put mines if armored enemies near KRON_UPS_useMines = true; //Distance from destination for seraching vehicles KRON_UPS_searchVehicledist = 500; //Percentage of units to surrender. KRON_UPS_EAST_SURRENDER = 10; KRON_UPS_WEST_SURRENDER = 10; KRON_UPS_GUER_SURRENDER = 15; //Efective distance for doing perfect ambush (max distance is this x2) KRON_UPS_ambushdist = 50; //Enable it to send reinforcements, better done it in a trigger inside your mission. KRON_UPS_reinforcement = false; //Artillery support, better control if set in trigger KRON_UPS_ARTILLERY_EAST_FIRE = false; //set to true for doing east to fire KRON_UPS_ARTILLERY_WEST_FIRE = false; //set to true for doing west to fire KRON_UPS_ARTILLERY_GUER_FIRE = false; //set to true for doing resistance to fire //Parámeters of UPSMON.sqf The same as UPS of Kronzky, only new "reinforcement" for allowing a group to go where is called for. // Required parameters: // unit = Unit to patrol area (1st argument) // markername = Name of marker that covers the active area. (2nd argument) // (e.g. nul=[this,"town"] execVM "ups.sqf") // // Optional parameters: // random = Place unit at random start position. // randomdn = Only use random positions on ground level. // randomup = Only use random positions at top building positions. // min:n/max:n = Create a random number (between min and max) of 'clones'. // init:string = Custom init string for created clones. // nomove = Unit will stay at start position until enemy is spotted. // nofollow = Unit will only follow an enemy within the marker area. // delete:n = Delete dead units after 'n' seconds. // nowait = Do not wait at patrol end points. // noslow = Keep default behaviour of unit (don't change to "safe" and "limited"). // noai = Don't use enhanced AI for evasive and flanking maneuvers. // showmarker = Display the area marker. // trigger = Display a message when no more units are left in sector. // empty:n = Consider area empty, even if 'n' units are left. // track = Display a position and destination marker for each unit. // reinforcement = Makes squad as reinforcement, when alarm KRON_UPS_reinforcement==true this squad will go where enemy were. // reinforcement:x = Makes squad as reinforcement id, when alarm KRON_UPS_reinforcementx==true this squad will go where enemy were. // fortify = makes leader order to take positions on nearly buildings at distance 200 meters, squad fortified moves less than "nomove" // spawned = use only with squads created in runtime, this feature will add squad to UPSMON correctly. // nowp = No waypoints will be created for this squad, so this squad will comunicate enemies but will not be moved, so you can do what you want with them using waypoints. // ambush = Ambush squad will not move until in combat, will wait for incoming enemies stealth and ambush when near or discovered. // ambush:n = Creates an anbush and wait maximun the especified time n in seconds. you can put 0 seconds for putting mines and go away if combined with "move" for example // aware,combat,stealth,careless defines default behaviour of squad // respawn = allow squad to respawn when all members are dead and no targets near // respawn:x = allows to define the number of times squad may respawn. videos of youtube: 5.0.4 Ambush: fortify and reinforcement: Getin: Building Patrol: paradrop: combat:
  2. Monsada

    [WIP] Urban Patrol Modification

    for spawning units using upsmon u need to call the mon_spawn function nul = [[b]TEMPLATE,POSITION,UNITS[/b],[mark, upsmon optional params]] execVM "SCRIPTS\UPSMON\MON_SPAWN.SQF"; 1. First u need a template squad, create a squad in editor and run upsmon on init setting the TEMPLATE parameter: nul = [this,"town","TEMPLATE:",1] execVM "scripts\upsmon.sqf"; This will set this squad with template id 1 with the patrol area of the mark named "town" 2. Now u can spawn squad template 1 where u need, comonly used in triggers, calling the upsmon spawn function: nul = [TEMPLATE,POSITION,UNITS,[mark, upsmon optional params]] execVM "SCRIPTS\UPSMON\MON_SPAWN.SQF"; nul = [1,position player,2,["town2","respawn"]] execVM "SCRIPTS\UPSMON\MON_SPAWN.SQF"; This will spawn 2 copies of template 1 squad on player position, this squad patrol area is mark name town2. note: spawned parameter on upsmon will not spawn any soldier! is only must be used when creating units at runtime that use upsmon. spawned = use only with squads created in runtime, this feature will add squad to UPSMON correctly. For more details and examples with upsmon s see wiki https://dev.withsix.com/projects/upsmon/wiki/MON_spawn https://dev.withsix.com/projects/upsmon/wiki/UPSMONsqf
  3. Monsada

    [WIP] Urban Patrol Modification

    Hi Oscar, I'm Monsada, the UPSMON autor and another catalonian programer like u. I created UPSMON for arma 1 and I'm surprissed that UPSMON is still running and adapted in ARMA3. We could take a beer in Figueres if u like ;), send me email if u come to figueres some day. Congratulations and good luck, Monsada
  4. Hi Hebreu, can u test "respawn" parameter? nul=[this,"island","fortify","delete:",600,"respawn"] execVM "scripts\upsmon.sqf"; you can add it in the spawn module too. If you want only to respawn x times set "respawn:",x i spect this can help u, Monsada
  5. When spawned a group with vehicles, soldiers and crew are created out of vehicle, then when leader orders to move to any position all will get inside. I don't understand if that is the problem or maybe when squad are moving they get out with no sense. The last I have seen some time when leader has contact to enemy.
  6. UPSMON has no sense if player is the leader because leader is who orders fire team soldiers.
  7. If i understand you have test it on falulla and ambush works fine, then the problem is in your mission, so without sample mission could see nothing. As told Rafalsky provide the sample mission so we can check it.
  8. in current version of UPSMON can not be changed, but you can try reinforcement spot instead. You can set a position to go when reinforcement is demanded. It Only can be done especifying groups of reinforcement. When you call for especific reinforcement you can especify a position too. KRON_UPS_reinforcementx = true; KRON_UPS_reinforcementx_pos = [0,0,0]; Sample of groups of reinforcement: 1. Create a squad in editor and put this on init: nul=[this,"airport","reinforcement:",1] execVM "scripts\UPSMON.sqf"; this code will exec upsmon on squad and set as reinforcement id 1. you cand assign various squads to the same reinforcement id. 2. Create a void mark in map and name it "rfpos1" 3. Execute next code in a trigger or where ever you want KRON_UPS_reinforcement1 = true; KRON_UPS_reinforcement1_pos = getMarkerPos "rfpos1"; When you set KRON_UPS_reinforcement1= true; reinforcement squad 1 is called for reinforcement and will be sent to position of mark "rfpos1"
  9. Init_uspmon must run on all client because of eventhandlers, but only for that, all resting code only executes on server, so after eventhandlers declaration for all clients, a check of server is executed //Adding eventhandlers "KRON_UPS_EAST_SURRENDED" addPublicVariableEventHandler { if (_this select 1) then { nul=[east] execvm "scripts\UPSMON\MON_surrended.sqf";};}; "KRON_UPS_WEST_SURRENDED" addPublicVariableEventHandler { if (_this select 1) then { nul=[west] execvm "scripts\UPSMON\MON_surrended.sqf";};}; "KRON_UPS_GUER_SURRENDED" addPublicVariableEventHandler { if (_this select 1) then { nul=[resistance] execvm "scripts\UPSMON\MON_surrended.sqf";};}; "MON_LOCAL_EXEC" addPublicVariableEventHandler { if (local ((_this select 1)select 0)) then { call ( compile format[(_this select 1)select 1,(_this select 1)select 0] ); }; }; if (!isServer) exitWith {};
  10. SEEK squad will patrol to random point, as MOVE does, then will patrol buildings there, will wait a time, and then will go to another random point. you want another parameter fortify2 that squad goes to random position and then fortify there no? ok is easy only must add fortify2 parameter and put this code before buiding usage //If fortify2 must change role to fortify when reached target position if (_fortify2 && _targetdist <= _closeenough ) then { _fortify = fortify2; _nomove="NOMOVE"; _minreact = KRON_UPS_minreact * 3; _buildingdist = _buildingdist * 2; _makenewtarget = false; _wait = 3000; }; //Buildings usage. .... ------------------------------------------- UPSMON runs only on server if (!isServer) exitWith {}; there is 2 types of server, dedicated server an client server, someone does as server and loads a mission this machine acts as server and client. on dedicated server there is no problem but on client server sometimes player is not initialized when init is executed this command makes init to wait until player is ready because if not player has not value and condition not matchs. waitUntil {player==player} you are all right if player is not used may be is not necessary, I used it for security reasons, if player is not initialiced yet, is posible that upsmon fails?
  11. Hello galzohar, When I created upsmon I had two posibilities when search for buildings, a- search one time for leader and order soldiers to take positions. b- search for near buildings on each soldier. think in a mission with 100 soldiers each of them looking for near buildings each 10 seconds or 5. I think in terms of performance that was only leader that does it. On the other hand may be posible to make a parameter for setting buildings use on eachs upsmon squad so you can parametrice one or two scuads to be more defensive but less than fortify. Or create another role. SEEK for example that patrols but using much more buildings SEEKING for enemies. in terms of programing, SEEK squad would be a MOVE squad but with a percentage of patrolling buildings greater. _buildingdist = 80 instead of 60 Really only patrol if distance to enemy is close enough //If we are close enough patrol in buildings for searching enemies if ((( _wptype != "HOLD" && vehicle _npc == _npc && (random 100) < 90 ) && _npc == vehicle _npc && _dist <= ( _closeenough ))) then { [_npc,_buildingdist,true] spawn MON_moveNearestBuildings; }; }; in SEEK squads will patrol buildings if close enough of _targetdist (distance to destination point) so new code will be like this: if ((( _wptype != "HOLD" && vehicle _npc == _npc && (random 100) < 90 ) && _npc == vehicle _npc && ( _dist <= ( _closeenough ) || ( _targetdist <= _closeenough && _seek )))) then { [_npc,_buildingdist,true] spawn MON_moveNearestBuildings; }; on init of upsmon file get seep parameter: //seek group in near places _seek= if ("SEEK" in _UCthis) then {true} else {false}; if (_seek) then { _nomove="MOVE"; _buildingdist = 80; _wait = 90; }; Rafalski I had troubles with developmen machine, can u try this for me please?
  12. upsmon is much more than a patrol script: http://dev-heaven.net/projects/upsmon/wiki What can AI do with UPSMON?¶ * 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 uses combat formations depending on the situation. 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 does paratroop near objectives if they take an hely, may land too. * 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 positions,AI patrol them when leader thinks that enemy is near or using it. 2. What else can be done with UPSMON?¶ * You can define diferent roles to your squads: o MOVE squads are patrol squads, they moves inside mark and in fight are more agressive. o NOMOVE if no enemies they do not move, in fight tends to hold position. o FORTIFY squads do not move , get defence positions in nearly buildings, and static weapons. * You can do a squad to respawn when entirely squad dead. * You can add UPSMON artillery module for allowing AI to do support artillery fire to known position. * You can set REINFORCEMENT squads and send to battle when you need in your mission. * You can create squads dinamically using the UPSMON spawn module.
  13. Hi demonized, seems that match the condition to search for vehicles, then I can not understand why is getting in again, may be when executing upsmon in the heli joins pilot to group, I think this may be the problem, but if is so with 5.7 would fail too. mmm.. Can you put this lines of code? looks for this in upsmon.sqf: ------------------------ //Search for vehicle if ((!_gothit && _targetdist >= ( KRON_UPS_searchVehicledist )) && _isSoldier && !_noveh) then { if ( vehicle _npc == _npc && _dist > _closeenough ) then { ---------------------------- then add these two lines please and report if executes and the results: player sidechat format["%1: _gothit=%2 _targetdist=%3 _isSoldier=%4",_grpidx, _gothit, _targetdist,_isSoldier]; player sidechat format["%1: _noveh=%2 _dist=%3 _closeenough=%4 _npc=%5",_grpidx, _noveh, _dist, _closeenough, _npc]; Could you mind to test again with 5.0.8 R3 to see if problem persist?, if problem desapear we will search in changes to find the bug.
  14. Hello Demonized, I have been reading your problem and maybe could be solved with settings in init_upsmon parámeters. If I understood well the problem is that when upsmon squad leave transport heli, leader orders soldiers to get in again. Well, the leader orders to get in hely because distance to destination is larger than KRON_UPS_searchVehicledist. Destination point may be patrol point into area marker or nearest known enemy. When under fire should not get in. //Search for vehicle if ((!_gothit && _targetdist >= ( KRON_UPS_searchVehicledist )) && _isSoldier && !_noveh) then { if ( vehicle _npc == _npc && _dist > _closeenough ) then { _unitsIn = [_grpid,_npc] call MON_GetIn_NearestVehicles; The problem is that _targetdist is > KRON_UPS_searchVehicledist, we must evaluate why _targetdist is greater. _targetdist may be distance to patrol point or distance to nearest target. If hely has transported to patrol point this distance should not be greatest unless: a- land point is too far from patrol mark position or b- area to patrol is so bigger. If a, landing position is far than patrol mark try to aproach mark or put a larger value on KRON_UPS_searchVehicledist. If b, patrol area is bigger increase KRON_UPS_searchVehicledist to 1000 or 1200 or reduce area of patrol mark. In any case I think in your case you will solve the proble puting a larger value on KRON_UPS_searchVehicledist. Let me know if this solves your problem and which are the parámeters of your mission. KRON_UPS_searchVehicledist? KRON_UPS_sharedist? how big is area of patrol marker, larger than KRON_UPS_searchVehicledist? units land on patrol mark?
  15. Hi, there is a garbage collector on upsmon, try to put 'delete' param, You can set time to remove dead bodies too. Visit wiki on dev heaven for more info. delete:n = Delete dead units after 'n' seconds. when using spawn script set delete nul = [this,"town","TEMPLATE:",1] execVM "scripts\upsmon.sqf"; nul = [1,position player,1,["town2","respawn","DELETE:",30]] execVM "SCRIPTS\UPSMON\MON_SPAWN.SQF"; this will create a squad like "TEMPLATE" and will set DELETE param on leader, so units will be removed after 30 seconds if no players near. GREAT JOB RAFALSKI!!
  16. Fantastic job Rafalsky, I let you rights on upsmon project so u can work on it. http://dev-heaven.net/projects/upsmon If you need something or have any question, email me to chs.monsada@gmail.com ---------- Post added at 03:56 PM ---------- Previous post was at 03:50 PM ---------- May be this is not the place, but I want to explain why Im out of programing improvements on UPSMON script all that time. I was working on two board games, now Im ready to sell it but I have no sense how to do it. If any forum reader works in a game board editorial or have contacts or money can contact me? Thanks for all, Monsada
  17. You musa use spawned paran to avoid surrender ejem spawning runtime squads nul = [_x, "UPSMON_marker_1", "spawned","random"] execVM "scripts\upsmon.sqf"
  18. Hi, If tou want east to fire you musa use: KRON_UPS_ARTILLERY_EAST_FIRE = true;
  19. Hi alleycat, to force surrendering put the variable you need to true: KRON_UPS_WEST_SURRENDED = true; KRON_UPS_EAST_SURRENDED = true; KRON_UPS_GUER_SURRENDED = true; for any issue you have please register it in devheaven, so I can work on it http://dev-heaven.net/projects/upsmon
  20. are not correct you must put : nul=[this,"m2","reinforcement:",1] execVM "scripts\upsmon.sqf"
  21. Hi all, I will notify that I will retake project in future days. By now I will answer some questions You can set default speed when no enemies known using NOSLOW squad will run, if not specified limited speed will be set ---------- Post added at 11:52 AM ---------- Previous post was at 11:49 AM ---------- Hi Acelondoner, to disabling teleport go to init.sqf in your mission folder, edit it. You will see a line like this onMapSingleClick "player setpos _pos"; Delete it ;) ---------- Post added at 11:57 AM ---------- Previous post was at 11:52 AM ---------- Hi Breeze, Delete lets units of squad being deleted when are dead, if you set time for example "DELETE:",300 bodies that are dead will be removed after 300 seconds. for better knowing the parameters I recomend to see wiki http://dev-heaven.net/projects/upsmon/wiki/UPSMONsqf Sorry I don't understand last question ---------- Post added at 12:02 PM ---------- Previous post was at 11:57 AM ---------- Hi Fideco, Sorry but I don't know about that mods or scripts, UPSMOS try to give AI improved habilities to fight as an army, I recomend you to try it and report your experience. ---------- Post added at 12:07 PM ---------- Previous post was at 12:02 PM ---------- To respawn a entire group when all men are dead is very simple, no triggers, no script, only add parameter RESPAWN or RESPAWN:x nul=[this,"town","nomove","delete:",300,"respawn"] execVM "scripts\upsmon.sqf"; nul=[this,"town","nomove","delete:",300,"respawn:",5] execVM "scripts\upsmon.sqf"; second sample will respawn a maximus of 5 times this squad. For more explanation see: http://dev-heaven.net/projects/upsmon/wiki/UPSMONsqf
  22. general comander is not in any place, is a maner of telling that AI fights together
  23. yes, was kju but, I have no notice of him since then, let me know any notice about new programmer to give him rights in project
  24. Hi all, sorry to all but by now Im working in a new project, i'm doing a game and I have no time. All ideas are welcome and programers are needed, if anyone knows programing and would like to work in UPSMON project is welcome too, I will explain all and give rights for avoiding work will not to be stopped. Rafalsky would you like to do it? you need to create an acount in dev-heaven when you have it tell me in private and will send you rights to UPSMON devheaven-project http://dev-heaven.net/projects/upsmon ---------- Post added at 11:46 AM ---------- Previous post was at 11:40 AM ---------- AI will rest in safe mode if no enemy, well, think that AI will fight as an army with UPSMON so if any unit check enemy will comunicate it. there is a parameter in init_upsmon for setting the distance of comunication, kron_ups_sharedist. If no enemies comunicated AI must be safe. When AI lost enemy or die enemies will return to safe.
  25. This is not right. NOMOVE squads are more agressive when closeenough for example. ---------- Post added at 08:53 AM ---------- Previous post was at 08:45 AM ---------- Negative. UPSMON do not tells to fire. SAMPLES OF USAGE OF KRON_UPS_closeenough: -Is used in formula to set get out dist when in vehicle. -Is used in formula to know if arrived to destination. -Is used in flanking formulas, more close more agressive. - Used for determine when lay mines. - used for determining when is too close to enemy to avoid get in vehicles. - Only close to target buildings are patrolled. - When close to target increased suppress fire manauvers ... As I tell is used in many places for calculations when need to know when is too close from target for doing something. I do not recomend to change this value.
×