Alon's Forum Posts

  • Hi All,

    How do I make the mouse to IGNORE any clicks?

    Not by clicking on specific object or area but on ANYTHING, just ignore the Mouse Clicking no matter where it clicks for X seconds.

    Thanks ahead!

    Tagged:

  • You do not have permission to view this post

  • Yes, what dop suggested is more like what I'll probably go for a "ready to use X number of Layers".

    It should do the job.

    My current code is based on controlling the Z-Order of the current layer, Basically: one layer of instances have 3 the default Z-Order: Top, Mid, Bottom I'm not using all the manual numbers for unlimited Z-Order since it also change their scale based on the camera), so what I may do is each layer + default 3 Z-Order (Top, Mid, Bottom).

    So 1 layer basically is not enough once there are plenty of other objects, (I just tried it, it's a mess) so I want to give the user some extra layers to have more control this is why I think I should add layers for the created instances.

    I'm didn't decide how to approach the control of each instance specifically yet because currently if the mouse cursor is OVER an instance, it picks the top one and using SCROLL DOWN I sent it down on the Z-Order of the current layer, SCROLL UP sent it to TOP... moving them to other layers I should also let the user KNOW on which layer it is, so I'll probably need to design a "VISUAL" layer icons, that was my original idea but please share your thoughts.

    I'm not sure if I can make it or not, because it could be complex for my level but I'll try to play with it soon and see for myself, I'm very hyped to try it already... I hope it's not too complicated.

    One thing is sure, I ALWAYS naming my Layers, I never use the numbers... so I can follow them on the code easily (and I already have plenty of layers for the core software).

  • My alternative idea was similar to this, creating a "ready to use" layers and play with them.

    or an easier approach to do just limit my users to X layers, I'm considering this because it could work and hopefully won't be hard to code as well.

    Thanks for the advice everyone! :)

  • Iirc it's not possible. What are you trying to do? Showing/Hiding it should be sufficient.

    No, showing and hiding is simple.

    My project is a creation toolset, I need to let my users to CREATE / USE / DELETE their own layers.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi All,

    Just to be clear, I'm not talking about the Editor.

    Is it possible to Create a layer + "Layer Name" and Remove/Delete it using Code?

    If possible, can someone please share an example file or screenshot to see how it's done?

    Thanks ahead!

    Tagged:

  • Thank you so much for the visual and written explanation, this is VERY helpful!

    I will look at it more carefully soon with C3 open :)

  • Thank you Everade this is what I was trying to achieve!

    Can you please explain what you did as I'm still a newbie that learning, if you can analyze what you did on specific lines or screenshot for more visual way to explain.

    I'm not just looking for copy/past but trying to learn and understand on the way, thanks for everything! :)

  • Ok i think this is what you want:

    https://gofile.io/?c=rm5mBB

    Thanks again for taking the time, Yes more or less this is the direction but notice if you tweak sliders on one instance than tweak another, when you reset it will tweak also the other instead of only the selected one only.

    Hehe sorry for the mess I'm still trying to solve this without super confusing code and I'm already lost easily...

  • I'm confused, i thought that's what you were looking for?!

    You said "reset to initial values".

    And that's exactly what it does.

    First of all I appreciate you're trying to help :)

    Sorry about my bad English, on my original thread I tried to explain what I'm trying to do:

    I'm trying to have "RESET" button for each slider so it can bring back both Variable and Knob Values to the original / initial numbers that I insert on the Instance Variable "Value".

    I wish I could describe it better.

  • That's cool! it seems like THERE IS some kind of a "system" in this Software Versioning.

    I still find this minor thing very interesting, thanks for sharing!

  • gofile.io

    I've set a default instance variable directly onto the knob.

    Of course your could also set local variables directly into the code.

    Or use global variables instead.

    But this should work just fine.

    Thanks for give it a try Everade I just had a quick look but it's just resetting the knobs.

    I mean, it doesn't do what I'm trying to achieve which is reset to the Default (initial) values and also put the knobs on the correct position.

  • I think I got closer by adding the Default variables, but once I got to the code I got lost again...

    can you please have a look and explain how can I clean up my mess? I think it should be more simple and maybe I over do it with unnecessary extra code because I got confused, so it's hard for me to follow the code even when I try to look at every line again and again.

    Thanks ahead for any help! :)

    DOWNLOAD another attempt of mine

  • Are people really too lazy to manually change a 1.0 to a 1.1 now?

    Not at all, the original thread is HOW it's done if there is a common known "system" that developers use to calculate the changes or rather just throwing numbers based on the size of the changes 0.001 / 0.1

  • The initial value code uses some variables but then these variables change. You need to create some instance variables that don't change to be used as default values. Then you can set the objects back to these original values. Your disabled code doesn't work because those values have changed. If instead it was self.defaultAdjustHSL_Value then it would work and you update another variable self.curAdjustHSL when the sliders move.

    Hmmm... so if I'll create EXTRA variables to start with like your example:

    self.defaultAdjustHSL and so on for each of the knobs, it will be possible to address them when pressing the button?

    I'm just trying to see if I understand the logic behind it before I'll be lost again, thanks! :)