Home   Help Search Login Register  

Author Topic: watch that direction and shoot anything that moves  (Read 621 times)

0 Members and 1 Guest are viewing this topic.

Offline twisted

  • Members
  • *
  • I'm a llama!
watch that direction and shoot anything that moves
« on: 22 Sep 2005, 03:16:25 »
i have a script that i want to bring to life. Not a very complicated one, but one that will add a level of team work to SP.

It also could be one of a series of added functionality that can be transplanted into OFP missions.

Basically it's a shoot/cover this direction script. so you tell your guys where to cover and they will madly open up at any enemy in that direction.

i want this as an action of the fire menu (usual key press 3) and to affect only those in my squad i choose. This way i can have 4 guys covering the enemy while the rest advance.

so a step by step break down is...

1) select AI i want to cover via F-keys.

2) press 3 (attack) then another key to choose ‘cover' option. the addaction command would work here it seems to put the command on the middle mouse button menu.

3) Choose from 9 options of where to cover, namely in direction player is facing [getdir] or the 8 compass points [setdir].

4) AI goes prone depending on their stance.  [NAMEOFUNIT SetUnitPos "DOWN"]

5) If AI sees enemy they tell all AI that are part of their cover group where the enemy is. They all then madly open fire at the enemy. They fire even if they have very low chance of hitting enemy (can you do a dofire command on a position shared by AI?). Thing is they must be sort of trigger happy like in real life.  This is where it really differs from the 'watch direction' command. The willingness to fire is increased a lot. *****Is this possible?****  the AI should also keep firing till 5 - 10 seconds after the AI was last seen or killed (depending on number of AI seen)

6) repeat step 5 until another command is given.

I'd even like them to shoot at where they remembered the enemy to be. I know ECP allows AI to share others positions so that may help them aim. *** may be a good way of simulating dynamic suppressing fire later ****

I'd like all of this to work in conjunction with ECP so maybe i can find some way of leveraging the AI info sharing to help my AI to shoot where they remember the enemy to be.

this should be a simple script (except maybe the shoot where you remembered them to be part), but its my first and so I'll be posting my thoughts and learning experience here. Maybe someone will benefit from it. Maybe not. It'll add a lot to SP OFP IMHO.

most importantly i hope to get some help from the smart guys and big names on this board.
« Last Edit: 22 Sep 2005, 09:49:27 by twisted »