[Freeciv-Dev] [bug #22824] multiplayer ruleset: Savegames not portable against ruleset changes due to saved script variables
Follow-up Comment #4, bug #22824 (project freeciv): I don't think this would ever have caused trouble, as I think the order/number of techs and buildings has not changed since the ruleset was added in patch #1838. It's future-proofing. ___ Reply to this item at: http://gna.org/bugs/?22824 ___ 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 #22824] multiplayer ruleset: Savegames not portable against ruleset changes due to saved script variables
Update of bug #22824 (project freeciv): Status: Ready For Test = Fixed Open/Closed:Open = Closed ___ Reply to this item at: http://gna.org/bugs/?22824 ___ 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 #22824] multiplayer ruleset: Savegames not portable against ruleset changes due to saved script variables
Update of bug #22824 (project freeciv): Status:None = In Progress Assigned to:None = jtn Planned Release: = 2.4.4, 2.5.0, 2.6.0 ___ Reply to this item at: http://gna.org/bugs/?22824 ___ 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 #22824] multiplayer ruleset: Savegames not portable against ruleset changes due to saved script variables
Update of bug #22824 (project freeciv): Status: In Progress = Ready For Test ___ Additional Item Attachment: File name: trunk-S2_5-S2_4-multiplayer-lua-state.patch Size:2 KB ___ Reply to this item at: http://gna.org/bugs/?22824 ___ 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 #22824] multiplayer ruleset: Savegames not portable against ruleset changes due to saved script variables
URL: http://gna.org/bugs/?22824 Summary: multiplayer ruleset: Savegames not portable against ruleset changes due to saved script variables Project: Freeciv Submitted by: jtn Submitted on: Sat 18 Oct 2014 12:53:59 BST Category: rulesets Severity: 3 - Normal Priority: 5 - Normal Status: None Assigned to: None Originator Email: Open/Closed: Open Release: Discussion Lock: Any Operating System: None Planned Release: ___ Details: In a savegame of the multiplayer ruleset, the following state is saved: [script] code=$$ vars=$phil_tech=find.tech_type(60) phil_id=60 darw_id=44 tevo_tech=find.tech_type(89) darw_btype=find.building_type(44) $ This hardcodes numeric indexes of ruleset objects from the currently loaded ruleset. If the ruleset is rearranged so that objects have different indices, this bypasses the usual savegame compatibility arrangements for that. Probably the script should just look these up on demand; I can't see any impact other than performance, and a minor one at that. (I wasn't sure whether file-scope variable assignments might be re-evaluated at savegame load. It seems they aren't; I guess they're evaluated at ruleset load and then stomped by anything in the savegame. If I save a game and then rearrange buildings.ruleset: jtn: 'lua cmd log.normal((find.building_type(Darwin's Voyage)).id)' /lua: 43 jtn: 'lua cmd log.normal(darw_id)' /lua: 44 ___ Reply to this item at: http://gna.org/bugs/?22824 ___ Message sent via/by Gna! http://gna.org/ ___ Freeciv-dev mailing list Freeciv-dev@gna.org https://mail.gna.org/listinfo/freeciv-dev