Skip to main content
Cleanup
Source Link
DMGregory
  • 141k
  • 23
  • 258
  • 401

How do games like Mount & Blade handle collisionsto implement a directional attacking/blocking system?

I have less of a technical question and more of a systemic / architectural question.

I'm working on implementing a directional attacking / blocking system in Unity à la Elder Scrolls: Arena or more recently, Mount & Blade - where moving the mouse in a certain direction signals a direction of attack. As expected, you will also be able to block in each direction, with each block direction countering the attack coming from the same direction.

I was wondering and hoping for some advice from more experienced developers, what are your thoughts on how to best implement this? Specifically: do I use colliders and actually make attacks physically collide with a potential shield or weapon in that direction? Or do I merely hold an enum with direction state and compare these values when a collision occurs.? Any further expanded ideas and suggestions are welcome! Thanks in advance.

How do games like Mount & Blade handle collisions?

I have less of a technical question and more of a systemic / architectural question.

I'm working on implementing a directional attacking / blocking system in Unity à la Elder Scrolls: Arena or more recently, Mount & Blade - where moving the mouse in a certain direction signals a direction of attack. As expected, you will also be able to block in each direction, with each block direction countering the attack coming from the same direction.

I was wondering and hoping for some advice from more experienced developers, what are your thoughts on how to best implement this? Specifically: do I use colliders and actually make attacks physically collide with a potential shield or weapon in that direction? Or do I merely hold an enum with direction state and compare these values when a collision occurs. Any further expanded ideas and suggestions are welcome! Thanks in advance.

How to implement a directional attacking/blocking system?

I'm working on implementing a directional attacking / blocking system in Unity à la Elder Scrolls: Arena or more recently, Mount & Blade - where moving the mouse in a certain direction signals a direction of attack. As expected, you will also be able to block in each direction, with each block direction countering the attack coming from the same direction.

I was wondering how to best implement this? Specifically: do I use colliders and actually make attacks physically collide with a potential shield or weapon in that direction? Or do I merely hold an enum with direction state and compare these values when a collision occurs? Any further expanded ideas and suggestions are welcome!

Source Link

How do games like Mount & Blade handle collisions?

I have less of a technical question and more of a systemic / architectural question.

I'm working on implementing a directional attacking / blocking system in Unity à la Elder Scrolls: Arena or more recently, Mount & Blade - where moving the mouse in a certain direction signals a direction of attack. As expected, you will also be able to block in each direction, with each block direction countering the attack coming from the same direction.

I was wondering and hoping for some advice from more experienced developers, what are your thoughts on how to best implement this? Specifically: do I use colliders and actually make attacks physically collide with a potential shield or weapon in that direction? Or do I merely hold an enum with direction state and compare these values when a collision occurs. Any further expanded ideas and suggestions are welcome! Thanks in advance.