Sprite Spawned From Wrong Place

0 favourites
  • 3 posts
From the Asset Store
Spooky Places game assets for 2D endless runner action adventure game.
  • Problem Description

    Sprite is spawned from left side of other sprite instead of the specified image point.

    Attach a Capx

    https://onedrive.live.com/redir?resid=4 ... ile%2ccapx

    Description of Capx

    A red sprite spawns (shoots) a blue sprite from its origin every 0.5 seconds.

    Steps to Reproduce Bug

    • Step 1: Drag the red sprite to the left as if you tried to push it off screen. The red square is bound to layout
    • Step 2: Move the red sprite up and down as you try to push it off screen

    Observed Result

    The red sprite spawns a blue sprite from its left side.

    Expected Result

    The red sprite should shoot a blue sprite from its origin.

    Affected Browsers

    • Chrome: (YES)
    • FireFox: (YES)
    • Internet Explorer: (YES)

    Operating System and Service Pack

    Windows 8

    Construct 2 Version ID

    R227 (64 bit)

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Closing as won't fix: the problem is the "Bound to layout" behavior does its clamping after the events run, so it works in this order:

    1. drag-and-drop moves object outside layout

    2. event fires and spawns object

    3. bound-to-layout moves object back inside layout

    Changing this order will doubtless break other projects that depend on things working this way, so we can't really change it. It should be straightforwards to work around if you just do the layout bounding in events instead of with the behavior.

  • Yes, I have worked around it already, just wanted to inform you just in case.

    Thanks

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