SweptHit
Defined in: src/modules/collision/narrowphase.ts:72
Result of a swept AABB test: whether it hit, the surface normal, and tEntry (fraction of the motion travelled before impact).
Properties
Section titled “Properties”
readonlyhit:boolean
Defined in: src/modules/collision/narrowphase.ts:73
normal
Section titled “normal”
readonlynormal:Readonly<Vec2>
Defined in: src/modules/collision/narrowphase.ts:75
Collision normal on b’s surface (unit vector). {0,0} when no collision.
tEntry
Section titled “tEntry”
readonlytEntry:number
Defined in: src/modules/collision/narrowphase.ts:77
Fraction of motionA travelled before impact. 1 when no collision.