Home   Help Search Login Register  

Author Topic: Force AI to RPG vehicles...  (Read 820 times)

0 Members and 1 Guest are viewing this topic.

Offline Garcia

  • Members
  • *
  • Leeds United is the best football team...EVER!
Force AI to RPG vehicles...
« on: 22 Jul 2005, 01:59:11 »
I need a script that forces an AI to fire a RPG at a vehicle...as simple as that...best I managed was to get the AI to fire up in the air...

let's say you got AI 1 with RPG, he's 200 m from vehicle 1. Vehicle 1 may be moving around with ppl in it, or it may be standing there alone and still. So, then AI 1 should grab his RPG, aim at vehicle 1, and fire...no matter if it's moving or not...

Pravit

  • Guest
Re:Force AI to RPG vehicles...
« Reply #1 on: 22 Jul 2005, 04:57:20 »
doTarget and doFire seem to work pretty consistently if the vehicle is friendly or neutral. If it's an enemy, though, you run into the problem of the AI occasionally being too scared to get up and fire at it. Do you need this to happen consistently every time in some kind of cutscene?

Edit: I went to desert island, added one AT guy and one enemy tank. Set the AT guy to setcaptive true and setcombatmode "BLUE" so he wouldn't get shot at or shoot early, then in a trigger told him to dotarget and dofire. He seemed to do it pretty consistently.

Unfortunately, I can't figure out how to force him to fire an RPG at vehicles he considers too small, such as civilian cars.
« Last Edit: 22 Jul 2005, 05:02:47 by Pravit »

Offline Garcia

  • Members
  • *
  • Leeds United is the best football team...EVER!
Re:Force AI to RPG vehicles...
« Reply #2 on: 22 Jul 2005, 05:05:58 »
dotarget and dofire don't work at all, that's the problem...they refuse to weapon the RPG and fire it...

Pravit

  • Guest
Re:Force AI to RPG vehicles...
« Reply #3 on: 22 Jul 2005, 05:18:31 »
Which unit is doing the firing and what is he firing at(what type of vehicle and what side)? What kind of environment is it - is there shooting and enemy soldiers all around, or is he hiding, waiting for a tank to pass by? What do they do instead of using the RPG - do they fire with their rifles or just lie there?
« Last Edit: 22 Jul 2005, 05:18:59 by Pravit »

qqqqqq

  • Guest
Re:Force AI to RPG vehicles...
« Reply #4 on: 22 Jul 2005, 09:03:09 »
Try using selectweapon before dotarget.

Offline Garcia

  • Members
  • *
  • Leeds United is the best football team...EVER!
Re:Force AI to RPG vehicles...
« Reply #5 on: 22 Jul 2005, 13:51:13 »
It's either the rpg2 or rpg7 from nam pack 2, most likely the vehicle will be a manned or unmanned chopper, in a jungle enviroment, and possibly under gunfire, but maybe not...

though, when I tried to make this work, I tested it with rpg2 and rpg7, in open area, no shooting around them, both on empty vehicle with no enemies around, and on a flying chopper, and they just sat there looking stupid...

and selecting weapon doesn't work :-\

Offline Terox

  • Former Staff
  • ****
  • Follow the Sappers!
    • zeus-community.net
Re:Force AI to RPG vehicles...
« Reply #6 on: 22 Jul 2005, 16:36:20 »
a lot of the problems here is config based
and is dependant on the threat assesment that an ai makes of an enemy vehicle, the cost of the weapon he is about to use and the damage calculation that is undertaken.

The simplest workaround is to use an invisible  "target" addon, such as those available in the Bas island and setpos it to the vehicle in question.

These targets have exceptionally hight threats attached to them for all types of vehicles, men, armour and air and consistently draw fire from any units that have weapons available to do damage to them
Excellent way to have gunships fire rockets at ground locations etc

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