Jump to content

Recommended Posts

MCYLvZf.pngCHqqeya.pngP0q5heA.pngBIHI47Q.pngCyc1K9S.jpgNZGePJR.pngoG5JdhS.pngpcGNZEt.png

FTaxdAV.png

GF Auto Loot Road Crash Script - Mod

by

 

GEORGE FLOROS [GR]

 

 

Description:

Spawn Random Road Crash , will detect the enabled Mods , without editing lists,for loot and vehicles.
You are free to do anything but i would like to give me Credits for this!
Simple and easy to use and adapt .
Have Fun !

 


Installation / Usage:

For usage instructions and information of how to use the GF Auto Loot Road Crash Script - Mod please refer to the included documentation and/or example mission.

Place in your mission the files . There is everything included , in the initServer.sqf , to copy paste in your mission.

https://community.bistudio.com/wiki/SQF_syntax
Don't try to open this with the simple notepad.

For everything that is with comment // in front or between /*
means that it is disabled , so there is no need to delete the extra lines.

You can open this ex:
with notepad++
https://notepad-plus-plus.org/

 

ArmA 3 | Notepad ++ SQF tutorial
https://www.youtube.com/watch?v=aI5P7gp3x90

 

and also use the extra pluggins
(this way will be better , it will give also some certain colors to be able to detect ex. problems )
http://www.armaholic.com/page.php?id=8680

or use any other program for editing .

For the Compilation List of my GF Scripts , you can search in:

 

https://forums.bohemia.net/forums/topic/215850-compilation-list-of-my-gf-scripts/

 

BI Forum Ravage Club Owner :
https://forums.bohemia.net/clubs/73-bi-forum-ravage-club/

 


Notes:

Spawn Random Road Crash , will detect the enabled Mods , without editing lists,for loot and vehicles.
There are 4 options available :
1 = Load every Mod + Bohemia Loot , 2 = Load every Mod - No Bohemia Loot ,
3 = Load Bohemia Loot Only , 4 = Custom items only.
Custom arrays can be used as well.
It is possible to spawn normal alive vehicles , with crew or not or just wrecks.
NOTE : The normal vehicles , might also not spawn loot at all , due to the vehicle destuction.
There are Blacklist Zones available , 5 from default and
a safe distanse from players.

It is possible to spawn an Enemy Patrol group , with custom units.
More information inside the GF_Auto_Loot_Road_Crash.sqf
There is also included a mod version , posible to unpack and edit.

 


Credits and Thanks to :

Thanks to All script contributors
Thanks to everyone who tries to do the best for this game!
Thanks to BIS for such a great platform .
Thanks to BIS Community and BIS Community Forums .
Thanks to Armaholic Community and Forums .

 

 

Changelog:

v1.0


Forum topic:
- Armaholic forums http://www.armaholic.com/forums.php?m=posts&q=40354

 

 

Armaholic

GF Auto Loot Road Crash Script - Mod

 

  • Like 3
  • Thanks 1

Share this post


Link to post
Share on other sites

Well if this script production continues all left for the editors will be to create the tasks and the briefings. The mission environment will be ready 👍

  • Thanks 1

Share this post


Link to post
Share on other sites
41 minutes ago, JohnKalo said:

The mission environment will be ready 👍

 

Good to hear this John !

 

I'll be waiting to see your creations !

 

Ps : I think this is only a greek phrase !  :f:

# If everything goes well

Do they english talking countries use it ? Can someone confirm ? - Just curious !

43 minutes ago, JohnKalo said:

if this script production continues all left

 

  • Like 1

Share this post


Link to post
Share on other sites

Rock'n roll!

 

I've been a bit busy last week but did some quick testing and works like a charm, without any errors. Thank you so much once again George!

 

Although one thing came to my mind: It would be nice if mission makers could define an area(s), with 3den markers, where crashes are meant to be spawned. I know there is this "blacklist-markers"-setup, but IMO it would be simpler and easier to do with "spawning-area-marker-thing"... For example, if I want to make some battle scars only in certain city/village and on to the way between this city/village and starting position of the mission.

 

