Sounds like you want your entire game to already be built for you.
Yeah you're right, thank you for noticing.
1. Should it run primary on a single PC or server farm ?
2. What level of detail/quality do you expect from the generated world (roguelike/minecraft?) ?
3. What behavior do you expect from your AI (simple=Zombie, hard=autonomous citizin of a large society).
4. Turn based or real-time ?
5. What are existing games which (partly) cover your vision ?
6. If no game exists which covers your vision, why ?
1. server farm
2. simple, not voxel though.
3. autonomous citizin of a large society.
4. real-time
5. Children of the Nile, Tyrants, Populous...
6. I think it's a novel idea?! I'm sure many have conceived something similar but because the vision is grand and thus not articulated well the path taken to the vision lends to many different games realised by a similar vision?
Once you're nearly finished then optimise the hell out of it...
Well at first what I made could simulate 10 ai without a hit to fps. Then with some geometry division techniques I was able to increase that number to 150. But 150 is far from my goal of 10,000. So if I can't even get to 500 then it really isn't worth exploring further in the current format. That format being a world of x,y,z coordinates with ai needing a position vector, up vector and lookAt vector. If I can't get to 10,000 using a spherical world then I'd go to a flat world. I'd rather not finish and then realise that I can only make it to 300 ai.
- allow thousands of individual ai to roam around the surface of the world without major loss to system resources or fps, avoiding obstacles and moving to their destination.
The fact that you want thousands of concurrent AI reveals a lot. Can you tell me about any major game where you have seen this actually done?
None of those are particularly hard. Most major engines out there have it built in or otherwise can handle what you described.
Some of the games which I know of that do something similar are Children of the Nile, there was a Genesis title called 'Tyrants' but in that game there were less than 100 ai, and I heard an old game called populous simulated people to a degree.
- Thanks for the list.
If you want thousands of AI you have two real choices:
A) make the AI really dumb at distance and smarter when it's closer to the player, or even inactive when invisible. Games like fallout 4, elder scrolls series etc do this.
B) keep the AI super smart all the time but offload the processing into several dozen shared servers purely responsible for AI.
So I'm planning on doing B, as the game will require all ai to be as smart as possible.
-------------------------------------------------------------------------------------------------------------------------------
I made this post because I realised yesterday just what I needed to see this project come to life. I thought, heck maybe someone already made a library / engine which does everything I'm currently programming and I'm just wasting my time. I reached a limit of 150 ai because I was using raycasting to snap the ai to the surface of the world, I literally divided the whole sphere n# of faces into n# of individual mesh's and then the raycaste processing was reduced to check where the collision occurred within 13 faces instead of n# faces. But then the limit was 150 ai moving, and for some unknown to me, nodejs could only handle 50 ai and nodejs doesn't even show what's happening visually. But today I thought of a new approach, using something in threejs called Line3 which is 'drawn' between two vectors, create a line3 for the path which the ai will travel along and then to obtain the ai's position I only need to obtain it's point along that line. I haven't tested it yet though. I assume obtaining a point along a line uses fewer system resources than a raycaste call.