Files
src/miniquake2/physics/pmove.ml
Provides miniquake2 physics pmove facilities for this project.
- Package
miniquake2.physics.pmove- Reachable
- Yes
Imports
Declarations
# accelerate
function accelerate(localState, wishDirection, wishSpeed, acceleration)
Return the accelerate value.
| Parameter | Type | Default | Description |
|---|
localState | dynamic | — | localState value consumed by this operation. |
wishDirection | dynamic | — | wishDirection value consumed by this operation. |
wishSpeed | dynamic | — | wishSpeed value consumed by this operation. |
acceleration | dynamic | — | acceleration value consumed by this operation. |
View source
# addCurrents
function addCurrents(pmove, localState, wishVelocity)
Add currents.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
wishVelocity | dynamic | — | wishVelocity value consumed by this operation. |
View source
# addTouch
function addTouch(pmove, entity)
Add touch.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
entity | dynamic | — | entity value consumed by this operation. |
View source
# airAccelerate
function airAccelerate(localState, wishDirection, wishSpeed, acceleration)
Return the air accelerate value.
| Parameter | Type | Default | Description |
|---|
localState | dynamic | — | localState value consumed by this operation. |
wishDirection | dynamic | — | wishDirection value consumed by this operation. |
wishSpeed | dynamic | — | wishSpeed value consumed by this operation. |
acceleration | dynamic | — | acceleration value consumed by this operation. |
View source
# airMove
function airMove(pmove, localState, airAcceleration)
Move air.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
airAcceleration | dynamic | — | airAcceleration value consumed by this operation. |
View source
# categorizePosition
function categorizePosition(pmove, localState)
Return the categorize position.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# checkDuck
function checkDuck(pmove, localState)
Validate duck.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# checkJump
function checkJump(pmove, localState)
Validate jump.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# checkSpecialMovement
function checkSpecialMovement(pmove, localState)
Validate special movement.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# clampAngles
function clampAngles(pmove, localState)
Clamp angles.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# clipVelocity
function clipVelocity(inputVelocity, normal, overbounce)
Clip velocity.
| Parameter | Type | Default | Description |
|---|
inputVelocity | dynamic | — | inputVelocity value consumed by this operation. |
normal | dynamic | — | normal value consumed by this operation. |
overbounce | dynamic | — | overbounce value consumed by this operation. |
View source
# create
function create(traceCallback, pointContentsCallback)
Creates create for the miniquake2 physics pmove module.
| Parameter | Type | Default | Description |
|---|
traceCallback | dynamic | — | traceCallback value consumed by this operation. |
pointContentsCallback | dynamic | — | pointContentsCallback value consumed by this operation. |
View source
# deadMove
function deadMove(pmove, localState)
Move dead.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# flyMove
function flyMove(pmove, localState, doClip)
Move fly.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
doClip | dynamic | — | doClip value consumed by this operation. |
View source
# friction
function friction(pmove, localState)
Return the friction value.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# goodPosition
function goodPosition(pmove)
Return the good position.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
View source
# initialSnapPosition
function initialSnapPosition(pmove, localState)
Return the initial snap position.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# move
function move(pmove)
Move state.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
View source
# moveWithAirAcceleration
function moveWithAirAcceleration(pmove, airAcceleration)
Move with air acceleration.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
airAcceleration | dynamic | — | airAcceleration value consumed by this operation. |
View source
# moveWithAirAccelerationUsingLocal
function moveWithAirAccelerationUsingLocal(pmove, airAcceleration, localState)
The caller-supplied private state makes high-frequency client prediction allocation-stable. Server/game callers retain the owning wrapper below.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
airAcceleration | dynamic | — | airAcceleration value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# shortToAngle
function shortToAngle(value)
Performs the shortToAngle operation for the miniquake2 physics pmove module.
| Parameter | Type | Default | Description |
|---|
value | dynamic | — | Value consumed or transformed by the operation. |
View source
# signedShort
function signedShort(value)
Return the signed short value.
| Parameter | Type | Default | Description |
|---|
value | dynamic | — | Value consumed or transformed by the operation. |
View source
# snapPosition
function snapPosition(pmove, localState)
Return the snap position.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# stepSlideMove
function stepSlideMove(pmove, localState)
Advance slide move.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# stepSlideMoveCore
function stepSlideMoveCore(pmove, localState)
Advance slide move core.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source
# waterMove
function waterMove(pmove, localState)
Move water.
| Parameter | Type | Default | Description |
|---|
pmove | dynamic | — | pmove value consumed by this operation. |
localState | dynamic | — | localState value consumed by this operation. |
View source