Jump to content
peacefull Nation

Spawn Ai Paratroopers over me

Recommended Posts

The easiest: use bis_fnc_spawnGroup :

[(getPos player) vectorAdd [0,0,300], EAST, ["O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup;

 

(in SP no problem, in MP, you need to pay attention on the way you trigger that code, and what player means)

Say you want to add that in a trigger bluFor present or anyplayer...

1 - your trigger must be "server only" check the case.

2 - you need to change the code for:

[(getPos (thisList select 0)) vectorAdd [0,0,300], EAST, ["O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup;

 

You can also change few things like:

Slight randomization for the position:

change the position for (getPos (thisList select 0) vectorAdd [-200 + random 400,-200 + random 400, 300]

 

as you can see I spawned 4 paratroopers . You can spawn any type of unit but add a parachute as backpack!

This need some extra sequence, so it's better and more realistic to add little delays.

First, name the group you created (example of a trigger):

mygrp = [(getPos (thisList select 0)) vectorAdd [-200 + random 400,-200 + random 400, 300]], EAST, ["O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup;

then:

0 = [] spawn {
  {
     _x allowDamage false;
     sleep 0.4;
     _chute = createVehicle ["NonSteerable_Parachute_F", (getPosatl _x), [], 0, "NONE"];
     _chute setPosATL (getPosatl _x);
     _x moveinDriver _chute;
     sleep 0.5; 
     _x allowDamage true;
   } forEach units myGrp;
};

 

Then you can add a waypoint to nearest player, etc.

That's the principle.

You can also spawn an air asset and make your AIs jump from it...

 

 

  • Like 2

Share this post


Link to post
Share on other sites

Google is your friend.  This is a fairly common topic, and googling "Arma 3 AI Paradrop" would have yielded various solutions.  Here's one:

 

 

  • Like 1
  • Haha 1

Share this post


Link to post
Share on other sites

We see you are new... Welcome!

ArmA is a fully customizable game. So, YES, you can literally make anything you ever wanted. Not just scenarios, but actual 3D Game Design with 3rd party professional software. Virtually no limits. If you can dream it, you can build it.

Welcome to your newest addiction. *mwahh ahh ahhh*

  • Like 1

Share this post


Link to post
Share on other sites

is thier a code command i can just paste it and then it just  randomly spawns  over currrent  player location without setting  markers..

or 

a full code i can test  i can just put it in .sqf and run execute that sqf file and it spawns.

 

within the sqf it can have command such as execvm or what ever as long it work  thats all i care , as i am new i just want to se how the code is made and done , i hope am not asking alot , i am only asking for help cause i love it when i se it working just excited with what this game can do ,awesome.

 

the server allows all codes to work even cheats  so am thinking u can come up with a code to make this spawn thing.

Share this post


Link to post
Share on other sites
On 21/10/2017 at 3:51 AM, pierremgi said:

The easiest: use bis_fnc_spawnGroup :

[(getPos player) vectorAdd [0,0,300], EAST, ["O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup;

 

(in SP no problem, in MP, you need to pay attention on the way you trigger that code, and what player means)

Say you want to add that in a trigger bluFor present or anyplayer...

1 - your trigger must be "server only" check the case.

2 - you need to change the code for:

[(getPos (thisList select 0)) vectorAdd [0,0,300], EAST, ["O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup;

 

You can also change few things like:

Slight randomization for the position:

change the position for (getPos (thisList select 0) vectorAdd [-200 + random 400,-200 + random 400, 300]

 

as you can see I spawned 4 paratroopers . You can spawn any type of unit but add a parachute as backpack!

This need some extra sequence, so it's better and more realistic to add little delays.

First, name the group you created (example of a trigger):


mygrp = [(getPos (thisList select 0)) vectorAdd [-200 + random 400,-200 + random 400, 300]], EAST, ["O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup;

then:


0 = [] spawn {
  {
     _x allowDamage false;
     sleep 0.4;
     _chute = createVehicle ["NonSteerable_Parachute_F", (getPosatl _x), [], 0, "NONE"];
     _chute setPosATL (getPosatl _x);
     _x moveinDriver _chute;
     sleep 0.5; 
     _x allowDamage true;
   } forEach units myGrp;
};

 

Then you can add a waypoint to nearest player, etc.

That's the principle.

You can also spawn an air asset and make your AIs jump from it...

 

 

nice i just tested the [(getPos player) vectorAdd [0,0,300], EAST, ["O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup; and wow.

 

now i will check the rest of your code  awesome dood.

Share this post


Link to post
Share on other sites
[(getPos player) vectorAdd [0,0,300], EAST, ["O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup;

i tried adding more troops how ever they fall down the sky and the default ones you already had deploy parachute fine.

here is my modifed code.

[(getPos player) vectorAdd [0,0,300], EAST, ["O_T_Recon_M_F","O_T_Recon_Medic_F","O_T_Recon_TL_","O_T_Sniper_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F","O_Soldier_PG_F"],[],[],[],[],[],180] call BIS_fnc_spawnGroup;

 

Share this post


Link to post
Share on other sites

PG means paratrooper so They already have a parachute (you can see that in the editor if you practice 3den sometimes) .

For all other kind of units, you should read just a little bit more what I wrote. "You can spawn any type of unit but add a parachute as backpack!"

and copy / paste the code for that.

Share this post


Link to post
Share on other sites
1 minute ago, pierremgi said:

PG means paratrooper so They already have a parachute (you can see that in the editor if you practice 3den sometimes) .

For all other kind of units, you should read just a little bit more what I wrote. "You can spawn any type of unit but add a parachute as backpack!"

and copy / paste the code for that.

 

thank u so much for your help sir .

 

i have this now another code  paradrop supply , when it hits ground the ammo gets damaged then deleted.


 

_para = "B_Parachute_02_F";


_vehicle = "B_supplyCrate_F" createVehicle (getPos player);
_vehicle setPosATL (_vehicle modelToWorld[0,0,200]);

        _DropPos1 = getpos _vehicle;

        _Chute1 = createVehicle [_para, _DropPos1, [], 0, "NONE"];

_chute1 attachTo [_vehicle, [0, 0, 1]];

maybe can i some how get a helicopter to drop it off ?

Share this post


Link to post
Share on other sites

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

 

1: how will i  get  ai airplane to come to my location and drop of ai paratroopers.

2: same with question  one but this one with helicopter.

 

i will really appreciate it alot.

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

×