[phpBB Debug] PHP Warning: in file /includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
AI Challenge Forums • View topic - Detecting number of live players

It is currently Fri Jan 19, 2018 3:49 am Advanced search

Detecting number of live players

Code won't compile? Found a bug? Post here!

Detecting number of live players

Postby Queue29 » Sat Sep 04, 2010 3:34 pm

Queue29
Lieutenant-Colonel
 
Posts: 41
Joined: Sat Feb 06, 2010 5:43 am

Re: Detecting number of live players

Postby bswolf » Sat Sep 04, 2010 6:01 pm

IsAlive checks only that a given id is the owner of some planet or fleet. Because 0 is the id used to represent neutral planets, IsAlive(0) returns true when there are neutral planets, though no player has id 0.
bswolf
Lieutenant
 
Posts: 15
Joined: Fri Sep 03, 2010 6:14 am

Re: Detecting number of live players

Postby Queue29 » Sun Sep 05, 2010 2:01 am

Thanks, that was it.
Queue29
Lieutenant-Colonel
 
Posts: 41
Joined: Sat Feb 06, 2010 5:43 am


Return to Technical Issues

Who is online

Users browsing this forum: No registered users and 1 guest

cron