Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WML: Add additional members to [store_side] results #929

Merged

Conversation

sigurdfdragon
Copy link
Contributor

Most were only possible to add since 1.13.5

Not sure if 'lost' should be here.

I still need to add a changelog entry

@gfgtdf
Copy link
Contributor

gfgtdf commented Feb 10, 2017

Hmm i don't remember why the is 'lost' thing was added in the first place, what it actually does is removing a side form carryover when it was defeated. but note that:

  1. Ai sides usually have already persistent=no in their [side] definition

  2. When a human side looses this usuualy means that the campaoign ends and that there will be no carryover going on anyway.

So it might be some (possibly multiplayer related) corner case where this is important.

@sigurdfdragon
Copy link
Contributor Author

ok, given that, is there any reason not to just store the whole side.__cfg as below, with maybe an addition to knockout the [ai] tag? (such a case would match what is displayed for the side in the Gamestate Inspector)

``
local container = t.__cfg

utils.vwriter.write(writer, container)
``

@CelticMinstrel
Copy link
Member

Well, there could be things that exist in t but not in t.__cfg. I recall adding a few such things which are calculated on the fly. (I don't remember if that was in master or a branch, though.)

(By the way, it's three backticks to delimit code blocks, not two. You can also add a language on the same line as the opening backticks, in this case lua.)

@CelticMinstrel
Copy link
Member

So, just to be sure, I assume all those individual keys that were specifically accessed before also exist in t.__cfg?

@sigurdfdragon
Copy link
Contributor Author

sigurdfdragon commented Feb 17, 2017

Double-checked and added back two keys that weren't handled correctly by .__cfg

@CelticMinstrel CelticMinstrel merged commit 3df8d4f into wesnoth:master Feb 18, 2017
@CelticMinstrel
Copy link
Member

By the way, IIRC the wml_tag_porting branch added some new side proxy members, some of which may need special handling added here.

@sigurdfdragon sigurdfdragon deleted the add_new_keys_to_store_side branch May 28, 2021 16:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants