Using Touch object for the buttons in the game.

0 favourites
  • 8 posts
From the Asset Store
This is a single chapter from the "Construct Starter Kit Collection". It is the Student Workbook for its Workshop.
  • My button will work?

    I am just going to submit a picture of my Event Sheet and tell me if my buttons will work when I will put my fingers over it when I play the game with a Touchscreen:

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Are your btnYes and btnNo objects of "Button" type? In this case don't use Touch events for them. Use btnYes -> On clicked event instead.

    If they are sprites, change events to Touch-> On touched object. "On touched" is a triggered event, it's triggered only once, which is what you normally want for menu buttons, toolbars, settings icons etc.

    "Is touching" is a continuous event, it's executed many times per second, while the finger is touching the object. You should use it for controls like a virtual joystick, firing button etc.

  • To dop2000:

    - What do you mean by Button Type? You mean the buttons that Construct 2 provides in the "Insert Object" box in "Form Controls"?

    - Are you saying that when we use the button provided by Construct 2 we don't need to add the Touch object because they will still be clickable when we play on a cellphone or a Tablet?

  • Yes, Button object under Form Controls. If you are using it, it has its own "On clicked" event which will also work on touch screen.

    But there are many problems with form controls (for example it's quite hard to change their appearance), and in many games it's better and easier to make buttons with sprites or text objects instead.

    By the way, you can easily test your game on touch screen of your phone using "Remote preview" option.

  • To dop2000:

    Thank you for your help! In your previous comment, you were talking about testing my game with my cell phone using the "Remote preview" option. But I will have to publish my game first and then submit my files on the web to be able to test it on my cellphone?

  • No! Simply start Remote Preview in Construct 3, it will give you a link, open that link on your phone. Takes 5 seconds.

  • To dop2000:

    First of all, I would like to know if the "Remote Preview" is available in the Free Edition of Construct 3?

    If the answer is yes, I would like to know how can I access the "Remote Preview" option (the steps).

    Thank you!

  • Menu -> Project -> Remote preview.

    But it doesn't work in free version.

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