Sowwy you had to re-code the .cap. I can attempt to give an explanation for the way the variables behave in your events. But Even then, the good solution would be: Re-code.
Its impossible to give a *concrete* and fulfilling explanation. I have an idea what happened. Or should i say "a feeling".
Allow me to start with pointing to the way Construct is reading and storing variables.
Take this as the illustration.
There are only 2 objects. RedOne and GreenOne.
Both are member of the family "Items"
Both have 2 private variables.
But ! Look at the private variables, and notice that they are not added in the same order.
In the RedOne, 'variable_1' is first. In GreenOne 'variable_2' is first added.
Or to translate this to what it really is about.
They are on different positions. In Redone 'variable_1' is at position 1 int the list of private variables. While its on position 2 in the GreenOne.
So what you say ? Well read the events sheet, its kinda straight forward.
It dont need explanation.
And yet, when you run it. You well see that Reading out the variables using a Family is not working as you expecting it would.
Reading the private variable by addressing the object with its Family name, will read out the private variable on position(x) in the list of private variables for that object. NOT by its name !!!!!!!
Do you see this ?
Now well when this is true for families. Its also true for reading out AND storing any private variable, how ever you address the object.
So what construct really does is this.
You make an event/action that reads/stores a private variable, and construct will translate the name of the private variable to a number representing its position in the list of private variables for that object. And make the calls by that number.
This is done on the moment you make the event/action.
Those calls to positions (in the events) will update if you change (in the layout) things in the private variables.
But at this moment, i hope due its still beta, you can force situations that will NOT update both, the positions the variable gets called by in the events AND the private variables as presented to you in the properties list in the layout editor.
Now funny, and thats always the same, those situations are usually forced by beginners like you and me. Because we trial and error more then advanced users.
Try this. Make an object with 3 variables. Use the 2nd and 3th variable in some events.
Then go back to the Layout editor.
Delete the 1st variable.
Realize that was wrong to do and press UNDO (CTRL+z)
The variable returns.
Now SAVE the .cap.
Then run it
And or enjoy a awful crash, or have a .cap with messed up variables.
Now how you trial ed and error d to come to the position you was in. I have no idea.
And, you must realize by now, that all traces to what exactly triggers the situation are gone.
Ashley, i hope you take that serious, even when its just coming from me.