My dev-wishlist in short:

1.Possibility to make area markers for the spawn

2.Possibility to define amount of crashes in area marker

 

You know what I'm trying to say...? 🙂

  • Thanks 1

Share this post


Link to post
Share on other sites
On 2/11/2019 at 10:23 AM, jonipetteri said:

My dev-wishlist in short:

1.Possibility to make area markers for the spawn

2.Possibility to define amount of crashes in area marker

  

You know what I'm trying to say...? 🙂

 

Hello there jonipetteri !

 

I just got out from one whole week in hospital and just logged in ! 

 

It is possible and easy what you want , just in order not to make changes in the actual script , here is what you need to do :

 

after :

line 390 : waituntil {_Array_Loaded};

 

Spoiler

GF_ALC_Spawn = {

private ["_marker","_x","_a","_Pos"];

_x = 0;
_a = 0;	

//________________ Number of the Crashsites	________________

for "_x" from 0 to GF_ALC_Number + random GF_ALC_Number_random do {

_a = _a + 1;

//________________ Find Crashsite Position	________________

_Found = false;
while {!_Found} do {
	_Pos = [] call BIS_fnc_randomPos;
	
	_nearestRoad = [_Pos, 50] call BIS_fnc_nearestRoad;	
	_nearest_House = nearestObject [_Pos, "House"];
	_nearest_Building = nearestObject [_Pos, "Building"];
	
	if (		
	//________________	Add Blacklist Distance from all Players	________________
	(({((_Pos distance _x) <= GF_ALC_Distanse_from_Players)} count GF_ALC_allPlayers) isEqualTo 0)
	
	//________________	Add here your Blacklist Zones ( for more )	________________
	&& ((_Pos distance GF_ALC_Blacklist_Zone_1) > GF_ALC_Blacklist_Zone_distance) 
	&& ((_Pos distance GF_ALC_Blacklist_Zone_2) > GF_ALC_Blacklist_Zone_distance)
	&& ((_Pos distance GF_ALC_Blacklist_Zone_3) > GF_ALC_Blacklist_Zone_distance) 
	&& ((_Pos distance GF_ALC_Blacklist_Zone_4) > GF_ALC_Blacklist_Zone_distance) 
	&& ((_Pos distance GF_ALC_Blacklist_Zone_5) > GF_ALC_Blacklist_Zone_distance) 

	//________________	uncomment to add Distance from _nearestRoad - House - Building	________________
	//	&& ((_Pos distance _nearestRoad) > 50) 
	//	&& ((_Pos distance _nearest_House) > 50) 
	//	&& ((_Pos distance _nearest_Building) > 50) 
	
	) then {
	
	_Found = true;
	
if (GF_ALC_Systemchat_info) then {
systemchat format ["Crashsite Position Found %1",_Found];
};	
		}else{	

	_Found = false;
	
if (GF_ALC_Systemchat_info) then {
systemchat format ["Crashsite Position Found %1",_Found];
};	
	
};
};
	

waituntil {_Found};
	

//________________	crashsite Vehicle	________________

if(GF_ALC_Spawn_Normal_Vehicles ) then {

//________________	Normal_Vehicles	________________

GF_ALC_Vehicle = selectrandom GF_ALC_Vehicle_array;

} else {

//________________	Wrecks	________________

GF_ALC_Vehicle_array = [
	"Plane_Fighter_03_wreck_F",
	"Land_UWreck_Heli_Attack_02_F",
	"Land_Wreck_Heli_Attack_02_F",
	"Land_Wreck_Plane_Transport_01_F",
	"Plane_Fighter_01_wreck_F",
	"Plane_Fighter_02_wreck_F",
	"Plane_Fighter_04_wreck_F"
];

GF_ALC_Vehicle = selectrandom GF_ALC_Vehicle_array;
};


//________________	GF_ALC_Spawn_CraterLong	________________

_CraterLong = createVehicle ["CraterLong", _Pos, [], 0, "CAN_COLLIDE"];


//________________	CraterLong_small	________________ 

if(GF_ALC_Spawn_CraterLong_small) then {

for "_x" from 1 to 2 + random 3 do {
_Pos_Crater_small = _Pos getPos [random 5,random 360];
_Crater_small = createVehicle ["CraterLong_small", _Pos_Crater_small, [], 0, "CAN_COLLIDE"];
};
};

_height_of_drop = 2;
_Vehicle = createVehicle [GF_ALC_Vehicle, _Pos, [], 0, "FLY"];
_Vehicle setPosATL [getPosATL _Vehicle select 0, getPosATL _Vehicle select 1, _height_of_drop];

if (GF_ALC_Spawn_Crew) then {
createVehicleCrew _Vehicle;
};

if(GF_ALC_Spawn_Normal_Vehicles ) then {
_banked = selectrandom [0.50,-0.50];
_Vehicle setVectorUp [_banked,0,0]; //box is banked 90 degrees to the right
};

waituntil{!isNull _Vehicle};
_Vehicle setDamage 0.5 + random 0.5;




//________________	Crater	________________ 

if(GF_ALC_Spawn_Craters) then {

for "_x" from 1 to 3 + random 7 do {
_Pos_Crater = _Vehicle getPos [1 + random 10,random 360];
_Crater = createVehicle ["Crater", _Pos_Crater, [], 0, "CAN_COLLIDE"];
_Crater setdir random 360;
};
};

//________________	Oil_Spill_F	________________ 

if(GF_ALC_Spawn_Oil_Spill) then {

if (GF_ALC_Systemchat_info) then {
	systemchat "Spawn_Oil_Spill";
};

for "_x" from 1 to 3 + random 15 do {
_Pos_Oil = _Vehicle getPos [3 + random 20,random 360];
_Oil = createVehicle ["Oil_Spill_F", _Pos_Oil, [], 0, "CAN_COLLIDE"];
_Oil setdir random 360;

//________________	Smoke and fire attached to Oil_Spill_F	________________ 

if(GF_ALC_Spawn_Smoke_and_Fire_to_Oil) then {

if (GF_ALC_Systemchat_info) then {
	systemchat "Smoke_and_Fire_to_Oil";
};
	
switch (floor random 3) do {
 case 0: {

	_Fire = "#particlesource" createVehicle (getPos _Oil);
	_Fire setParticleClass "SmallDestructionFire";
	_Fire setParticleFire [0.3,1.5,0.1];
	
	_Smoke = "#particlesource" createVehicle (getPos _Oil);
	_Smoke setParticleClass "SmallDestructionSmoke";
	_Smoke setParticleFire [0.3,1.5,0.1];	
	};

 case 1: {

	_Fire = "#particlesource" createVehicle (getPos _Oil);
	_Fire setParticleClass "MediumDestructionFire";
	_Fire setParticleFire [0.3,1.5,0.1];
	
	_Smoke = "#particlesource" createVehicle (getPos _Oil);
	_Smoke setParticleClass "MediumDestructionSmoke";
	_Smoke setParticleFire [0.3,1.5,0.1];	
	};

 case 2: {
 	//	Nothing
	};	
	
};
	
};

};
};

//________________	Smoke and fire attached to vehicle	________________ 

if(GF_ALC_Spawn_Smoke_and_Fire_to_Vehicle) then {

if (GF_ALC_Systemchat_info) then {
	systemchat "Smoke_and_Fire_to_Vehicle";
};

switch (floor random 3) do {
 case 0: {

	_Fire_Veh = "#particlesource" createVehicle (getPos _Vehicle);
	_Fire_Veh setParticleClass "SmallDestructionFire";
	_Fire_Veh setParticleFire [0.3,1.5,0.1];
	_Fire_Veh attachTo [_Vehicle,[0,0,0]];
	
	_Smoke_Veh = "#particlesource" createVehicle (getPos _Vehicle);
	_Smoke_Veh setParticleClass "SmallDestructionSmoke";
	_Smoke_Veh setParticleFire [0.3,1.5,0.1];	
	_Smoke_Veh attachTo [_Vehicle,[0,0,0]];
	};

 case 1: {

	_Fire_Veh = "#particlesource" createVehicle (getPos _Vehicle);
	_Fire_Veh setParticleClass "MediumDestructionFire";
	_Fire_Veh setParticleFire [0.3,1.5,0.1];
	_Fire_Veh attachTo [_Vehicle,[0,0,0]];
	
	_Smoke_Veh = "#particlesource" createVehicle (getPos _Vehicle);
	_Smoke_Veh setParticleClass "MediumDestructionSmoke";
	_Smoke_Veh setParticleFire [0.3,1.5,0.1];	
	_Smoke_Veh attachTo [_Vehicle,[0,0,0]];
	};

 case 2: {

	_Fire_Veh = "#particlesource" createVehicle (getPos _Vehicle);
	_Fire_Veh setParticleClass "BigDestructionFire";
	_Fire_Veh setParticleFire [0.3,1.5,0.1];
	_Fire_Veh attachTo [_Vehicle,[0,0,0]];
	
	_Smoke_Veh = "#particlesource" createVehicle (getPos _Vehicle);
	_Smoke_Veh setParticleClass "BigDestructionSmoke";
	_Smoke_Veh setParticleFire [0.3,1.5,0.1];
	_Smoke_Veh attachTo [_Vehicle,[0,0,0]];
	};

 case 3: {	
	//	Nothing
	};
 
};
};


//________________	Cut the grass around the Crashsites	________________ 

if (GF_ALC_Grass_Cutter) then {

if (GF_ALC_Systemchat_info) then {
	systemchat "Grass_Cutter";
};

for "_x" from 1 to random 4 do {
_Pos_Cutter = _Vehicle getPos [2 + random 10,random 360];
createVehicle ["Land_ClutterCutter_large_F", _Pos_Cutter, [], 0, "CAN_COLLIDE"];
};

};	
		
sleep 2;
_Vehicle setPos _Pos;
_Vehicle setPosATL [getPosATL _Vehicle select 0, getPosATL _Vehicle select 1, _height_of_drop];


//________________	Spawn Loot around the Crashsites	________________ 

if (GF_ALC_Spawn_Loot) then {
		
for "_i" from 1 to GF_ALC_Spawned_Items + random GF_ALC_Spawned_Items_random do {

//________________	Position of the loot at the Crashsite	________________			

_Loot_Pos = _Pos getPos [
			6 + random 20,	//	distance
			random 360	
			];
			
			
//________________	_Loot	________________

private ["_Loot","_Item","_magazines","_Item_magazines","_getText","_Color","_Marker","_Text"];
	
	_Item = selectRandom GF_ALC_cfgArray;
	_getText = getText (configFile >> "cfgVehicles" >> _Item >> "vehicleClass");	
	
	_Loot = createVehicle ["WeaponHolderSimulated",[_Loot_Pos select 0, _Loot_Pos select 1,(_Loot_Pos select 2) +  0.06], [], 0, "CAN_COLLIDE"];	
	_Color = "Default";	//	https://community.bistudio.com/wiki/CfgMarkerColors_Arma_3
	_Text =  "Empty - ERROR";
	
	
	//	https://forums.bohemia.net/forums/topic/193019-can-i-detect-all-pistols-from-cfgweapons/?tab=comments#comment-3072020
	_type = [
	0,1,2,4,16,256,4096,131072,	 //>> "Type"
	101,201,301,302,401,501,601,602,603,604,605,607,611,616,617,620,701,801,901	//>> "ItemInfo" >> "type"
	];	 
	
	if (
	(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") in _type)
	or (getNumber (configFile >> "CfgWeapons" >> _item >> "type") in _type)
	or (getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") in [ 0 , 616 ])
	or (isClass (configFile >> "CfgGlasses" >> _Item))
	or (isClass (configFile >> "CfgMagazines" >> _Item))
	 
	) then {
	
		
switch true do {
	
/*
 //>> "Type"

WeaponSlotPrimary 1
WeaponSlotHandGun 2
WeaponSlotSecondary 4
WeaponSlotHandGunItem 16
WeaponSlotItem 256
WeaponSlotBinocular 4096
WeaponHardMounted 65536
WeaponSlotInventory 131072

//>> "ItemInfo" >> "type"

DEFAULT_SLOT 0

MUZZLE_SLOT 101
OPTICS_SLOT 201
FLASHLIGHT_SLOT 301
BIPOD_SLOT 302
FIRSTAIDKIT_SLOT 401
FINS_SLOT 501
BREATHINGBOMB_SLOT 601
NVG_SLOT 602
GOGGLE_SLOT 603
SCUBA_SLOT 604
HEADGEAR_SLOT 605
FACTOR_SLOT 607
RADIO_SLOT 611
HMD_SLOT 616
BINOCULAR_SLOT 617
MEDIKIT_SLOT 619
TOOLKIT_SLOT 620 //added
VEST_SLOT 701
UNIFORM_SLOT 801
BACKPACK_SLOT 901
*/
	
//________________	Gear	________________

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 101) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorGrey";_Text = "Muzzles";};

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 201) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorGrey";_Text = "Optics";};

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 301) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorGrey";_Text = "Rail Attachments";};
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 302) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorGrey";_Text = "Bipods";};	

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 401) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorYellow";_Text = "FirstAidKit";};
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 501) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlack";_Text = "Fins";};

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 601) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlack";_Text = "BREATHINGBOMB";};

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 602) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlack";_Text = "Nvg";};	
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 603) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlack";_Text = "Goggles";};		
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 604) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlack";_Text = "Scuba";};			
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 605) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorGreen";_Text = "Headgear";};	
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 607) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorGreen";_Text = "Factor";};		
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 611) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorGreen";_Text = "Radio";};	

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 616): {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlue";_Text = "Nvg";};

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 617): {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlue";_Text = "Binocular";};
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 619): {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlue";_Text = "Medikit";};

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 620): {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorBlue";_Text = "Toolkit";};

case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 701) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorKhaki";_Text = "Vests";};
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 801) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorGUER";_Text = "Uniforms";};
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "ItemInfo" >> "type") == 901) : {
	_Loot addBackPackCargoGlobal [ _Item, 1 ];
	_Color = "ColorGUER";_Text = "Backpacks";};
			
