How do I pick only 1 text box

0 favourites
  • 3 posts
From the Asset Store
Pick Up Items Sound effects for your game, Take them for a ride right now and you will worry no more.
  • I highlight your score if you made the top 10 list. However, sometimes, there are multiple of the same score. How do I prevent the highlight from highlighting all the same score and just highlight 1?

  • Hi, there are many ways of doing this. You could pick the nth instance. If you have many objects in an layout I would suggest instance variables for that. I do it like that all the time. e.g.:

    1. Select your Textbox Object -> Create instance variable (value number). I always call my instance variable for that "Call_ID".

    2. Go to your Layout and select each instance of the object type and give it a diffrent "Call_ID" => e.g. for the first row highcore text object "1".

    3. If you now just wanna highlight that box you could use the following event: pick by comparison, then enter the two values ( the value "1" and the instances "Call_ID"). All following actions on this object type will just cause effect on this instance.

    Remember you don't have to do it with instance variable. Every object has allready an UID or ID. I prefere doing this with instance variables because you can (if needed) give two object elements the same "Call_ID".

    Hope this helps you. You can find a lot about this in the manual as well.

    Cheers Marco.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Thank for your help!

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