Suggestion for collision detection

Discussion and feedback on Construct 2

Post » Thu Jul 21, 2011 1:25 am

I have some objects (sprites) and, put a variable to store the type of object (enemy, friend, and others). I wanted to check if an object (player) collide with any object or any sprite, then a sub-event checks the type then perform an action, but it is not possible.

It's possible, in a future version, add a condition like 'on collision with any object' or 'on collision with any sprite'?

So we'll can make generics conditions.

Sorry about my english, I don't speak this language highly, but i wish that text is understandable.
B
3
G
1
Posts: 5
Reputation: 585

Post » Thu Jul 21, 2011 1:55 am

So welblade is asking for an 'any' sprite instead of selecting each sprite and creating unique events. If that's correct, I'd like to add a suggestions for sprite groups and group selection for collision events or maybe an OR option, I'd prefer sprite groups and group selection for events.
B
11
S
6
G
1
Posts: 6
Reputation: 1,479

Post » Thu Jul 21, 2011 2:01 am

I think the "Families" feature from Classic solves this. We're still working on it for C2, but it basically allows you to group for example "Ork", "Troll" and "Monster" sprites in to one "Enemies" family. Then you can make events like "Player collides with Enemy".
Scirra Founder
B
359
S
214
G
72
Posts: 22,946
Reputation: 178,468

Post » Thu Jul 21, 2011 2:04 am

Ahh perfect, can't wait xD
B
11
S
6
G
1
Posts: 6
Reputation: 1,479

Post » Thu Jul 21, 2011 2:41 am

Is that! Is what I need, well if you is already work in it, I can stay restful
B
3
G
1
Posts: 5
Reputation: 585


Return to Construct 2 General

Who is online

Users browsing this forum: henryScirra and 11 guests