case(_getText isEqualTo "Backpacks") : {
	_Loot addBackPackCargoGlobal [ _Item, 1 ];
	_Color = "ColorBrown";_Text = "Backpacks";};
		
case(isClass (configFile >> "CfgGlasses" >> _Item)) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "colorCivilian";_Text = "Glasses";};
	
	
//________________	Weapons	________________
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 1) : {
	_Loot addWeaponCargoGlobal [ _Item, 1 ];
	private _magazines = getArray (configFile >> "CfgWeapons" >> _Item >> "magazines");
	private _Item_magazines = selectRandom _magazines;
	_Loot addMagazineCargoGlobal [_Item_magazines, round (1 + random 2)];
	_Color = "ColorEAST";_Text = "WeaponsPrimary";};

case(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 2) : {
	_Loot addWeaponCargoGlobal [ _Item, 1 ];
	private _magazines = getArray (configFile >> "CfgWeapons" >> _Item >> "magazines");
	private _Item_magazines = selectRandom _magazines;
	_Loot addMagazineCargoGlobal [_Item_magazines, round (1 + random 2)];
	_Color = "ColorPink";_Text = "HandGuns";};
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 4) : {
	_Loot addWeaponCargoGlobal [ _Item, 1 ];
	private _magazines = getArray (configFile >> "CfgWeapons" >> _Item >> "magazines");
	private _Item_magazines = selectRandom _magazines;
	_Loot addMagazineCargoGlobal [_Item_magazines, round (1 + random 2)];
	_Color = "ColorOrange";_Text = "WeaponsSecondary";};

