[Suggestion] Mark instance variable as 'non-configurable'

Discussion and feedback on Construct 2

Post » Thu Aug 28, 2014 3:14 am

While working on a project, I find that I create several instance variables whose values get set by events while the game is running, and have no purpose being configured in the layout editor. At the same time, those same objects will have a couple variables that DO need to be configured in the layout editor, and those runtime-only variables clutter up the properties window and get in the way. It would be great if I could hide those runtime-only variables from the layout editor, so as to avoid confusing other people who also work on the project.

This is pretty minor in the grand scheme of things, but would still be nice to have.
B
54
S
19
G
13
Posts: 97
Reputation: 10,146

Post » Thu Aug 28, 2014 6:41 pm

Variable grouping would serve the same purpose, you could hide the non-configurable variables under an "internal" group or something like that. That also has the benefit of allowing you to configure variables in a sane way for other use-cases, such as my other post and followup

currently my solution is to name them _varname
B
36
S
8
G
8
Posts: 532
Reputation: 6,903

Post » Fri Aug 29, 2014 7:22 am

@Fimbul

I like this idea, though I think "Variable Namespaces" would be a more appropriate name.
B
54
S
19
G
13
Posts: 97
Reputation: 10,146

Post » Fri Aug 29, 2014 6:06 pm

"Namespaces" sounds too much like proper namespaces, which I guess is a worthwhile feature in it's own right.
Variable grouping, however, is purely cosmetic, and wouldn't affect the way variables work at all.
B
36
S
8
G
8
Posts: 532
Reputation: 6,903


Return to Construct 2 General

Who is online

Users browsing this forum: blackhornet and 26 guests