Jump to content
Sign in to follow this  
Fireball

Insurgency

Recommended Posts

There is no "official" Arma 3 version in the works. Grab the A2 version and knock yourself out!

uninstalled arma 2

Share this post


Link to post
Share on other sites
uninstalled arma 2

Porting a mission to Arma 3 does not require an Arma 2 installation.

Share this post


Link to post
Share on other sites
I'm working on something inspired to the old insurgency for A3, but completely re-written and with some new gameplay features. I think it could take some more times, but if someone wants to help me testing it and suggest new ideas PM me!

This is gonna be good! Hail BTC!

Share this post


Link to post
Share on other sites
Porting a mission to Arma 3 does not require an Arma 2 installation.

thought you were talking about booting up a2

Share this post


Link to post
Share on other sites
I'm working on something inspired to the old insurgency for A3, but completely re-written and with some new gameplay features. I think it could take some more times, but if someone wants to help me testing it and suggest new ideas PM me!

PM sent

Share this post


Link to post
Share on other sites

Hi there buddy It is possible to have a main base in insurgency. You just need to do this:

go to this file: initservercommon.sqf and find these lines:

_pos = randPos;

while { count (_pos isFlatEmpty [30,0,0.2,20,0,false,objNull]) == 0 || getTerrainHeightASL _pos <= 2 } do {

_pos = randPos;

};

HQ setDir (((CENTERPOS select 0) - (_pos select 0)) atan2 ((CENTERPOS select 1) - (_pos select 1))+90);

HQ setPosATL _pos;

waitUntil { !isDead(HQ) };

As you can see the named object HQ is fixed above terrain level at _pos.

That means the HQ vehicle set in the map (2d editor) is going to be "pulled" to a random position along the map.

First things first.

Create ur customized main base! anywhere you want. place static defenses, respawnable vehicles, create facilities and services. (Im assuming you know how)

Then, lets bring the magic.

in the editor, create an empty default marker and name it as you want. (e.g. hq, notice the minors not capital letters)

then go back to the script file above.

and do this:

//_pos = randPos;

//while { count (_pos isFlatEmpty [30,0,0.2,20,0,false,objNull]) == 0 || getTerrainHeightASL _pos <= 2 } do {

// _pos = randPos;

//};

//HQ setDir (((CENTERPOS select 0) - (_pos select 0)) atan2 ((CENTERPOS select 1) - (_pos select 1))+90);

//HQ setPosATL _pos;

HQ setposATL (getmarkerpos "hq");

waitUntil { !isDead(HQ) };

WHY THE // symbols?

the // comment lines are used to "disable" or "avoid" reading.

As you can see, im not erasing or deleting any line of the original script. It is just "commented". and replaced by other instructions.

These "new" (old threaded method) lines will make the vehicle named HQ to move to a detrmined position at the marker you have just placed before.

Now go and enjoy your main base!

---------- Post added at 02:39 ---------- Previous post was at 02:34 ----------

Anybody have an idea about this?

Hi there buddy It is possible to have a main base in insurgency. You just need to do this:

go to this file: initservercommon.sqf and find these lines:

_pos = randPos;

while { count (_pos isFlatEmpty [30,0,0.2,20,0,false,objNull]) == 0 || getTerrainHeightASL _pos <= 2 } do {

_pos = randPos;

};

HQ setDir (((CENTERPOS select 0) - (_pos select 0)) atan2 ((CENTERPOS select 1) - (_pos select 1))+90);

HQ setPosATL _pos;

waitUntil { !isDead(HQ) };

As you can see the named object HQ is fixed above terrain level at _pos.

That means the HQ vehicle set in the map (2d editor) is going to be "pulled" to a random position along the map.

First things first.

Create ur customized main base! anywhere you want. place static defenses, respawnable vehicles, create facilities and services. (Im assuming you know how)

Then, lets bring the magic.

in the editor, create an empty default marker and name it as you want. (e.g. hq, notice the minors not capital letters)

then go back to the script file above.

and do this:

//_pos = randPos;

//while { count (_pos isFlatEmpty [30,0,0.2,20,0,false,objNull]) == 0 || getTerrainHeightASL _pos <= 2 } do {

