[Freeciv-tickets] [freeciv] #41117: Savegame handling for counters

Back to archive index
OSDN Ticket System norep****@osdn*****
Mon Nov 15 00:15:08 JST 2021


#41117: Savegame handling for counters

  Open Date: 2021-01-08 06:00
Last Update: 2021-11-15 00:15

URL for this Ticket:
    https://osdn.net//projects/freeciv/ticket/41117
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=41117

---------------------------------------------------------------------

Last Changes/Comment on this Ticket:
2021-11-15 00:15 Updated by: lachu

Comment:

Reply To cazfi
I send first patch.

---------------------------------------------------------------------
Ticket Status:

      Reporter: cazfi
         Owner: (None)
          Type: Patches
        Status: Open
      Priority: 5 - Medium
     MileStone: 3.2.0
     Component: General
      Severity: 5 - Medium
    Resolution: None
---------------------------------------------------------------------

Ticket details:

Save and load counter information. This require saving the order (city_counters_order), and the city counter values. Should also save boolean indicator that the freeciv revision doing the saving has hardcoded_counters. There's no need to read it yet, but it's there in the savegame for the benefit of the future freeciv revisions loading it.
That the saving side does the right thing can be checked from the generated save file.
Once saving side is known to work, loading side testing is a bit more complicated: First compile with hardcoded 'def' value of our only counter set to 1. Run a game and save after founding a city. Check from the save file that the city's counter has value 1. Recompile with hardcoded 'def' set to 2. Start the game by loading the previously saved game. Now the loading should overwrite initial 2 by the value 1 from the savegame. Save the game again, and check from the save file that value indeed is 1 (and not 2).

-- 
Ticket information of Freeciv project
Freeciv Project is hosted on OSDN

Project URL: https://osdn.net/projects/freeciv/
OSDN: https://osdn.net

URL for this Ticket:
    https://osdn.net/projects/freeciv/ticket/41117
RSS feed for this Ticket:
    https://osdn.net/ticket/ticket_rss.php?group_id=12505&tid=41117



More information about the Freeciv-tickets mailing list
Back to archive index