Conversation
wnbaum
left a comment
There was a problem hiding this comment.
I think you also need to add a space after the comma in this line. Otherwise when the script is loaded again, the vector string will not be split properly.
You'll need to update the pong scene as well, since vectors are currently stored like "1,1" without the space.
Another option is just to remove the spaces entirely from the default values to keep the current serialization scheme.
If a space is left in the Y axis, the default doesn't work. This fixes a bug where focusing the Y side of a Vector2 input and then losing the focus ends with the " " string in the input, losing the default number.
|
Thanks for the insightful review, @wnbaum! As you said, the problem was actually in the defaults having the space character after the comma. Ready for review again. |
wnbaum
left a comment
There was a problem hiding this comment.
Looks good to me now!
Having the user set properties serialized as a String is kind of weird, I changed this in my decouple PR so that Variants themselves get serialized which hopefully leads to less issues like this.
I was thinking the same thing. Let's try to get that in when the dust has settled. |
If a space is left in the Y axis, the default doesn't work. This fixes a bug where focusing the Y side of a Vector2 input and then losing the focus ends with the " " string in the input, losing the default number.
Follow up of #160
https://phabricator.endlessm.com/T35562