Page 1 of 1

Lots of players

PostPosted: 20 Apr 2012, 18:53
by Krom
As many of you know we've been implementing AI town builder module. It is very far from being self-sustainable, not to say completely defenseless.. So far AI stops just before gold mine.
Anyway, I've fooling around with the AI when it suddenly hit me - how many players Remake can handle? 8, maybe 9 as TDL requested? I mean how hard can it be - replace MAX_PLAYERS = 8 with something different, maybe 18? Easy to say and whats surprising - easy to make.

What you see below is a modified AcrossDesert map that has 18 players (17 AIs + 1 Human). Game time is ~1hr 20min and you can already see that most advanced (read "lucky") AIs managed to build something resembling towns, yet unlucky ones (violet, orange) made excessively stupid decisions to build houses without short roads.

My apology for large image - making it any smaller would have lost all the details.

Re: Lots of players

PostPosted: 20 Apr 2012, 19:04
by pawel95
Haha yeah. For example Brown-yellow on the bottom has so a long road only for a woodcutter :D
It a funny idea. A map with 20 players, but than the space is to avaible, for AI special.

Re: Lots of players

PostPosted: 20 Apr 2012, 19:21
by The Dark Lord
Haha nice, especially that mill! :P
Btw I think it was Piko who suggested that, not me. Not that it matters.

Oh and I also think there should be a difference between the allowed numbers of human and AI players. In some missions I make lots of AI players that only have troops. The more AI players, the more possibilities for 'special' attacks.
For example, if the enemy has 4 groups of archers and 4 groups of lance carriers, I could make 2 AI players with each 2 groups of archers and 2 groups of lance carriers and let them each attack at a different location AND let the attack repeat (TYPE 2) so that they won't retreat. If I had just one AI player, I would have to choose whether I'll let it attack repeatedly with everything, or just once at two different locations (just once = you can stop the attack by sending 1 militia to make them halt, they won't continue the attack).
Then again, new scripting commands would do the job as well. Something that makes an attack go on until all soldiers are dead (currently TYPE 2 in combination with TAKE_ALL).

Sorry for going offtopic. :P

Re: Lots of players

PostPosted: 21 Apr 2012, 01:36
by Remake 2012
Well done. We waiting .. . . . . :)
GREAT !

Re: Lots of players

PostPosted: 21 Apr 2012, 01:58
by Lewin
I guess the only reason to not increase the player limit is performance. I found that with 7 builder AIs the game only runs at about 10x speed max. Currently the AI uses a lot of CPU to place a house connect road, but if the AIs don't do much as TDL mentioned then it's not really a problem. But of we allow 20 AIs in singleplayer I bet people will try giving them all villages and then wonder why it runs slowly :P

Great picture, I love watching the AI build they're so funny :P

Re: Lots of players

PostPosted: 21 Apr 2012, 05:40
by Piko
Btw I think it was Piko who suggested that, not me.
Yes, I suggested the 9 players idea.

About AI building - good job, Krom ;)

Re: Lots of players

PostPosted: 04 May 2012, 10:42
by ChrisEggII
Hmm... I think 9 players are enough, but If someone have good server and players don't make lags, he'll should can make game for 18 players.
Single-players shouldn't have any limits.

Re: Lots of players

PostPosted: 04 May 2012, 11:32
by Krom
18 Players is more of a crazy test, rather than an actual plan.

I have trouble picturing an SP map with 9 distinct players )

Re: Lots of players

PostPosted: 04 May 2012, 12:21
by Lewin
All of the game simulation is done on the clients, not the server. The server is just a dumb packet forwarder that allows you to connect to other players. It uses about 3KB/s per player, (upload and download combined) so 8 players only uses about 24KB/s. Even with just a 1MB/s link that means you can have over 300 players at once. There are basically no CPU/memory requirements for the server because it's so simple, it knows nothing about KaM, only the packets of information to be sent between clients.

The limit on maximum players is client side. Playing a singleplayer game is would be very laggy with 18 players if they all have villages and are doing things. Network games are the same, each player adds more processing to be done. (giving serfs/labourers jobs, making all the units move/interact/fight, updating terrain, archers scanning for enemies to shoot, etc.)

Re: Lots of players

PostPosted: 30 May 2012, 19:18
by godest
Damn that picture looks awsome :)!