coastline 0.0.4
Loading...
Searching...
No Matches
physicsimpact.h File Reference
#include "common/physics.h"
Include dependency graph for physicsimpact.h:

Go to the source code of this file.

Macros

#define MAX_IMPACT_SPEED   27.0f
 The speed a hit is counted up to for its sound.

Functions

static u8 ImpactVolume (f32 speed)
static void RecordImpact (RigidBody *body, f32 speed)
 Record a hard impact and its contact point in body.
static void RecordImpactVolume (RigidBody *body, f32 speed)
 Retain the loudest impact sound for body.

Macro Definition Documentation

◆ MAX_IMPACT_SPEED

#define MAX_IMPACT_SPEED   27.0f

The speed a hit is counted up to for its sound.

Function Documentation

◆ ImpactVolume()

u8 ImpactVolume ( f32 speed)
inlinestatic
Returns
The crash-sound volume corresponding to speed.

◆ RecordImpact()

void RecordImpact ( RigidBody * body,
f32 speed )
inlinestatic

Record a hard impact and its contact point in body.

◆ RecordImpactVolume()

void RecordImpactVolume ( RigidBody * body,
f32 speed )
inlinestatic

Retain the loudest impact sound for body.