// _pos = randPos;

//};

//HQ setDir (((CENTERPOS select 0) - (_pos select 0)) atan2 ((CENTERPOS select 1) - (_pos select 1))+90);

//HQ setPosATL _pos;

HQ setposATL (getmarkerpos "hq");

waitUntil { !isDead(HQ) };

WHY THE // symbols?

the // comment lines are used to "disable" or "avoid" reading.

As you can see, im not erasing or deleting any line of the original script. It is just "commented". and replaced by other instructions.

These "new" (old threaded method) lines will make the vehicle named HQ to move to a detrmined position at the marker you have just placed before.

Now go and enjoy your main base!

Share this post


Link to post
Share on other sites

maybe you should just wait your turn or post your problem here....and not both. gl with your problem!

Share this post


Link to post
Share on other sites

I am in the process of editing the ACE Zargabad mission and I'm running into a few problems.

I've been up way too long and I'm finding it difficult to put my questions into something that resembles sense, so I'll start off with a few (hopefully) simple questions. I apologise in advance.

I have made my own base and followed ArtMayer_MX instructions. Works great!

Deleting the HQ (uppercase) means no enemies spawn on the map. Can I just place it way out in the desert or does it need to be in my base?

Do all the caches spawn at the same time or does the second cache spawn after the first cache is destroyed?

Is it possible to swap the enemy dropping a suitcase for a Notebook or EvMap?

Having to search the bodies for these items would be even better. I reckon that would be a problem with the Garbage Collector though, right?

That's it for now. I hope I made sense and didn't miss something in the previous posts.

I'll be back for more help once my brain starts working... good.

Cheers.

Edited by Maff

Share this post


Link to post
Share on other sites
Deleting the HQ (uppercase) means no enemies spawn on the map. Can I just place it way out in the desert or does it need to be in my base?

Pay close attention to the details in Art's post (edited):

go to this file: initservercommon.sqf and find these lines:

_pos = randPos;
while { count (_pos isFlatEmpty [30,0,0.2,20,0,false,objNull]) == 0 || getTerrainHeightASL _pos <= 2 } do {
_pos = randPos;
};
HQ setDir (((CENTERPOS select 0) - (_pos select 0)) atan2 ((CENTERPOS select 1) - (_pos select 1))+90);
HQ setPosATL _pos;
waitUntil { !isDead(HQ) };

In the editor, create an empty default marker and name it as you want (e.g. "hq")

then go back to the script file above and do this:

//_pos = randPos;
//while { count (_pos isFlatEmpty [30,0,0.2,20,0,false,objNull]) == 0 || getTerrainHeightASL _pos <= 2 } do {
// _pos = randPos;
//};
//HQ setDir (((CENTERPOS select 0) - (_pos select 0)) atan2 ((CENTERPOS select 1) - (_pos select 1))+90);
//HQ setPosATL _pos;
HQ setposATL (getmarkerpos "hq"); // <-- NOTE THAT THIS LINE IS CHANGED
waitUntil { !isDead(HQ) };

Place that marker wherever you want. I usually move it well outside the terrain's borders.

Do all the caches spawn at the same time or does the second cache spawn after the first cache is destroyed?

All caches spawn at mission init.

Is it possible to swap the enemy dropping a suitcase for a Notebook or EvMap?

Yes. In the following files/lines, change "Suitcase" to whatever class name you desire (E.G. "EvKobalt", "EvMoscow", "EvMap", "EvPhoto", "Laptop_EP1", etc). You could theoretically have an array of intel objects that drop at random, though I have never tried to implement such.

...\common\client\AI\functions.sqf

Line 160:      _case = createVehicle [''''suitcase'''', %4, [], 0, ''''None''''];

...\common\client\misc\functions.sqf

Line 23:      _cases = nearestObjects[getPosATL player,["suitcase"], 3];

...\common\server\cleanup\functions.sqf

Line 9:      if (typeOf _x == "Suitcase") exitWith { deleteVehicle _x; };
Line 17:      } forEach nearestObjects[centerPOS,["CraterLong","Suitcase","WeaponHolder","ReammoBox","AllVehicles","Land_fortified_nest_small_EP1"],AORADIUS];