case(isClass (configFile >> "CfgMagazines" >> _Item)) : {
	_Loot addMagazineCargoGlobal [ _Item, round (1 + random 2)];
	_Color = "colorRed";_Text =  "Mags";};
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 4096) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorWEST";_Text = "Items / Objects";};		

case(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 131072) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "ColorWhite";_Text = "Inventory Items";};	
	
case(getNumber (configFile >> "CfgWeapons" >> _item >> "type") == 0) : {
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "colorBLUFOR";_Text = "Inventory Items";};
	
};

	} else {
	
	_Loot addItemCargoGlobal [ _Item, 1 ];
	_Color = "colorBLUFOR";_Text = "Inventory Items";	
	};

	
//________________	GF_ALC_Debug	________________
	
if (GF_ALC_Debug && {!(isNull _Loot)}) then {

	_Marker_Number = format ["%1",_Loot_Pos];
	_Marker = createMarker [_Marker_Number,getpos _Loot];		
	_Marker setMarkerShape "ICON"; 
	_Marker setMarkerType "mil_dot"; 
	_Marker setMarkerColor _Color; 
	_Marker setMarkerText _Text;	
	_Marker setMarkerSize [0.6,0.6]; 		
};			
			
			
};			
};
			
			
//________________	Spawn a Group at the Crashsite	________________

