Pasting image into sprite then masking it

Get help using Construct 2

Post » Mon Mar 18, 2013 10:55 pm

Hi!

I want to load a portion of an image into a sprite, then masking it with another sprite.

I used Pode's ImageTextonSprite to do the first, but I can't do the masking part.

I tried scirra "destination atop" blending but, since back image is always bigger than the masking sprite, undesired effects appear when two sprites are next.

(I want to make a jigsaw puzzle, and I have a set of "jigsaw cuts" for the mask, this is why putting a mask near the other one matters).

B
40
S
12
G
5
Posts: 132
Reputation: 8,303

Post » Mon Mar 18, 2013 11:14 pm

I'd say preparing your sprites ahead of time with proper image editing software would be your best bet... but I guess it seems like you're trying to do it dynamically within your app. What kind of undesirable effects are you experiencing? Try make your masking sprite oversized?
Mistakes were made.
B
40
S
19
G
67
Posts: 1,049
Reputation: 38,502

Post » Mon Mar 18, 2013 11:17 pm

You can do it with the canvas plugin. Here's an example:
http://dl.dropbox.com/u/5426011/examples17/puzzle_piece.capx
B
82
S
26
G
63
Posts: 4,857
Reputation: 45,754

Post » Tue Mar 19, 2013 5:35 pm

@R0j0h0und: I thinked about using canvas (indeed I installed canvas and ImageTextOnSprite at the same time), but, as that lacked some "sprite" conditions, I gave up from using it.
I passed over the possibility of using a drag and drop behaviour.
B
40
S
12
G
5
Posts: 132
Reputation: 8,303


Return to How do I....?

Who is online

Users browsing this forum: Colludium, jeffige, makkancs, SparklingAir, Yahoo [Bot] and 18 guests