Having to search the bodies for these items would be even better. I reckon that would be a problem with the Garbage Collector though, right?

It would take significant recoding of an already complex bit of work.

Share this post


Link to post
Share on other sites

Hi, I have ported the insurgency 1.50 to Sangin island (Helmand Province), check it out here: http://www.armaholic.com/page.php?id=27228

idwgprs_3.jpg

Operation Moshtarak:

Insurgency in Marjah



by

Pogoman & Fireball & Kol9yN

ported by Churrofighter

Description:

Search and destroy all insurgent ammo caches. The number of destroyed caches can be checked using the radio.

Insurgency is based off the game mode created by the Project Reality team.

Target is to find and blow up all weapons caches. In order to pinpoint the weapon caches, one needs to evaluate intelligence dropped from killed insurgents. While the BLUFOR team advances through the villages, and towns, clearing out armed insurgents, the squares will go from red to green, marking that the area has been cleared and safe.

OPFOR players can spawn into enemy AI units to make the task of BLUFOR a mayhem.

Features:

  • Join In Progress
  • Dynamic number of enemies: One can set a mission parameter to disable or double the amount of enemy infantry or enemy vehicles. However, the number of possible enemies depends on players currently playing on the server.
  • ACE Settings: Change viewdistance dialog
  • IEDs covering the whole map
  • ACE Wounds: Medics are required for Medikits and Full Heal in the field is enabled.
  • RTO can request fixed-wing CAS
  • Squad Leader can request artillery support.
  • Commander can deploy an RQ-9 Reaper for battlefield observation.
  • Pilots and Crewmans can recruit IA.
  • View settings: H.

Slots:

It has 32 player slots featuring a Marine Expeditionary Unit:

Chaos-6 (Command and control)

Commander -

RTO/2IC -

Hitman-1 (Infantry)

Platoon Leader -

Automatic Rifleman -

Corpsman -

Rifleman (M1014)-

Grenadier -

Rifleman AT (SMAW)-

Hitman-2 (Infantry)

Platoon Leader -

Machinegunner -

Corpsman -

Rifleman (M72)-

Grenadier -

Designated Marksman -

Bravo-2 (Infantry)

Platoon Leader -

Automatic Rifleman -

Corpsman -

Rifleman (M1014) -

Grenadier -

Rifleman AT (FGM-148) -

Raptor-3 (Infantry)

Platoon Leader -

Machinegunner -

Corpsman -

Rifleman (M72) -

Mortar Gunner -

Mortar Assistant-

Whiskey-4-1

Pilot -

Whiskey-4-2

Pilot -

Whiskey-4-3

Pilot -

Hammer-5

Commander -

Gunner -

required_addons.png

- Advanced Combat Environment 2

- Community Base Addons

- A.C.R.E - Advanced Combat Radio Environment

- Sangin Province Hellmand

Share this post


Link to post
Share on other sites

Looks a little different from the one in the A2 m29 version:

init = "this addAction [""Halo Jump"",""mps\action\mps_halo.sqf""]

mps_halo.sqf

// Code Parts by ArmA Community
// Adapted by EightySix

private["_timer","_height"];

if( isNil "mps_halo_limitation") then { mps_halo_limitation = 0; };

if(mps_halo_limitation > 6) exitWith { hint "Halo Not Available"; };

if(isNil "mps_halo_time") then { mps_halo_time = time - ( mps_halo_limitation * 601 ); };

if( ( ( mps_halo_time - time )* -1) <= ( mps_halo_limitation * 600 ) && mps_halo_limitation > 0 ) exitWith { hint format["Halo Not Available for %1mins", ceil( ( mps_halo_limitation * 600 + ( mps_halo_time - time ) ) / 60) ]; };

haloed = true;

_timer = 20;

mps_jumpgrp = [];

104 cutText ["Click on the map where you'd like to HALO jump.","PLAIN DOWN",5];

onMapSingleClick "

if(player == leader (group player) ) then { { if ( !(isPlayer _x) && _x distance player < 100 ) then { mps_jumpgrp = mps_jumpgrp + [_x]; }; }forEach (units (group player)); };

