Is it possible to make AI controlled recon droid?

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
DrDrSheldonLeeCooper
Chief Warrant Officer
Chief Warrant Officer
Posts: 353
Joined: Sat Apr 26, 2014 1:50 pm
Projects :: Times before Empire
Games I'm Playing :: SWBF2-BF-Skyrim
xbox live or psn: No gamertag set
Location: Coruscant City [Germany]

Is it possible to make AI controlled recon droid?

Post by DrDrSheldonLeeCooper »

Is it possible to make an AI controlled recon droid?
For example,you place the recon droid then it flies arround the map and kills droids/clones etc. for you.
Is it possible?
THEWULFMAN
Space Ranger
Posts: 5557
Joined: Tue Aug 17, 2010 3:30 pm
Projects :: Evolved 2
Location: Columbus, Ohio
Contact:

Re: Is it possible?

Post by THEWULFMAN »

(Cut unhelpful image) ~[RDH]Zerted

Oh god how Marth and I wish.

Hover vehicles, like recon droids, can't be AI controlled. It crashes the game. You can have AI controlled flyers, AI controlled walkers, but AI controlled hovers will cause a CTD.
razac920
2nd Lieutenant
2nd Lieutenant
Posts: 365
Joined: Sun Jan 16, 2011 12:42 am

Re: Is it possible?

Post by razac920 »

You could try spawning an allied local unit next to you when you deploy a controllable? Though I don't know how similar you can make a unit class to a remote droid.
THEWULFMAN
Space Ranger
Posts: 5557
Joined: Tue Aug 17, 2010 3:30 pm
Projects :: Evolved 2
Location: Columbus, Ohio
Contact:

Re: Is it possible?

Post by THEWULFMAN »

razac920 wrote:how similar you can make a unit class to a remote droid.

I tried that.

Once.


There's a whole host of issues.
razac920
2nd Lieutenant
2nd Lieutenant
Posts: 365
Joined: Sun Jan 16, 2011 12:42 am

Re: Is it possible?

Post by razac920 »

What issues? That video seems to show functionality, albeit with weird camera effects, scary music, and ridiculous numbers.
THEWULFMAN
Space Ranger
Posts: 5557
Joined: Tue Aug 17, 2010 3:30 pm
Projects :: Evolved 2
Location: Columbus, Ohio
Contact:

Re: Is it possible?

Post by THEWULFMAN »

Well #1 is that AI have a horrible time aiming at them. The AI clones would aim at what would be waist level on a normal sized unit, while the recon droid was 3x smaller than that.

Issue #2 is the AI recon droids don't use their jetpacks as automatically as I want, which I could circumvent entirely by simply modeling them in a way that makes them look like they're hovering, but this would ruin collision completely.
razac920
2nd Lieutenant
2nd Lieutenant
Posts: 365
Joined: Sun Jan 16, 2011 12:42 am

Re: Is it possible?

Post by razac920 »

Both of those seem fixable, though:
1. Have you tried copying these lines from Yoda's ODF?

Code: Select all

TargetPointOffsetStand  = "0.0 0.5 0.0"
TargetPointOffsetCrouch = "0.0 0.3 0.0"
I believe they tell the AI to aim low for short units.

2. I've found that spawning hover units in the air pretty much always gets them to deploy their jetpacks. Since you're spawning these locals next to a unit, simply spawn them above the unit (comfortably above, as it takes a few seconds for them to deploy the jetpack)
THEWULFMAN
Space Ranger
Posts: 5557
Joined: Tue Aug 17, 2010 3:30 pm
Projects :: Evolved 2
Location: Columbus, Ohio
Contact:

Re: Is it possible?

Post by THEWULFMAN »

re:#1 that might explain it. I tried TargetPointOffset, nothing seemed to change. I'll have to try TargetPointOffsetStand/Crouch.
razac920
2nd Lieutenant
2nd Lieutenant
Posts: 365
Joined: Sun Jan 16, 2011 12:42 am

Re: Is it possible?

Post by razac920 »

Ah, looking at ODF_Parameters, I see that TargetPointOffset is a property of "EntityGeometry" (is this buildings?), while TargetPointOffsetStand/Crouch is a property of "soldier".
Post Reply