I could try to implement the table solution without fixed formats. So you pass 
a table to the save function, but it is up to you what keys to specify, and the 
.wcd file will contain only the keys you chose to use, with the values you 
assigned to them.
For example, you could call
  local decision = ...
  wl.Game().save_campaign_data("empiretut", "emp04", {
    conquered_monastry = decision
  })
and then you´d get in the next scenario
  local cdtable = wl.Game().read_campaign_data("empiretut", "emp04")
  --> value of cdtable is {conquered_monastry=true}
  local decision = cdtable.conquered_monastry
So you´d save and get only the information you really want.
-- 
https://code.launchpad.net/~widelands-dev/widelands/campaign_data/+merge/343783
Your team Widelands Developers is requested to review the proposed merge of 
lp:~widelands-dev/widelands/campaign_data into lp:widelands.

_______________________________________________
Mailing list: https://launchpad.net/~widelands-dev
Post to     : widelands-dev@lists.launchpad.net
Unsubscribe : https://launchpad.net/~widelands-dev
More help   : https://help.launchpad.net/ListHelp

Reply via email to