player setPos [_pos select 0, _pos select 1, 1500];

[player, 1500] exec 'ca\air2\halo\data\Scripts\HALO_init.sqs';

haloed = false;

104 cutText ['Close the map and don''t forget to open your chute!','PLAIN DOWN',5];

";

while { haloed && _timer > 0 } do { sleep 1; _timer = _timer - 1; };

onMapSingleClick "";

sleep(1); 104 cutText ["","PLAIN DOWN",0];

if !(haloed) then {

if(player == leader (group player) && count mps_jumpgrp > 0 ) then {

{

_unk = [position player,random 360,(20 + random 90),true,1] call mps_new_position;

_x setPos [_unk select 0,_unk select 1, 1500];

if(mps_ace_enabled) then {

[_x,1500] execVM (mps_path+"func\mps_func_halo_ai.sqf");

}else{

[_x,1500] exec (mps_path+"func\mps_func_halo_ai.sqs");

};

}forEach mps_jumpgrp;

};

_height = (position player) select 2;

while {_height > 50} do {

_height = (position player) select 2;

hintsilent format["Height: %1m\nPull at minimum 180m",round _height];

sleep 0.125;

};

hintsilent "";

mps_halo_time = time;

}else{

hint "Halo Expired";

};

mps_func_halo_ai.sqs

_HALOunit = _this select 0
_waypointreached = 0

_chuteopeningaltitude = 150 + (random 100);

_speed = 70

_HALOunit switchMove "HaloFreeFall_non"

_HALOunit allowdammage false;

#loop

~0.001

;// Conditions to continue the loop

? (alive _HALOunit) && (vehicle _HALOunit == _HALOunit) && (position _HALOunit select 2 > _chuteopeningaltitude) : goto "loop"

;// Run Parachute AI script

[_HALOunit] exec "ca\air2\halo\data\Scripts\HALO_Parachute.sqs"

exit

mps_func_halo_ai.sqf

private["_para_unit","_chuteopeneningaltitude","_vehicle","_pos"];

_para_unit = _this select 0;

if(_para_unit == player) exitWith{};

_chuteopeningaltitude = 150 + (random 100);

_para_unit switchMove "HaloFreeFall_non";

while { alive _para_unit && vehicle _para_unit == _para_unit && ( (position _para_unit) select 2) > _chuteopeningaltitude } do { sleep 1; };

_vehicle = createVehicle ["BIS_Steerable_Parachute", position _para_unit,[],0,"FLY"];

_pos = [position _para_unit select 0, position _para_unit select 1, (position _para_unit select 2)];

_vehicle setPos _pos;

_para_unit moveInCargo _vehicle;

_vehicle setVelocity _vel;

_para_unit setVelocity _vel;

[_vehicle, _para_unit] execVM "ca\air2\halo\data\Scripts\Parachute_AI.sqf";

waituntil { ((position _vehicle) select 2) < 2};

deleteVehicle _vehicle;

if(true)exitWith{};

Share this post


Link to post
Share on other sites

im not sure it its this particlar script but the one in Domination requires you to hold the mouse button for two seconds straight for the helo to kick in?

Share this post


Link to post
Share on other sites

Halo jumping should be a standard function for all missions i think. But i never tried to implement it myself.

-You only swapped the classname in the mission.sqm right, so the init field will stay unchanged? Maybe the units are part of a bigger array group (multi array) or script that eventually teleports them to their final destination. So you could check each init and description etc. and if not in there maybe all other arrays that run on mission start?

Share this post


Link to post
Share on other sites
Halo jumping should be a standard function for all missions i think. But i never tried to implement it myself.

I implemented HALO jumping in my Warfare mission, and he's doing it right. But I seem to recall seeing messages in Steam from people not being able to call HALO, and IIRC it had to do with them running OA without A2. The Halo script being called is from A2. OA has a different Halo available, however if you're running CO you can still use the A2 Halo.

Like I said, I adapted it. The problem seems to be on the map click.

---------- Post added at 19:46 ---------- Previous post was at 19:18 ----------

it's either the onmapclick or the set/get pos

