Gamestudio Links
Zorro Links
Newest Posts
Zorro on Linux
by gtell
Today at 08:55
Aum119 is ready
by George
Today at 08:05
Why I don't like Unity/Unreal
by Kartoffel
Yesterday at 19:39
Video control
by middleagechinese
Yesterday at 15:10
Lost Key
by Ezzett
Yesterday at 03:44
AUM Magazine
Latest Screens
RPG PARTY
Triton Wing now available on Steam
AckCon'17: Lotter vs The World
Triton Wing
ZeaL
Who's Online
11 registered (MasterQ32, jyd, MatPed, pascalx, Superku, gtell, sivan, alibaba, 2 invisible), 450 Guests and 4 Spiders online.
Key: Admin, Global Mod, Mod
Newest Members
vivekkumar, Hale75, victrades, htj, anufriyev
17781 Registered Users
Topic Options
Rate This Topic
#462697 - 10/22/16 02:40 Pathfinding for crowds?
gameplan Offline
Member

Registered: 08/30/11
Posts: 133
Loc: Germany, Supergeheimes Hinter-...
Hi,

I want to implement a pathfindung solution for a big crwod of dynamically moving entites. Every entity should avoid contact with each other entity while finding a path through a moving crowd of entities over a unevan surface.

I just want to ask, if someone does know a good starting point? Does there exist a specific algorithm, that suits best for this excercise? What do you recommend?

Thanks.
_________________________
Version: A8 free
OS: Windows 10

Top
#462700 - 10/22/16 09:26 Re: Pathfinding for crowds? [Re: gameplan]
sivan Online
Expert

Registered: 03/07/11
Posts: 3106
Loc: Budapest
WJBender made a navmesh plugin called Peragro of the Recast/Detour/DetourCrowd. By the way, it is available in Unity and UE4 by default. I don't know whether it is still available or not, he switched to Unity. It has good performance I think only max 100 characters. To make your own plugin:
http://masagroup.github.io/recastdetour/
https://github.com/recastnavigation/recastnavigation

another open source solution is RVO2:
http://gamma.cs.unc.edu/RVO2/

by the way if you need larger crowd, you can implement a vector field pathfinding and movement system, or use simply a potential field. I have recently implemented my solution based on this, but it does not deal with avoidance (but possible to add little repulsion to the heat map around units):
https://gamedevelopment.tutsplus.com/tut...g--gamedev-9007

But it really depends on you what you mean by crowd, and what is the exact purpose, what limitations you can accept on quality and performance...
_________________________
Free world editor for 3D Gamestudio: MapBuilder Editor

Top
#462709 - 10/22/16 15:25 Re: Pathfinding for crowds? [Re: sivan]
rayp Offline

X

Registered: 07/31/08
Posts: 1837
Loc: Germany
To keep performance high use a single while that controlls all ents stored in a array.
this mass ai tip changed my life.

My mass ai project
http://www.opserver.de/ubb7/ubbthreads.php?ubb=showflat&Number=460893#Post460893

Greets


Edited by rayp (10/22/16 15:27)
_________________________
My entry...your exits
Zombies dont like pink glow slime, fact!
"We gonna rock down to electric avenue" "One way ... or anotha ..."
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
-=GOOGLE IS SKYNET=-
rayp.flags |= UNTOUCHABLE;

Top
#462718 - 10/22/16 21:49 Re: Pathfinding for crowds? [Re: rayp]
gameplan Offline
Member

Registered: 08/30/11
Posts: 133
Loc: Germany, Supergeheimes Hinter-...
Hm, most of the implementations that I have locked at, seem to need a navmesh or nodes, that need to be placed by hand. I would appreciate a solution, that works without manually setting navmeshes, nodes or similar things.

I want to implement a navigation / pathfinding for around 500 NPCs, that works for a dynamically changing enviroment (many moving objects). Examples for similar implementations are Picmin, Age of Empires or Left4Dead.
_________________________
Version: A8 free
OS: Windows 10

Top
#462719 - 10/22/16 22:58 Re: Pathfinding for crowds? [Re: gameplan]
Quad Offline
Senior Expert

