[suggestion] Global and Local variables in properties bar

0 favourites
  • 14 posts
From the Asset Store
Globals 2.0
$3.99 USD
Globals 2.0 stores and group variables. You can also load and save data (variables) from/to JSON files.
  • Hi,

    Just think it would be very helpful to have a tab in properties bar with all global as well as local variables. Local would appear depending on events you are editing. I know you are working hard on c3, but would that thing be poss to add to c2? Thanks

  • I am not sure how this would help? Construct handles variables like any other IDE I have used for the most part. Some have the option of looking at different variable views, but never needed them (others might). Most of the dialogs work fine with auto-complete.

    Just wondering what benefit it would give. I keep my functions super small, so I always can see all my local variables as I go. Only thing missing is global variables, but I have never ever found myself scrolling through my code to look at them.

  • I think the auto-complete is fine for this. Beside, if you organize all those variables well, you should not have any trouble.

    Can you provide a use case that might show the benefit of your suggestion?

  • I think the auto-complete is fine for this. Beside, if you organize all those variables well, you should not have any trouble.

    Can you provide a use case that might show the benefit of your suggestion?

    Yes, when you are programming something with a lot of variables, creating lengthy events, it would be good to be able to quickly view and edit them, without the need to scroll back to where you keep them, and then scroll back down looking for the events you're working on. It's an unnecessary loop.

  • Why do you want to scroll back to where you keep them? You forgot their names?

    For me, if I have lots of global variables to be used and referred to, I will just use Snipping Tool to snapshot all those global variables, place the snapshot on the left side of the screen and place C2 on the right side.

  • Why do you want to scroll back to where you keep them? You forgot their names?

    For me, if I have lots of global variables to be used and referred to, I will just use Snipping Tool to snapshot all those global variables, place the snapshot on the left side of the screen and place C2 on the right side.

    Yes, when you use 20 or 30 you might get confused. Snapshot would occupy too much space. I have laptop with 15" screen.

  • As a workaround, why not put all the global variables in their own separate event sheet and keep it open in a tab up top? Then it's just one click and they're right there for you.

  • Why do you need them listed if you either choose them from a drop-down list or have them auto-completed as you type expressions?

  • Why do you need them listed if you either choose them from a drop-down list or have them auto-completed as you type expressions?

    They contain a lot of data, and its not easy to remember all of them. Many has similar names due to their function. I usually would use array, but I've learned that having variables with descriptive names is much easier to remember and speeds up workflow when creating sets of events, when doing maths for example using local variables, that are set in different events, and have random names like r or Num. Also, when you test, you'd want to be able to edit them faster then trough pop up.

    Btw, that's something I was thinking of mentioning, to have in the future variables editable together with their names and type within the even sheet and not in pop up.

  • do you have an example capx? I cannot picture this. It sounds like you are not working at efficiently as possible, but perhaps I am mis-understanding the situation.

  • I want to clarify, not trying to knock on you I am legitamately curious as to what purpose/use you would have for such a feature. Over the years I have used many IDE's, on many projects, and worked with many people. I have never once seen or heard of someone taking advantage of a variable browser. That said, I know some people must use them, because there is a plugin for it on Notepad++. I just have never personally encountered a real use case for it.

    Something that I have used and enjoy is a function viewer which I wish Construct had. The search feature is not that great in construct, so being able to click on a function I have created and going to it with all my code listed (unlike Search which hides code) would be awesome.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Also, when you test, you'd want to be able to edit them faster then trough pop up.

    I think I get it. It would be useful if you want to edit your variables in the event sheet inside a complex and possibly deeply nested code. In that case it could be helpful to see all the currently available variables in a separate place too and edit them on the fly.

  • > Also, when you test, you'd want to be able to edit them faster then trough pop up.

    >

    I think I get it. It would be useful if you want to edit your variables in the event sheet inside a complex and possibly deeply nested code. In that case it could be helpful to see all the currently available variables in a separate place too and edit them on the fly.

    Exactly. And when you running out of ideas for variables names, it would be good to just glance and remind yourself what variable name was, where it is located etc. as well as quickly edit. I have proposed properties tab, since it would be best place to display them, as well as you just could have a tab there you'd select.

    Global object with variables is an option but it wouldn't include local variables.

    I want to clarify, not trying to knock on you I am legitamately curious as to what purpose/use you would have for such a feature. Over the years I have used many IDE's, on many projects, and worked with many people. I have never once seen or heard of someone taking advantage of a variable browser. That said, I know some people must use them, because there is a plugin for it on Notepad++. I just have never personally encountered a real use case for it.

    Something that I have used and enjoy is a function viewer which I wish Construct had. The search feature is not that great in construct, so being able to click on a function I have created and going to it with all my code listed (unlike Search which hides code) would be awesome.

    When you loads of variables, list is really important too keep track of them. Unity has it for example. And yes, search feature is not the best one either, but it's not badr.

  • Why don't you use a word document or an excel sheet to keep track of the variables and their usage in each event sheets?

    Because that's what I do to avoid overlap and mishandling and to avoid bugging out features when doing maintenance on event sheets .

    It's not hard and take hardly a minute every hour of development.

    Because even if you know what variables have already been created, it would be quite difficult for you to remember where are all of them used and how.

    Best to just jot those down. Easier for maintenance and bug removal.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)