handling multiple player collisions

Get help using Construct 2

Post » Tue Nov 20, 2012 12:23 am

So for my fighting game, up to 4 player's can be on screen at one time.
Each player also has a large variety of moves, air attack, 4 way regular attack, and 4 way special attack.

I've built my game so that the player controller is a skeleton for each player. the move names have been labeled generically like side attack, and up attack, and up special so that when i obtain the animations for each character, I can drag and drop as much as possible.

How do I handle it so that when a player selects their character they each can attack each other, rather than saying If player 1 animation > on collision with player 2, or player 1 animation on collision with player 3   etc...

AND if i have mulitple moves, do I have to make a collision event for each move?

+ Is it better to use image points for attack collision, or full collision boxes (if possible)

bscarl882012-11-20 00:31:46
B
32
S
4
Posts: 405
Reputation: 3,219

Post » Sun Nov 25, 2012 11:10 pm

I guess I'll have to set it up player by player. But if I have 8 possible fighters, but only 4 player controllers MAX on screen at once, how do I make it so the user can select that character for the player 1-4 controllers?

I have my actions generic enough (sideattack, upattack, airattack etc.) that each character actions would be simple enough to implement.

B
32
S
4
Posts: 405
Reputation: 3,219

Post » Fri Dec 21, 2012 10:08 pm

Bump. Anyone? Please help.   I've been stuck on this forever!
B
32
S
4
Posts: 405
Reputation: 3,219

Post » Fri Dec 21, 2012 10:41 pm

Families

Put an invisible box over each player. Have collision boxes at the point of attack areas.

then check collision on families and use an owner value as to not cause self attacks :D
B
87
S
18
G
9
Posts: 2,455
Reputation: 14,834

Post » Sat Dec 22, 2012 3:28 pm

I guess I need to read on about how to use families! But this does make sense!    Then if I want to give each player individual controls, I would have to use families and ownership for the controls too.

I'm confused as to how to do the ownership variable though.

But thank you so much for your response!!!
B
32
S
4
Posts: 405
Reputation: 3,219


Return to How do I....?

Who is online

Users browsing this forum: Kagubro and 34 guests