-SOLVED-if/else conditionals etc

0 favourites
  • 3 posts
  • In my game, I have ui objects that if touched should perform a certain action. If they are not touched, they should be performing a different action.

    I dont have any problem checking and adding actions if they are touched. My problem is:

    How can I check if something is NOT being touched. And if NOT perform some actions.

    I come from more of a programming background and this is pretty much my main problem.

    I want to be able to do things like

    if(isTouchingObject)

    {

    do this!

    }

    else

    {

    Do something else!

    }

    I love the general ease and workflow of construct so far. But these types of things are where I am struggling.

    Or the ability to have NOT conditionals. Like saying

    if(!isTouchingObject)

    {

    do this!

    }

    I dont know if any sort of ability to do this exists or not. But help would be appreciated.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Right-click your event:Add:Add else

    Right-click your condition:Invert

  • Right-click your event:Add:Add else

    Right-click your condition:Invert

    Thank you! The ever elusive invert!

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