I tested your script exactly as you posted it, using a clean map and an ammo box as the addAction object. Worked perfectly. I don't think the problem lies with the script. If you've got A2 included, I don't know what to tell you other than something external to the script must be bugging it.

Share this post


Link to post
Share on other sites

Just curious, has anyone made a 1.50 Insurgency conversion for Hazar-Kot? Preferably one that's fully ACE-compatible. I tried using the 1.50 Insurgency Zargabad (with ACE) and porting it but it just seems to crash when I start the mission.

Is there anything I need to keep in mind when converting the mission for other maps in order to make it work?

Edit: Ah, haha, nevermind, it just crashed when I tested it in the editor, exporting it and then running it works fine.

Edited by McNools

Share this post


Link to post
Share on other sites

I have a bunch of 1.50 ACE ports (can't recall if Hazar is one of them...don't think so). PM me if anyone wants a copy.

Lingor (using Lingor cops vs drug lords.. bad guys even drop coke instead of suitcases)

NGS Capraia

Caribou Frontier

Fata (playable as ACE Russians)

a few others...

Share this post


Link to post
Share on other sites

If anyone wants the ACE Insurgency I made for Hazar-Kot (with a few extra patrols and whatnot) you could send me a PM aswell, if I still have it then.

Anyway,I have another question, is there any way to exclude areas from spawning enemies? (not just specific buildings, but whole areas of buildings). I wanted to make an insurgency mission for Aliabad, but there are so many buildings here and there, and it gets quite repetive and somewhat silly when there are enemies spawning in every single little village and farm, it would be more interesting if I could exclude some areas (and possible make it random which areas aswell).

Share this post


Link to post
Share on other sites

I can't recall a way of doing that myself but it's been a while since I've fiddled with Insurgency... perhaps Harzach will have an idea and post.

Share this post


Link to post
Share on other sites
Anyway,I have another question, is there any way to exclude areas from spawning enemies?

First, thank you so much for all of the stellar work you have done for the Arma community.

Assuming you haven't dug up this info yet:

Place a marker centered on your chosen exclusion area. Name it "exclude_location" or whatever makes sense to you.

In common\functions.sqf, locate the findhouses function and change it to:

findHouses = { 
   private ["_buildings","_minPositions","_enterables","_alive"];
   _buildings = nearestObjects [_this select 0, ["House"], _this select 1]; 
   _minPositions = (_this select 2) - 1;
   _alive = _this select 3;

   _enterables = [];     
   { 
       if (
           format["%1", _x buildingPos _minPositions] != "[0,0,0]" 
       && EP1HOUSES 
       && !(typeOf _x in ILLEGALHOUSES) && (alive _x || !_alive) && (_x distance (getmarkerPos "exclude_location") > 100 //THIS IS THE LINE WE ARE EDITING
       )) then { 
           _enterables set [count _enterables, _x]; 
       }; 
   } forEach _buildings; 
   _enterables
};  

The ">100" is the radius of effect from the marker you placed. Obviously, you can change this to whatever value suits your particular situation, from very small (to exclude specific buildings) to very large (to exclude airports, for example).

To add another exclusion area, just add another marker and name it appropriately, then add it to line 19 (the default line):

&& !(typeOf _x in ILLEGALHOUSES) && (alive _x || !_alive) && (_x distance (getmarkerPos "exclude_location") > 600) && (_x distance (getmarkerPos "exclude_location_1") > 100)

It should be a relatively simple matter to randomize, by moving an existing or dynamically created set of exclusion markers to randomly selected locations (which could be determined either manually or dynamically), as long as the markers find their way into common/functions as above.

[Original solution provided by Cuel]

Share this post


Link to post
Share on other sites

People still post here looking for help with the A2 version, the actual focus of this topic. Why close it?

Share this post


Link to post
Share on other sites
People still post here looking for help with the A2 version, the actual focus of this topic. Why close it?

You've got a point there. Let's leave it here - it won't be supported anymore though.

Share this post


Link to post
Share on other sites

No worries Harzach and I will hold down the fort :p

Thanks for all your work/help on the A2 version Fireball.

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
Sign in to follow this  

×