Never use variables in C2, only dictionaries

Discussion and feedback on Construct 2

Post » Tue Feb 23, 2016 5:00 pm

Yeah, picking is another useful variable use case
B
45
S
11
G
4
Posts: 517
Reputation: 7,398

Post » Tue Feb 23, 2016 8:50 pm

I'm going to chime in that while dicitonary's and variables are mostly interchangeable in terms of function, variables are autofilled when entering expressions and dictionary keys are not. Instance variables are also logically tied to their objects for picking purposes. Local variables are automatically clean up after themselves. All of these together save me immeasurable amounts of time and brainpower (which unfortunately is always in limited supply).


As for storing data in any significant quantity, I always resort to arrays as they are much more flexible in what you can do with them.
Mistakes were made.
B
54
S
28
G
115
Posts: 1,705
Reputation: 65,083

Post » Thu Feb 25, 2016 10:00 am

I use variables and arrays and I usually keep a word document to remind me what each do aside from the normal UI comment.

This is because having a single document telling me all the available variables and arrays I have created and their existing usage is pretty helpful to avoid redundancy which in turn reduce the amount of work when you maintain and improve your project.

I don't use dictionary since array is more useful to me due to official support and their functionality and speed is nearly similar.
B
36
S
18
G
11
Posts: 248
Reputation: 8,694

Post » Thu Feb 25, 2016 10:03 am

I have external file with data to use with ajax and tokens. Having that kind of linear format of data works best for me. With external arrays there is so much to think about in terms of layout that I just can't be asked.
My professional Royalty Free Music at Scirra Assets Store
--------------------------------
Specs: i5 2500, 16gb of ram, gtx 770, win 7, Focusrite Scarlett 8i6, Mackie mr8mk2, Alesis 320, browsing the net on chrome.
B
93
S
30
G
22
Posts: 1,987
Reputation: 20,203

Previous

Return to Construct 2 General

Who is online

Users browsing this forum: No registered users and 5 guests