How to get X and Y UID coordinates?

0 favourites
  • 5 posts
From the Asset Store
Act on your instances, get/set their properties and variables only thanks to their UID. No more picking trouble! Plugin
  • I have a sprite which act as spawn point.

    I duplicated it that I have many instances of this object on the stage.

    Now every X seconds I want an object that spawns at the the different positions of the spawn point instances.

    How do a get the UID X and Y coordinate of my spawn point?

    I know it should look something like this:

    System / when spawn variable = 1 / create object at (SPAWN_POINT UID number and X coordinate, SPAWN_POINT UID number and Y coordinate)

    but I have no idea what is the right expression...

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Guys I am not mother tongue, i noticed that what I wrote up here is a bit messed up.

    Anyway to make it simple:

    this expression get the X coordinate of the IID of an object:

    Sprite(1).X

    what's the equivalent expression to get the X coordinate of the UID of an object?

    here's the link where I found the IID expression, but I couldn't found the UID equivalent

    scirra.com/manual/78/expressions

  • First, you should use the 'pick by UID' condition, then just use Sprite.X.

    So,

    Sprite -> Pick by UID

           -> Sprite.X

  • First, you should use the 'pick by UID' condition, then just use Sprite.X.

    So,

    Sprite -> Pick by UID

           -> Sprite.X

    Just beat me to it. Exactly what "Joskin" said.

  • thank you so much!!!

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