How do I fill many instance variables with automated action?

Get help using Construct 2

Post » Sat Feb 25, 2017 11:44 pm

Hello. I have a family class containing about 50 instance variables and several dictionaries with accordable pairs "variable name":"value".
I could create a function to manually apply each variable with 50 single actions, but that's very consuming, inconvenient and may cause errors, i.e. if I change family variable name and forget to fix key string.
Is there any way to transfer data from a dictionary, array or maybe JSON string automatically? Like "for each variable" action or something.

Here's example of what I need:
Image
B
8
S
1
G
2
Posts: 19
Reputation: 938

Post » Sun Feb 26, 2017 3:15 pm

Just found out about "Set from JSON" action to determine object's state but couldn't get any documentation or explanations. Can it be used to assign variables only?
B
8
S
1
G
2
Posts: 19
Reputation: 938


Return to How do I....?

Who is online

Users browsing this forum: tarek2, Yahoo [Bot] and 14 guests