Colision from a transparent image

Get help using Construct 2

Post » Mon Jan 20, 2014 7:22 pm

I need Construct 2 to detect the collisions on a transparent png image. How can I do that?

Sample: A maze image in black and white

I want only the black part to have solid behaviour.
B
5
Posts: 21
Reputation: 348

Post » Mon Jan 20, 2014 7:23 pm

white is transparent...
B
5
Posts: 21
Reputation: 348

Post » Mon Jan 20, 2014 7:50 pm

Can you post the capx? You can change the collide area in Sprite Editor, the last icon on left. "Set collide polygon".

B
6
S
2
Posts: 9
Reputation: 564

Post » Mon Jan 20, 2014 8:05 pm

You can't do that in "normal way". C2 don't have per pixel collisions. What you can do is to recreate your black and white maze image in layout editor using sprites, tilebg, or even tilemap.
ImageImageImageImage
B
157
S
66
G
42
Posts: 2,603
Reputation: 35,343

Post » Mon Jan 20, 2014 8:09 pm

Are you asking about one image/ multiple collision boxes ?

have a look here
August 2015 - I misplaced a lot of links - I will try to find backups and repost. If You find a post that interests please reply to post with @rampackwobble and I will get a nudge!

If you find my posts useful please consider donating something to a local charity or to the http://www.mndassociation.org/
B
64
S
34
G
47
Posts: 1,194
Reputation: 30,882

Post » Mon Jan 20, 2014 8:41 pm

Yes, it's only one png image. It's very difficult to recreate one maze in the layout editor. Example: w w w . j o k e l i b r a r y . n e t / yyDrawings/math/maze2a.gif
B
5
Posts: 21
Reputation: 348


Return to How do I....?

Who is online

Users browsing this forum: AllanR, Artcadev and 13 guests