How do I Collision with multiple objects

Get help using Construct 2

Post » Tue Jun 13, 2017 9:43 pm

1 - I'm doing a fighting game between two base
2 - Both sides create units to fight each other.
3 - The problem is when the units meet :(
Instead of just attacking a single enemy unit, it ends up dealing damage to several other units that are together.
How do I attack him one at a time?
.CAPX
https://mega.nz/#!5bg10TBZ!QOleGSxRMazB ... fazKbswUio
Translate PT/BR
B
22
S
2
Posts: 43
Reputation: 972

Post » Wed Jun 14, 2017 4:24 am

I had this problem also until I learned that you can add an EXTRA condition using OBJECT that is colliding to PICK INSTANCES using the Z ORDER where you can say for example pick the top one when many collide.

So:
1) OBJECT #1 collides with OBJECT #2
and 1 more condition: OBJECT #2 Z ORDER pick top/bottom > top
>> ACTION: badaboom badabang :)

That will solve your problem :)
Thank you to Construct 2 for giving me the ability to create games without programming knowledge.

My games & gaming portal = DolyGames

If anyone wants to cooperate to help each other Win-Win please email me - I am always happy to discover new opportunities.

Cheers,

COSMOS
B
20
S
9
G
1
Posts: 75
Reputation: 2,152

Post » Wed Jun 14, 2017 2:19 pm

DolyGamesCosmos wrote:I had this problem also until I learned that you can add an EXTRA condition using OBJECT that is colliding to PICK INSTANCES using the Z ORDER where you can say for example pick the top one when many collide.

So:
1) OBJECT #1 collides with OBJECT #2
and 1 more condition: OBJECT #2 Z ORDER pick top/bottom > top
>> ACTION: badaboom badabang :)

That will solve your problem :)

Perfect!!! Saved my project
Thank you very much =D
B
22
S
2
Posts: 43
Reputation: 972

Post » Wed Jun 14, 2017 6:10 pm

Governador wrote:
DolyGamesCosmos wrote:I had this problem also until I learned that you can add an EXTRA condition using OBJECT that is colliding to PICK INSTANCES using the Z ORDER where you can say for example pick the top one when many collide.

So:
1) OBJECT #1 collides with OBJECT #2
and 1 more condition: OBJECT #2 Z ORDER pick top/bottom > top
>> ACTION: badaboom badabang :)

That will solve your problem :)

Perfect!!! Saved my project
Thank you very much =D


My pleasure :)
Thank you to Construct 2 for giving me the ability to create games without programming knowledge.

My games & gaming portal = DolyGames

If anyone wants to cooperate to help each other Win-Win please email me - I am always happy to discover new opportunities.

Cheers,

COSMOS
B
20
S
9
G
1
Posts: 75
Reputation: 2,152


Return to How do I....?

Who is online

Users browsing this forum: leena222, tatogame and 19 guests