MiniQuake

src/miniquake/client_render_handoff.ml

Package
miniquake.client_render_handoff
Reachable
Yes

Imports

Declarations

BEAM_STEP

const BEAM_STEP = 30.

Defines the beam step value used by `miniquake.client_render_handoff`.

View source

beamAngles

function beamAngles(startPosition, endPosition)

Return beam angles derived from the active module state.

ParameterTypeDefaultDescription
startPositiondynamic—The start position input consumed by `beamAngles`.
endPositiondynamic—The end position input consumed by `beamAngles`.

View source

beamModelName

function beamModelName(type)

Return beam model name derived from the active module state.

ParameterTypeDefaultDescription
typedynamic—The type input consumed by `beamModelName`.

View source

beamSegmentOrigins

function beamSegmentOrigins(startPosition, endPosition, limit)

Return beam segment origins derived from the active module state.

ParameterTypeDefaultDescription
startPositiondynamic—The start position input consumed by `beamSegmentOrigins`.
endPositiondynamic—The end position input consumed by `beamSegmentOrigins`.
limitdynamic—The limit input consumed by `beamSegmentOrigins`.

View source

buildTemporaryEntities

function buildTemporaryEntities(compactBeams, client, currentTime, visibleCount)

Mirrors CL_UpdateTEnts: reset per-frame temp storage, update player-owned beam starts, append 30-unit model segments, and stop at either shared cap.

ParameterTypeDefaultDescription
compactBeamsdynamic—The compact beams input consumed by `buildTemporaryEntities`.
clientdynamic—Client state participating in the operation.
currentTimedynamic—Time value used by the operation.
visibleCountdynamic—Number of entries or units to process.

View source

clearTemporaryEntities

function clearTemporaryEntities()

Update module state for temporary entities.

View source

compactBeamStart

function compactBeamStart(value, viewEntity, viewOrigin)

Implements the `compactBeamStart` operation for `miniquake.client_render_handoff` (compact beam start).

ParameterTypeDefaultDescription
valuedynamic—Value consumed by `compactBeamStart`.
viewEntitydynamic—The view entity input consumed by `compactBeamStart`.
viewOrigindynamic—The view origin input consumed by `compactBeamStart`.

View source

currentTemporary

currentTemporary

Tracks the module-level current temporary state owned by `miniquake.client_render_handoff`.

View source

currentTemporaryEntities

function currentTemporaryEntities()

Return temporary entities.

View source

emptyTemporary

emptyTemporary

Tracks the module-level empty temporary state owned by `miniquake.client_render_handoff`.

View source

makeBeamEntity

function makeBeamEntity(number, modelIndex, origin, angles, currentTime)

Create and initialize beam entity.

ParameterTypeDefaultDescription
numberdynamic—The number input consumed by `makeBeamEntity`.
modelIndexdynamic—Zero-based index of the requested entry.
origindynamic—World-space origin of the operation.
anglesdynamic—Orientation angles used by the operation.
currentTimedynamic—Time value used by the operation.

View source

MAX_BEAMS

const MAX_BEAMS = 24

Defines the max beams value used by `miniquake.client_render_handoff`.

View source

MAX_TEMP_ENTITIES

const MAX_TEMP_ENTITIES = 64

Defines the max temp entities value used by `miniquake.client_render_handoff`.

View source

modelIndexForName

function modelIndexForName(client, name)

Return model index for name derived from the active module state.

ParameterTypeDefaultDescription
clientdynamic—Client state participating in the operation.
namedynamic—Stable name that identifies the requested object or option.

View source

precacheBeamModels

function precacheBeamModels(client)

CL_InitTEnts owns the lightning models rather than receiving them in the server model list. Register them during signon so the first beam does not parse and upload a model while gameplay is already visible.

ParameterTypeDefaultDescription
clientdynamic—Client state participating in the operation.

View source

renderFloat

function renderFloat(value)

Render float.

ParameterTypeDefaultDescription
valuedynamic—Value consumed by `renderFloat`.

View source

submitEntities

function submitEntities(visibleEntities, temporaryEntities)

Submit state for submit entities.

ParameterTypeDefaultDescription
visibleEntitiesdynamic—The visible entities input consumed by `submitEntities`.
temporaryEntitiesdynamic—The temporary entities input consumed by `submitEntities`.

View source

submitMirrorEntities

function submitMirrorEntities(visibleEntities, temporaryEntities, viewEntity)

Submit state for submit mirror entities.

ParameterTypeDefaultDescription
visibleEntitiesdynamic—The visible entities input consumed by `submitMirrorEntities`.
temporaryEntitiesdynamic—The temporary entities input consumed by `submitMirrorEntities`.
viewEntitydynamic—The view entity input consumed by `submitMirrorEntities`.

View source