Mouse events

  • Hi all,

    I'm making adventure / escape room game. I had problem with handling mouse / touch events. Seems like they always work for object that has lowest z-index. I did function for that, that is iterating through all special objects (family) I need (not many of them, like 30 maybe), and grabs one that is on top. It works fine with objects that are hidden/revealed dynamically and objects can be set to active/inactive. It works and does what I wanted, but there is problem with this approach.

    I also check if touch is touching family every frame, and it eats lot of cpu.

    I'm attaching event sheet screen and game screen (it serves for rotating knobs).

    Oh, I tested if it's picking objects is issue, but it turns out that "is touching <family>" conditions is causing this regardless of wwhat I do there.

    Maybe some of you had similar problems.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)