I’m suggesting adding a new combat mechanic that introduces a vulnerability location on NPC’s, damage dealt to that region would be increased by a scalar.
I think Rangers charged shot, along with Musketeers weakness orb should have a percent chance of triggering this mechanic.
How vulnerability points would work in an ideal setting.
- Charged shot or weakness orb collides with NPC mesh at location P.
- Probability check for generating VP is done. If it is successful continue.
- Vulnerability Point graphic is attached to location P.
- Vulnerability Point graphic is set as a child element to the mesh, moving with the mesh animation.
- Sound clip plays, giving audio confirmation of a VP.
- Vulnerability Point has a short, fixed duration until it disappears (3 - 5s ?).
- Collisions within a certain radius of the vulnerability point will have damage scaled.
This mechanic would have many positive effects on gameplay.
- Rangers have limited group utility outside of raw dps, this would make them more desirable.
- Players would be rewarded for having better accuracy.
- Weakness orb would be utilized more often in small group settings.
- Combat would be more interactive, dynamic, and fun. (instead of aiming for a rectangular boundary box)
- World boss encounters with numerous VPs triggering would be awesome.
Realistic implementation of this mechanic
There are two major limiting factors for implementing VPs.
- Currently implemented collision detection is based upon a boundary box around the NPC, not on the mesh.
- VR is computationally demanding, the implementation would need to have a light CPU footprint.
My solution to these issues would be:
- For each NPC, manually (or algorithmically, more below) add a small number (10?) of pre-defined VP locations on the mesh and store them in array (VP array).
- When a charged shot or weakness orb collision occurs on the boundary box at point P_box, and a VP event is instantiated…
- Iterate through VP array, calculate each vector distance from P_box, activate VP node with smallest distance.
- When a collision is detected while at least one VP node is active…
- Again, iterate through VP array, calculate vector distance from new collision point P_collision, find VP node that minimizes the distance (VP_closest).
- If VP_closest node is active
- damage = VP_scalar * damage;
- else: normal damage.
This approach should have a light CPU footprint if VP_array is small, yet still allow for sufficiently accurate collision detection given the boundary box collision implementation.
Adding VP node sites to currently existing NPCs
This could be done manually, or perhaps algorithmically. My suggestion is below… in pseudo pseudo code.
- For each NPC:
- Iterate through each mesh point P.
*Iterate through each VP_point in VP_array.- Ensure distance between VP_point and P > some spread distance.
- Ensure Y component of P is within the interval (min height, max height).
- Ensure Z component of the vector orthonormal to the plane tangent of P, relative to world space, is within an interval (-z,z) where z is tailored to filter out VP points being generated underneath, and on top of the mesh.
- Push P into VP_array.
- If VP_array reaches the desired size, break.
- Iterate through each mesh point P.
I really think this mechanic could work and would add more depth to the repetitive NPC combat system. Thanks for reading.