Page 1 of 1

Attack list and army sizes.

Posted: Fri Jan 16, 2009 8:14 pm
by Midnight
Just noticed that if you compare the army sizes for accounts on the attack list to what they are when you click on the account itself, they tend to be different.

Eg.

MaguĂ… - list size - 3,700 - profile size - 3699
Ancient Ajna - list size - 3,588 - profile size - 3589
sgtjohnkeel- list size - 3,620 - profile size - 3619
Harvey- list size - 3,720 - profile size - 3720
Oneil- list size - 3,694 - profile size - 3693
Midnight Masochist - list size - 3726 - profile size - 3725

Re: Attack list and army sizes.

Posted: Fri Jan 16, 2009 8:29 pm
by Thade
Looks like some kind of rounding bug. Probably a display issue on the rankings page having the wrong thing.

Re: Attack list and army sizes.

Posted: Fri Jan 16, 2009 9:55 pm
by Midnight
Thats what I figured, but decided to report it as it doesn't seem to occur in main, so figured it was fixable...

Re: Attack list and army sizes.

Posted: Fri Jan 16, 2009 10:12 pm
by Thade
Also noticed on the stats.php page that rank is not displayed. (figured it was probably same page so would mention it here, split me off if you'd rather it be separate)

Re: Attack list and army sizes.

Posted: Sat Jan 17, 2009 1:01 am
by adminGary
it's a rounding error.

since it is hard to give out 50 units on a day when the server ticks 48 times a day. The database is set to not hold just an integer, but a few decimals after that. So if on a sever tick you get 1.5 units, you don't loose that 1/2 a unit, it is made up for on the next server tick. Since some pages use round functions and others use floor functions the armies sizes between two pages can be off by a few units.

Since the round is limited to the untrained units, it doesn't cause any problems in any of the calculations for the game, which is probably why it hasn't been fixed yet.