Home   Help Search Login Register  

Author Topic: Getting the AI to fire LAWs/RPGs at neutral objects  (Read 1014 times)

0 Members and 1 Guest are viewing this topic.

Oberleutnant35

  • Guest
Getting the AI to fire LAWs/RPGs at neutral objects
« on: 07 Nov 2005, 08:43:43 »
All I need to do is get the AI foot soldiers to fire a LAW or RPG at say, an empty car.

Shouldn't be that tough, right?  Looked all about and found many others with the same problem... but no answers!

I can get the AI to target the said car and blast away with small arms (including hand grenades).  But I can only get them to fire their LAWs and RPGs straight up into the air... which isn't particularly helpful!    :o

Here's what I've got so far...

(This one has the loon equipping his LAW launcher only to put it back up without actually firing any LAW rounds.  He then commences to fire on the car with his M16):

LAWMan doTarget _car
~.5
LAWMan selectWeapon "LAWLauncher"
LAWMan playmove "Weapon"
LAWMan dofire _car

(And this one has him fire one LAW round at the moon):    ???

LAWMan doTarget _car
~.5
LAWMan selectWeapon "LAWLauncher"
LAWMan playmove "Weapon"
LAWMan fire ["LAWLauncher","LAWLauncher"]

Any ideas?  Thanks is advance!


Offline Trapper

  • Honoured Contributor
  • ***
  • I'm a llama!
Re:Getting the AI to fire LAWs/RPGs at neutral objects
« Reply #1 on: 07 Nov 2005, 11:16:08 »
Remove magazines and handgrenades and try your first idea again.

Dagon

  • Guest
Re:Getting the AI to fire LAWs/RPGs at neutral objects
« Reply #2 on: 07 Nov 2005, 11:28:01 »
I'll be uploading my workaround so you can take a look at it in a minute, if you like.

Dagon

  • Guest
Re:Getting the AI to fire LAWs/RPGs at neutral objects
« Reply #3 on: 07 Nov 2005, 11:37:39 »
Note that this while this will work on "soft" vehicles, it won't work on human targets.

OFP's loons are apparently hague convention obeying boyscouts. Damn.

If I was more scriptwise I'd change the script to simply do a logic test to find all ammos of not the "LAWlauncher" type and remove them, but since I'm not, I won't. -_-.

Offline Terox

  • Former Staff
  • ****
  • Follow the Sappers!
    • zeus-community.net
Re:Getting the AI to fire LAWs/RPGs at neutral objects
« Reply #4 on: 07 Nov 2005, 17:15:41 »
the use on an invisible target addon would be helpful here, such as the ones in the bas island pack

these targets come as infantry, armour, IR etc so using the correct invis target will cause the ai to react with the correct weapon.

Zeus ARMA2 server IP = 77.74.193.124 :2302
Teamspeak IP = 77.74.193.123

Oberleutnant35

  • Guest
Re:Getting the AI to fire LAWs/RPGs at neutral objects
« Reply #5 on: 08 Nov 2005, 09:03:44 »
Thanks!  Tried out removing ammo and the BAS invisible targets and both ways do the trick.  ;D

Of course, neither are as nice as if there were a simple "fire rpg at object X regardless of ammo" but hey, I ain't complaining!

Anyone know the difference between "Armour" and "Heavy" BAS invisible targets?  I'm assuming "Laser" has something to do air attacks?


Offline Terox

  • Former Staff
  • ****
  • Follow the Sappers!
    • zeus-community.net
Re:Getting the AI to fire LAWs/RPGs at neutral objects
« Reply #6 on: 08 Nov 2005, 15:39:55 »
following configs are identiocal almost to the bas configs

   class WGL_Target_EHvy:WGL_Target
   {
      side=0;
      scope=2;
      displayName="East Heavy Invis Target";
      threat[]={1,1,1};
      armor=1500;
      irtarget=1;
   };
   


class WGL_Target_EArm:WGL_Target
   {
      side=0;
      scope=2;
      displayName="East Armour Invis Target";
      threat[]={1,1,1};
      armor=500;
   };

Zeus ARMA2 server IP = 77.74.193.124 :2302
Teamspeak IP = 77.74.193.123