Dynamic way to cut sprite in half?

0 favourites
  • 2 posts
From the Asset Store
Firebase: Analytics, Dynamic Links, Remote Config, Performance, Crashlytics on Android, iOS & Web Browser
  • Is there a dynamic way to cut a sprite in half? Meaning, WITHOUT using either of the following:

    • Manually cutting them in half and creating animation frames
    • Piecing two halves together using the pin method, then using unpin to cut in half
    • Create a 2 new sprites, each containing one half and create it on top of the original sprite

    Is there any method, like dynamically copying part of an image onto another sprite?

    I have about 100 vehicles/sprites already created for an RTS game--when a unit is destroyed, I want to create an animation of the vehicle breaking into 2 halves. But to go back and create a "splitting animation" sprites for all 100 vehicles would probably take another month. Is there a faster, more dynamic/run-time way to do this?

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • If the collision mask is not important and all you need is to split the graphics, you can use a mask object.

    Create 2 mask objects (color the unwanted parts in black the rest leave transparent) and set the blending mode to Destination out

    On the layer settings where the object is on set:

    1. Transparent YES

    2. Force own texture YES

    Now create 2 instances of your object and the 2 masks and pin them to the object.

    If the mask is the same on both sides you can just mirror the same mask.

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