Registered: 10/27/07
Posts: 5134
Loc: İstanbul, Turkey
Recast is for autogenerating navmeshes from level geometry.
_________________________
3333333333

Top
#462722 - 10/23/16 02:46 Re: Pathfinding for crowds? [Re: Quad]
rayp Offline

X

Registered: 07/31/08
Posts: 1837
Loc: Germany
500 npcs with acknex?
that is not realistic. Even left4dead source engine cant handle such amount of ents. Dead rising maybe. That was the reason why capcom was impressed an bought bluecastle.
It took me years to have 50 pathfinding moving and animated ents with 60fps.
anyway good luck wink

Greets


Edited by rayp (10/23/16 03:03)
_________________________
My entry...your exits
Zombies dont like pink glow slime, fact!
"We gonna rock down to electric avenue" "One way ... or anotha ..."
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
-=GOOGLE IS SKYNET=-
rayp.flags |= UNTOUCHABLE;

Top
#462725 - 10/23/16 10:45 Re: Pathfinding for crowds? [Re: gameplan]
3run Offline
Expert

Registered: 05/05/09
Posts: 4894
Loc: Caucasus
Hi!
Originally Posted By: gameplan
I want to implement a navigation / pathfinding for around 500 NPCs, that works for a dynamically changing enviroment (many moving objects). Examples for similar implementations are Picmin, Age of Empires or Left4Dead.
Well, it may work but don't forget about models, bone animations, shaders etc... They will probably ruin the whole thing and at the end you'll get around 15-25 fps (that's what rayp is talking about I think). Maybe if it's going to be hardly optimized (well, it depends on the type of the game you make), well, I can't guess, let's see how it turns our, I'm curious.

Best regards!
_________________________
Looking for free stuff?? Take a look here: http://badcom.at.ua

Top
#462729 - 10/23/16 15:33 Re: Pathfinding for crowds? [Re: rayp]
Aku_Aku Offline
User

Registered: 09/25/09
Posts: 912
Loc: Budapest
The Conitec had a demo that showed hundreds of animated models in an infinite loop.
As i remember it was cca. 6 years ago.
Here: MMO test you can download a special version of A7 what aimed exactly the same, showing 500 animated models at 60 fps.
Maybe A8 can give more performance nowadays.
In the zip there are two test executables.
1. for testing crowd.
2. for testing terrain.
Good luck!

Top
#462731 - 10/23/16 16:51 Re: Pathfinding for crowds? [Re: Aku_Aku]
rayp Offline

X

Registered: 07/31/08
Posts: 1837
Loc: Germany
Standing animated models is one thing. Pathfinding moving and animated another thing.
looking forward to this.
greets
_________________________
My entry...your exits
Zombies dont like pink glow slime, fact!
"We gonna rock down to electric avenue" "One way ... or anotha ..."
"Hey Griswold ... where u gonna put a tree that big ?"
1998 i married my loved wife ... Sheeva from Mortal Kombat, not Evil-Lyn as might have been expected
-=GOOGLE IS SKYNET=-
rayp.flags |= UNTOUCHABLE;

Top
#462737 - 10/23/16 23:23 Re: Pathfinding for crowds? [Re: rayp]
sivan Online
Expert

Registered: 03/07/11
Posts: 3106
Loc: Budapest
the best to check what other games use in the similar genre you want to make. probably most of them select different methods not accidentally.

With 3DGS, I could achieve only 25 FPS as an average, handling about 400 characters (moving in group formations) in my RTS testbed level (filled with buildings, trees, and using shaders like water, shadowmapping etc.), when reached a good enough quality, after many-many optimizations. It required to implement my own complex pathfinder and movement system... with A8 Pro edition where I have terrain LOD and GPU animation.

But a lot depends on what quality you need, how many of units are visible, their bone and vertex number etc. If the behavior is very simple you can have more, but game engines are in general not for this purpose, rather for something like an FPS.
_________________________
Free world editor for 3D Gamestudio: MapBuilder Editor

Top


Moderator:  old_bill, Spirit 

Gamestudio download | chip programmers | Zorro platform | shop | resources | magazine | manual | support faq | bugs | beta features

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) 3dgamestudio.net