Jump to content


AI targetting & attack type


4 replies to this topic

#1 The Shell

    Amateur

  • Member
  • 117 posts

Posted 02 September 2008 - 17:10

OK, I have set up an enemy AI. It produces Nuke Launchers which then hunt and replaces them when destroyed. I haven't set up attack priorities or object lists so the nuke launcher chooses the nearest unit for its target.

What I need to know is- how do I have the nuke launcher set it's ammo to either conventional nukes or neutron shells depending on the type of target? I know about object lists, attack priorities and the use command button ability but how do I set up scripts that detect the chosen target for shell selection?

Thanks

#2 Dutchygamer

    Shyborg Commander

  • Member Test
  • 1899 posts
  • Projects: Frontline Chaos creator and leader, Invasion Confirmed co-leader

Posted 02 September 2008 - 17:16

That may be very hard too do... I'd suggest looking at the Ranger scripts; he sometimes switches to FB when attacking garrisond structures.
Posted Image

#3 nip

    Grunze-Catz

  • Member
  • 608 posts

Posted 02 September 2008 - 17:52

There is a condition under 'Unit' >>> 'Sighted' that could do the job...

*** IF ***
[???] Unit '???' sees a(n) '???' belonging to Player '???'.
*** THEN ***

Edited by nipthecat, 02 September 2008 - 17:52.


#4 The Shell

    Amateur

  • Member
  • 117 posts

Posted 03 September 2008 - 10:14

Dutchygamer said:

I'd suggest looking at the Ranger scripts
Do you mean AmericaInfantry.ini or in-map scripts?

nipthecat said:

There is a condition under 'Unit' >>> 'Sighted' that could do the job...

*** IF ***
[???] Unit '???' sees a(n) '???' belonging to Player '???'.
*** THEN ***
The 'unit sighted' scripts only apply to those in sight of the nuke launcher not its chosen target but I think if I use this with attack priorities, it will work. However the nuke launcher will probably attack units on the edge of its sight range and so wander in range of base defenses.

#5 JJ

    Half dead member

  • Project Leader
  • 3294 posts
  • Projects: Real life things, personal RA3 mod

Posted 04 September 2008 - 09:53

Put it as a generic script, not 'Unit' >>> 'Sighted'.

Edited by JJ_, 04 September 2008 - 09:53.




3 user(s) are reading this topic

0 members, 3 guests, 0 anonymous users