Forum: PogamutUT2004

Swarm Bots - NavPoints question.

Hi =)
I'm trying to implement an ant swarm strategy for my unreal bots, in order to illustrate the efficiency of this algorithm to achieve task.

I'm starting with pogamut and i'm going through some difficulties, finding some fuctions.
My bots moves using navigation points.

When he is on a pathnode, i need to know what are the navpoints reachable from that
pathnode (i mean, distance = 1, no pathnode between) in order to move my bot
1 by 1 navpoints. Is there a fuction for that?

Thank you! :-D (Sorry for my english)
Hi Tyler! Welcome to the forum :-)

So are you using NavPoint instances?

1) UT2004 navigation graph is probably not as dense as you would like to,
so you might find the distances between navpoints unsuitable

2) UT2004 has UnrealEd.exe that is editor for UT2004 maps and you may place as many additional
navpoints as you would like to have

3) NavPoint.getOutgoingEdges() method will give you Map that
has keys => ids of distant navpoints, values => object describing the link between navs (note that
you have to interpret the getFlag() method of the link to filter out unsuitable links like PROSCRIBED or PLAYER_ONLY, etc.)

4) Use world.getAll(NavPoint.class).values() to obtain collection of all NavPoints that are present in the game.

5) Use info.getNearestNavPoint() to obtain navpoint that is the nearest to you

Hope these notes make some sense to you! If not keep asking!

Best,
Jimmy

P.S.: please note that UT2004 can't (usually) run more than 8 bots at once without having performance problems
Thanks for your quick answer!

Yes, i'm using NavPoints instances.

1) True :-D

2) Yes, I created a map with UnrealEd to make my test
(http://i56.tinypic.com/14jrn7l.jpg)

3) Thank you! This is just what I need :-D

4-5) I see those functions on NavigationBot Pogamut example.
I'm taking it for reference.

I hope I have enough with 8 bots ^^

I'll keep posting my problems which I can´t solve.

Thank you very much for your help.