Changes to Store Side in 1.14?
Moderator: Forum Moderators
Forum rules
- Please use [code] BBCode tags in your posts for embedding WML snippets.
- To keep your code readable so that others can easily help you, make sure to indent it following our conventions.
- PapaSmurfReloaded
- Posts: 822
- Joined: November 17th, 2007, 1:10 pm
- Location: Argentina
Changes to Store Side in 1.14?
One of my addons is having issues with Store Side, I want to get the player name to be displayed, however $stored_side.name is not working. I've checked and it does, however, store correctly other stuff such as color, side number, gold, etc.
Does anybody know how to access the player name of the stored side?
Does anybody know how to access the player name of the stored side?
Re: Changes to Store Side in 1.14?
Hello PapaSmurfReloadedPapaSmurfReloaded wrote: ↑May 12th, 2018, 4:01 pm One of my addons is having issues with Store Side, I want to get the player name to be displayed, however $stored_side.name is not working. I've checked and it does, however, store correctly other stuff such as color, side number, gold, etc.
Does anybody know how to access the player name of the stored side?
The .name is now replaced with .current_player (for WML, for lua I think it's .side_name)
You can see more details here: viewtopic.php?f=21&t=47614 (it's not documented in wiki)
You could also [store_side] and then :debug :inspect (to see what's inside array)
I hope it helps..
- PapaSmurfReloaded
- Posts: 822
- Joined: November 17th, 2007, 1:10 pm
- Location: Argentina
Re: Changes to Store Side in 1.14?
Thank you very much enclave, you've saved me.enclave wrote: ↑May 12th, 2018, 5:31 pmHello PapaSmurfReloaded
The .name is now replaced with .current_player (for WML, for lua I think it's .side_name)
You can see more details here: viewtopic.php?f=21&t=47614 (it's not documented in wiki)
You could also [store_side] and then :debug :inspect (to see what's inside array)
I hope it helps..
It works, indeed, I find .current_player quite unintuitive it makes me wonder why they changed it to that.
Re: Changes to Store Side in 1.14?
Who knows;) Maybe they have future plans for .name which would have some other functionPapaSmurfReloaded wrote: ↑May 12th, 2018, 7:05 pm It works, indeed, I find .current_player quite unintuitive it makes me wonder why they changed it to that.
Well .current player feels logical in the way that if you give control to other player the name will change... to that player.. i guess... but why would you change something that was always .name thats a different question Must be a better reason than just logic.. since it creates incompatibility.. who knows who knows
Re: Changes to Store Side in 1.14?
it all part of the developers evil plan to break all of the umc addons.PapaSmurfReloaded wrote: ↑May 12th, 2018, 7:05 pm It works, indeed, I find .current_player quite unintuitive it makes me wonder why they changed it to that.
No, now seriously, we just changed a bit how name/side_name/current_player works and forgot to add a compability path in [store_side], in 1.12 it was somhow unclear what exactly is contained in the name and the current_player attribute which both exists in 1.12 and some dialogs used current_player= and some use name=. etc. The way it is intended to work in 1.14 is:
current_player always contains the name of the mp acoount name.
side_name= contains the wml defined name for the side,
So for example if i play the LoW mp campaign "side_name" will be 'Konrad' and current_player will be 'gfgtdf'. The reason why we called that attribute 'side_name' instread of 'name' is that 'name' is alrady the attribute for the leader unit generated by '[side]'. When showing a dialog, like the gamestats dialog, what teh engine does, it first tried to use 'side_name' and of that is empty it falls back to 'current_player'
Scenario with Robots SP scenario (1.11/1.12), allows you to build your units with components, PYR No preperation turn 1.12 mp-mod that allows you to select your units immideately after the game begins.
Re: Changes to Store Side in 1.14?
That's interesting, I never noticed it existed in 1.12gfgtdf wrote: ↑May 13th, 2018, 12:33 pm No, now seriously, we just changed a bit how name/side_name/current_player works and forgot to add a compability path in [store_side], in 1.12 it was somhow unclear what exactly is contained in the name and the current_player attribute which both exists in 1.12 and some dialogs used current_player= and some use name=. etc. The way it is intended to work in 1.14 is: