Jump to content
dlegion

praetorian 1c AAA turret question

Recommended Posts

hello guys, i tried everything, but really cant get how swithc side for turrets !
i need to make praetorian 1c AAA turret OPFOR, shooting to BLU and GREEN factions!
thanks for any help !

Share this post


Link to post
Share on other sites

Spawn it on OPFOR side with BIS function, like this:

 

[_position, 0, _vehicle, _side] call bis_fnc_spawnvehicle;

Where _vehicle is the classname of the turret and _side is EAST.

 

BIS_fnc_spawnVehicle

Share this post


Link to post
Share on other sites

thanks man!
something like this?...dont work, i probably have error in the code :(

[getpos t01, 0, B_AAA_System_01_F, EAST] call bis_fnc_spawnvehicle;

Share this post


Link to post
Share on other sites

i found the mistake, missing  " " !

[getpos t01, 0, "B_AAA_System_01_F", EAST] call bis_fnc_spawnvehicle;     <<== this works!

now another question (plz forgive me, but its essential !) :  i have to put code in init line of the turret, any way to name the turret / or do it in some other way  ?
thanks !

-----EDIT-----
and...i need to make it shoot to infantry too! any way to do it ?

Share this post


Link to post
Share on other sites
9 hours ago, dlegion said:

i found the mistake, missing  " " !

[getpos t01, 0, "B_AAA_System_01_F", EAST] call bis_fnc_spawnvehicle;     <<== this works!

now another question (plz forgive me, but its essential !) :  i have to put code in init line of the turret, any way to name the turret / or do it in some other way  ?
thanks !

-----EDIT-----
and...i need to make it shoot to infantry too! any way to do it ?

 

The turret will automatically engage ground targets once it detects them.

Share this post


Link to post
Share on other sites

eh...in my tests in the editor, seems that it shoots to all air and ground vehicles, but not on foot soldiers !
...and still cant find a way to put some code in the init spawning it by script :(

Share this post


Link to post
Share on other sites
_AA = [getpos t01, 0, "B_AAA_System_01_F", EAST] call bis_fnc_spawnvehicle;
_AA allowdamage false; <---- use _AA instead of this for anything you wish to init on the spawned object.

or e.g removing weapons from the cargo of it

_AA = [getpos t01, 0, "B_AAA_System_01_F", EAST] call bis_fnc_spawnvehicle;
clearweaponcargo _AA;
clearitemcargo _AA;

 

Share this post


Link to post
Share on other sites

awesomeeeee!! huge thanks !!
will try it tonight !!!
really thanks man !

Share this post


Link to post
Share on other sites

tried now....the method works perfectly.....but for some unclear reason allowDamage returns an error!
i tried and retryed, readed biki infos about allowDamage, all seems ok but the editor returns an error, and in fact it does take damage! mah !
 

Share this post


Link to post
Share on other sites

Why on earth did they not just give both the carrier and the new statics availability for all sides if not literally at least group-able? Why would they make it different than any other static available? Can take any other launcher or static and unit and just group it to a non probable opfor and voila its opfor no wasted time coding in when not necessary. This was a foreseeable request instantaneously, from a game creator that knows that people will always want to mod and utilize every bite of usable content they can to their own design and imaginative design. a cement ceiling so to say

If you just need a one time setup you can actually place the turret as empty and then somehow(for whatever reason) place an opfor unit inside it (for example) and it will take the side of opfor, any unfriendly infantry will shoot at the turret until they are out of ammo unfourtuanlty so no ai foot solders if you plan to do that.
 :icon_bash:

Edited by mechanical
clarification / testing yielded a result

Share this post


Link to post
Share on other sites

Just the information I needed.

 

However to get spawned objects as a variable you need to do:

_aaArray = [getpos t01, 0, "B_AAA_System_01_F", EAST] call bis_fnc_spawnvehicle;
_aa = _aaArray select 0;

// Now the allowDamage command will work.
_aa allowDamage false;

Interestingly in a brief bit of testing when the Praetorian gun is an Eden placed BUEFOR turret it responds quicker to shooting down OPFOR helicopters than the other way around.  S

 

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

×