Prevent melee collision misses with one node that utilizes traces to handle fast attacks and low FPS situations.
Using Colliders for melee weapons can be less accurate than needed as they are framerate dependent, resulting in possible missed hits, and does not provide Hit Results, reducing the amount of information given from a collision.
Traces provide Hit Results but can also be also be framerate dependent and don't change size or rotation between their start and end position.
This pack provides a single, easy to use, blueprint node that "sweeps" the trace over the distance covered in a frame making it easy to detect any possible missed collisions between frames. During the sweep any size and rotation changes from the start to the end are handled using interpolation, as well as a calculation of the necessary amount of traces needed to cover the distance to prevent overuse of checks.
This was made with melee combat in mind to handle situations where colliders or normal traces would potentially skip over a hit. This can occur at low frame rates and/or fast moving melee attacks where the distance a weapon travels in one frame is larger than its collision size resulting in teleporting through objects.
A demo map is included to demonstrate how these BP nodes works and how to use them. Examples are set up to show how it works in one frame and how it looks in motion, with adjustable FPS limits to better show what is happening.
A set up with an example weapon is also included that shows a likely situation where one character attacks another and the hit character reacts to the hit by using physics animation to flinch and particles are played. This is done using the system and a set up of interfaces that lay the groundwork for a melee system by providing communication between the weapon, its owner, and the hit object.
Features:
Supported Development Platforms:
Windows: Yes
Mac: Yes
Documentation: See Enhanced Melee Trace Demo Map/Comments in BPs
Important/Additional Notes: Core Files in "Melee Trace" folder. All other folders are for examples.