[Freeciv-Dev] [bug #13733] Endgame report can contain negative tech score

2009-06-20 Thread pepeto

URL:
  http://gna.org/bugs/?13733

 Summary: Endgame report can contain negative tech score
 Project: Freeciv
Submitted by: pepeto
Submitted on: Saturday 06/20/2009 at 09:37
Category: general
Severity: 2 - Minor
Priority: 5 - Normal
  Status: None
 Assigned to: None
Originator Email: 
 Open/Closed: Open
 Discussion Lock: Any
 Release: 
Operating System: None

___

Details:

When you end the game whereas you don't have any tech yet, your tech score is
set to 65535 (-1). This bug is due to the removal of the tech A_NONE of the
tech count which appear twice on the algorythm.

score.c at line 289:
  tech_type_iterate(i) {
if (i  A_NONE  get_invention(pplayer, i) == TECH_KNOWN) {
  pplayer-score.techs++;
}
  } tech_type_iterate_end;

report.c at line 1115:
packet.techs[i] = get_techs(size[i].player) - 1;

The attach patch remove the hard coded -1 from the code.



___

File Attachments:


---
Date: Saturday 06/20/2009 at 09:37  Name: tech_score.diff  Size: 631B   By:
pepeto

http://gna.org/bugs/download.php?file_id=6010

___

Reply to this item at:

  http://gna.org/bugs/?13733

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev


[Freeciv-Dev] [bug #13733] Endgame report can contain negative tech score

2009-06-20 Thread Madeline Book

Update of bug #13733 (project freeciv):

 Assigned to:None = mbook  


___

Reply to this item at:

  http://gna.org/bugs/?13733

___
  Message sent via/by Gna!
  http://gna.org/


___
Freeciv-dev mailing list
Freeciv-dev@gna.org
https://mail.gna.org/listinfo/freeciv-dev