bugFreeciv - Bugs: bug #20301, Not all lost units counted in...

 
 
Show feedback again

bug #20301: Not all lost units counted in score.units_lost

Submitted by:  Marko Lindqvist <cazfi>
Submitted on:  Sat 17 Nov 2012 02:30:21 AM UTC  
 
Category: generalSeverity: 3 - Normal
Priority: 5 - NormalStatus: Fixed
Assigned to: Marko Lindqvist <cazfi>Open/Closed: Closed
Release: Operating System: None
Planned Release: 2.3.3, 2.4.0, 2.5.0

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Fri 23 Nov 2012 05:40:13 AM UTC, SVN revision 22032:

Increase score.units_lost when
- Units lost with their transport
- Units killed by hut barbarians
- Units killed by terrain changes
- Diplomats killed in fight against other diplomats
- Diplomats failing their mission
- Units within opponent's borders wiped when entering peace

See gna bug #20301

(Browse SVN revision 22032)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Fri 23 Nov 2012 05:40:04 AM UTC, SVN revision 22031:

Increase score.units_lost when
- Units lost with their transport
- Units killed by hut barbarians
- Units killed by terrain changes
- Diplomats killed in fight against other diplomats
- Diplomats failing their mission
- Units within opponent's borders wiped when entering peace

See gna bug #20301

(Browse SVN revision 22031)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Fri 23 Nov 2012 05:39:54 AM UTC, SVN revision 22030:

Increase score.units_lost when
- Units lost with their transport
- Units killed by hut barbarians
- Units killed by terrain changes
- Diplomats killed in fight against other diplomats
- Diplomats failing their mission
- Units within opponent's borders wiped when entering peace

See gna bug #20301

(Browse SVN revision 22030)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Tue 20 Nov 2012 12:05:29 AM UTC, comment #3:

- Updated S2_4/TRUNK against current svn, old patch applies to S2_3

(file #16787, file #16788)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sat 17 Nov 2012 03:16:44 AM UTC, comment #2:

> This ticket is about fixing all cases.


Err. All cases where wipe_unit() is called since this simply moves counting inside wipe_unit().

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sat 17 Nov 2012 03:07:19 AM UTC, comment #1:

TRUNK & S2_4 versions

(file #16771, file #16772)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.
Sat 17 Nov 2012 02:30:21 AM UTC, original submission:

bug #19821 point 4 is about units lost with their transport not being counted in score.units_lost or score.units_killed. That's not the only place where those counters are not properly increased. This ticket is about fixing all cases.

Patch for S2_3 attached.
As S2_3 has no unit_loss_reason, patch for it is quite different from what S2_4/TRUNK one will likely be.

This fixes following cases where units_lost was not increased though it should:
- Units lost with their transport
- Units killed by hut barbarians
- Units killed by terrain changes
- Diplomats killed in fight against other diplomats
- Diplomats failing their mission (diplomats dying after succesfull mission are not counted any more than are settlers founding cities or caravans establishing traderoutes counted; they just perform their function)
- Units wiped from opponent terrain when entering peace

I consider inspection period of this S2_3 patch to begin now even though S2_4/TRUNK patches are still missing (I may commit to S2_3 before other branches)

Marko Lindqvist <cazfi>
Project AdministratorIn charge of this item.

 

(Note: upload size limit is set to 1024 kB, after insertion of the required escape characters.)

Attach File(s):
   
   
Comment:
   

Attached Files
file #16787:  UnitsLostScore-2.patch added by cazfi (20kB - text/x-diff)
file #16771:  UnitsLostScore.patch added by cazfi (20kB - text/x-diff)
file #16772:  UnitsLostScore-S2_4.patch added by cazfi (20kB - text/x-diff)
file #16770:  UnitsLostScore-S2_3.patch added by cazfi (18kB - text/x-diff)

 

Depends on the following items: None found

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -unavailable- added by cazfi (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 10 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sat 19 Jan 2013 11:13:11 AM UTCjtnDependencies-=>bugs #19821 is dependent
    Fri 23 Nov 2012 05:40:27 AM UTCcazfiStatusReady For Test=>Fixed
      Assigned toNone=>cazfi
      Open/ClosedOpen=>Closed
    Tue 20 Nov 2012 12:05:29 AM UTCcazfiAttached File-=>Added UnitsLostScore-2.patch, #16787
      Attached File-=>Added UnitsLostScore-S2_4-2.patch, #16788
    Sat 17 Nov 2012 03:16:44 AM UTCcazfiStatusNone=>Ready For Test
    Sat 17 Nov 2012 03:07:19 AM UTCcazfiAttached File-=>Added UnitsLostScore.patch, #16771
      Attached File-=>Added UnitsLostScore-S2_4.patch, #16772
    Sat 17 Nov 2012 02:30:21 AM UTCcazfiAttached File-=>Added UnitsLostScore-S2_3.patch, #16770
    Show feedback again

    Back to the top


    Powered by Savane 3.1-cleanup