Jump to content
Sign in to follow this  
SIXTWO

Need help with A10 bombing, AI suck at flying.

Recommended Posts

Ive searched every inch of the web to mi abilities, so don

t flame me.

Now all i want is to now how to get a A10 to take out a tank straight away.

e.g. Set up tank on runway, setup A10 a few miles away, set him to flying, chuck a destroy waypoint ontop of the tank.

But all the A10 does is shoot a few rounds of it machine gun at in, then fly over it, moments later it turns around does another lap and finally shoots a rocket at him which finally makes the tank go boom boom.

Is there any simple way or a script that can make that darn A10 shoot that tank on its first run, or for those that don't quite get me; i don't want the A10 to drive over the tank, then turn around and shoot him with a rocket, i want him to shoot the tank first then fly over it. :D

Share this post


Link to post
Share on other sites

I can't test this right now, but here is something off the top of my head that you could try:

1. The tank you want to be destroyed needs a name. For the sake of this example, I will call it target. Put the name into the name property field of the tank.

2. Put the following code into the INIT line of the A-10:

_nil = [this, [b]target[/b]] execVM "a10attack.sqf"

3. Create an SQF script file in the mission directory called a10attack.sqf (this script will be called from the init line of the A-10.)

4. Put the following code into the script:

private ["_a10", "_tgt"];

_a10 = _this select 0;
_tgt = _this select 1;

waitUntil {(_a10 distance _tgt) < 1500};

_a10 reveal _tgt;
_a10 doTarget _tgt;
sleep 1;
_a10 fireAtTarget [_tgt, "HellfireLauncher"];

Now, I'm not 100% sure whether the missile launcher on the A-10 is called "HellfireLauncher". If the above code doesn't work, you can check this in a new test mission by putting the following code into the init field of an A-10:

hint format["%1", weapons this]

^^ that code will spit out a list of weapons carried by the plane once you start the game. Look for the name of a launcher type weapon, and put that name into the quotation marks in the script code above.

Share this post


Link to post
Share on other sites

worked like a charm, thank u very much.

but is there anyway to stop the a10 from firing his turret at the tank, he seems to shoot the tank with his

GAU cannons first, then when it gets closer it fires a direct hit missile.

---------- Post added at 04:27 PM ---------- Previous post was at 04:23 PM ----------

EDIT: Oh BTW i think it was "MaverickLauncher" instead of hellfire.

Share this post


Link to post
Share on other sites
worked like a charm, thank u very much.

but is there anyway to stop the a10 from firing his turret at the tank, he seems to shoot the tank with his

GAU cannons first, then when it gets closer it fires a direct hit missile.

You could remove all GAU magazines from the plane, so he can't fire it at all. If you need to find out what the mags are called:

hint format["%1", magazines this]

Similar to the weapons thing above. Once you know what they're called, put the following code into the units init line:

this removeMagazines "[i]NAME_OF_MAGS[/i]"

Share this post


Link to post
Share on other sites

This is a pretty inconsistent thing your working with but I will try.

Give the A-10 a destroy waypoint near the tank and put in it's condition box

!alive tank

Obviously name the tank, I put tank but you can use whatever you want, and name the A-10 with the same name (A10).

put a trigger where the A-10 should start it's attack run and make sure the trigger activates.

In the On activation box, put:

A10 selectWeapon "muzzlename"; A10 doTarget tank; A10 doFire tank

It should work a bit better, but the problem is spotting the tank early, for the "muzzlename" area, put the name of the launcher used for the maverick or whatever you want (can't check cause ArmAholic library is still down, and on the A-10's box, put the skill up to max, that will make it spot the tank earlier.

EDIT: whoops i'm a bit late. :(

Share this post


Link to post
Share on other sites

thanks MadDog,

and sausage, dw ill keap it in mind still, since your version is not in script, and ill use it one day if i can't be bothered writing down a script since im useless at it. :D

Share this post


Link to post
Share on other sites

mine is very basic, but is quick to use.

I usually actually prefer the GAU-8 over the maverick, at least on ACE, because it is fairly reliable and is VERY powerful.

Share this post


Link to post
Share on other sites
mine is very basic, but is quick to use.

I usually actually prefer the GAU-8 over the maverick, at least on ACE, because it is fairly reliable and is VERY powerful.

Also, awesomesauce.

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  

×