Mirror image points?

0 favourites
  • 4 posts
From the Asset Store
Connect the dots in the correct order and draw happy animals!
  • Hello, I'm having some trouble getting my arm sprites to appear mirrored along with the body.

    So far I'm mirroring the player when facing left(A is down) and the arms are set to angle towards the Mouse position.

    Because of the angling, the arms are already facing the right way when shooting left so I cannot mirror them or they will appear backwards!

    An image of the issue:

    <img src="http://gyazo.com/8ed209d5bd3c7160be36f7e3bc8b1107.png" border="0" />

    Facing right

    <img src="http://gyazo.com/3c604aa4ec0fde15ca9e8502caf0788b.png" border="0" />

    The problem seems to be that the arms are still pinned to the non-mirrored image point.

    Here's my event sheet:

    <img src="http://gyazo.com/729e90544fccaf052a0027aab9af5169.png" border="0" />

    I tried setting the X position for when facing left:

    <img src="http://gyazo.com/2de8c02b9aa97d0355d579adbe245fec.png" border="0" />

    <img src="http://gyazo.com/6e9ad769c5f2d636b6882fe6e954c7cb.png" border="0" />

    and even tried a separate image point, but to no avail.

    dropbox.com/s/lmou2huc4bqtadp/myproject.capx

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • If you want to move a pinned object then you need to pin it again after you move it.

    So try doing 'set position to image point 2 / pin to player' after flipping the arms.

  • Pin has some benefits. However my experience is that Pin is only good for more LOCKED objects. Objects you don't intend to need to rotate, move in any more way.

    However if you need an an object like arms to stay at a certain image point. Your better off just leaving it in an auto update tick to reset the position.

    Since Pin has to set the new position anyways. Doing it manually has no over head loss.

    soo

    this is done every tick

    arm.setposition(player.imagepoint("arms")

    on Face Change

    player.mirror(yes)

    arms.mirrot(yes)

  • Ah, I see... was trying to avoid an every tick method assuming it'd use more memory but tried it anyway and it's working great!

    Will keep the Pin info. in mind.

    Thanks to both of you <img src="smileys/smiley1.gif" border="0" align="middle" />

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