UNDER THE HOOD: COLLISION & MELEE DAMAGE
Collision Damage is applied differently to weapon damage. Melee Damage (from Chompers, Choppers, Flippers, Rammers, etc.) simply works by creating collision damage.
We use the Havok physics engine. When two objects collide in the physics engine the engine gives us an “Impulse Magnitude”. The impulse magnitude is based on the mass and velocities of the two objects that are colliding. We use this impulse magnitude to create damage to the connections between blocks.
Two objects colliding and creating an impulse
Collision Sphere Cast
At the point of collision, we generate a Sphere Cast. The centre of the sphere is positioned at the point of the collision. The radius of the sphere is determined by the impulse magnitude.
Using the sphere we find all connections [on enemy robocraft blocks] that lie within the radius and do damage to them.
The amount of damage is based on the impulse magnitude and the distance from the centre of the sphere. The damage applied falls off with distance with an exponential relationship.
Collision Sphere Damage
Damage from collisions ignores penetration resistance completely. All connections within the sphere are affected.
NB: We plan to improve the collision damage model to better account for the structure of robocraft so that structural integrity is better taken into account when collisions occur possibly via some kind of ‘damage routing’ system more akin to how it worked in RC1 for collision damage. We believe the relatively random destruction that occurs during melee combat results from the over simplified sphere cast system that we use.