if (GF_ALC_Spawn_Enemy) then {

if (GF_ALC_Systemchat_info) then {
	systemchat "GF_ALC_Spawn_Enemy";
};

_Pos_Spawn =  [[[_Pos, 50 + random 250]],["water"]] call BIS_fnc_randomPos;
_Group = createGroup GF_ALC_Enemy_Side;

for "_x" from 0 to (GF_ALC_Squad_Members + floor random GF_ALC_Squad_Members_random) do {

_unit = _Group createunit [selectRandom GF_ALC_Pool_Infantry,_Pos_Spawn,[],0,"None"];
[_unit] JoinSilent _Group;
(leader _Group) setSkill GF_ALC_set_AiSkill + random GF_ALC_set_AiSkill_random;
};
[_Group,_Pos,GF_ALC_Patrol_distance + random GF_ALC_Patrol_distance_random] call BIS_fnc_taskPatrol;
};


//________________	GF_ALC_Debug	________________
	
if (GF_ALC_Create_Markers) then {

	_Marker_Number_Pos = format ["%1",_Pos];
	_Marker_Pos = createMarker [_Marker_Number_Pos,_Pos];		
	_Marker_Pos setMarkerShape "ICON"; 
	_Marker_Pos setMarkerType "mil_marker"; 
	_Marker_Pos setMarkerColor "ColorYellow"; 
	_Marker_Pos setMarkerText format ["Crashsite : %1",_a];	
	_Marker_Pos setMarkerSize [1,1]; 		
};	


if (GF_ALC_diag_log_info_count_Crashsites) then {
diag_log format ["Crashsites : %1",_a];
};

if (GF_ALC_Systemchat_info_count_Crashsites) then {
systemchat format ["Crashsites : %1",_a];
};


};

};

 

 

So next :

 

ex. 1 : get the markersize , you need to create a marker with the certain size ( this will count only the one size ! )
[getmarkerpos "marker_1",getmarkerSize "marker_1" select 0] spawn GF_ALC_Spawn;

 

ex. 2 : add the radius , just add a marker without adjusting
[getmarkerpos "marker_1",400] spawn GF_ALC_Spawn;

 

Try and tell me because it's not tested , it should be fine though !

 

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

×