Files
src/miniquake/server.ml
- Package
miniquake.server- Reachable
- Yes
Imports
Declarations
# acceptLocal
function acceptLocal(server, socket)
Implements the `acceptLocal` operation for `miniquake.server` (accept local).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
socket | dynamic | — | Network socket used for communication. |
View source
# appendBaselines
function appendBaselines(server)
Add state for append baselines.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# appendDatagram
function appendDatagram(destination, source)
Add state for append datagram.
| Parameter | Type | Default | Description |
|---|
destination | dynamic | — | Destination value or collection to update. |
source | dynamic | — | Source value or collection to read. |
View source
# appendQuakeCSignon
function appendQuakeCSignon(server, contextValue)
Add state for append quake csignon.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
contextValue | dynamic | — | The context value input consumed by `appendQuakeCSignon`. |
View source
# assignModelIndexes
function assignModelIndexes(server)
Implements the `assignModelIndexes` operation for `miniquake.server` (assign model indexes).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# beginChangeLevel
function beginChangeLevel(server)
Initialize state for begin change level.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# boolArray
function boolArray(count, defaultValue)
----------------------------------------------------------------------------- QuakeC-backed server spawning and per-frame execution. -----------------------------------------------------------------------------
| Parameter | Type | Default | Description |
|---|
count | dynamic | — | Number of entries or units to process. |
defaultValue | dynamic | — | The default value input consumed by `boolArray`. |
View source
# boundsOverlap
function boundsOverlap(originA, minsA, maxsA, originB, minsB, maxsB)
Implements the `boundsOverlap` operation for `miniquake.server` (bounds overlap).
| Parameter | Type | Default | Description |
|---|
originA | dynamic | — | The origin a input consumed by `boundsOverlap`. |
minsA | dynamic | — | The mins a input consumed by `boundsOverlap`. |
maxsA | dynamic | — | The maxs a input consumed by `boundsOverlap`. |
originB | dynamic | — | The origin b input consumed by `boundsOverlap`. |
minsB | dynamic | — | The mins b input consumed by `boundsOverlap`. |
maxsB | dynamic | — | The maxs b input consumed by `boundsOverlap`. |
View source
# broadcastPrint
function broadcastPrint(server, text)
Implements the `broadcastPrint` operation for `miniquake.server` (broadcast print).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
text | dynamic | — | Text to parse or process. |
View source
# buildModelPrecache
function buildModelPrecache(server)
Create and initialize model precache.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# buildSignon
function buildSignon(server)
Create and initialize signon.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# cleanMapName
function cleanMapName(name)
Return clean map name derived from the active module state.
| Parameter | Type | Default | Description |
|---|
name | dynamic | — | Stable name that identifies the requested object or option. |
View source
# cleanupMuzzleFlashes
function cleanupMuzzleFlashes(server)
Implements the `cleanupMuzzleFlashes` operation for `miniquake.server` (cleanup muzzle flashes).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# clearInvisibleClientTargets
function clearInvisibleClientTargets(server, clientValue)
Drop references from active monsters to a player who has become invisible. FL_NOTARGET prevents new checkclient acquisitions; clearing existing enemy state makes the custom command take effect immediately for alerted monsters.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `clearInvisibleClientTargets`. |
View source
# clientFloat
function clientFloat(server, clientValue, fieldName, fallback)
Implements the `clientFloat` operation for `miniquake.server` (client float).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `clientFloat`. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# clientItems
function clientItems(server, entityIndex, player)
Implements the `clientItems` operation for `miniquake.server` (client items).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
player | dynamic | — | The player input consumed by `clientItems`. |
View source
# clientMessageBuffers
function clientMessageBuffers(server)
Implements the `clientMessageBuffers` operation for `miniquake.server` (client message buffers).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# clientPrint
function clientPrint(clientValue, text)
Implements the `clientPrint` operation for `miniquake.server` (client print).
| Parameter | Type | Default | Description |
|---|
clientValue | dynamic | — | The client value input consumed by `clientPrint`. |
text | dynamic | — | Text to parse or process. |
View source
# clientSpawnParmBuffers
function clientSpawnParmBuffers(server)
Implements the `clientSpawnParmBuffers` operation for `miniquake.server` (client spawn parm buffers).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# clientWeaponModelIndex
function clientWeaponModelIndex(server, entityIndex, fallback)
Return client weapon model index derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# colorComponent
function colorComponent(value)
Implements the `colorComponent` operation for `miniquake.server` (color component).
| Parameter | Type | Default | Description |
|---|
value | dynamic | — | Value consumed by `colorComponent`. |
View source
# commandText
function commandText(args, first)
Implements the `commandText` operation for `miniquake.server` (command text).
| Parameter | Type | Default | Description |
|---|
args | dynamic | — | Command-line arguments supplied by the host process. |
first | dynamic | — | The first input consumed by `commandText`. |
View source
# copyGlobalsToSpawnParms
function copyGlobalsToSpawnParms(server, clientValue)
Transfer data for copy globals to spawn parms.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `copyGlobalsToSpawnParms`. |
View source
# copyNumberArray
function copyNumberArray(values)
Transfer data for copy number array.
| Parameter | Type | Default | Description |
|---|
values | dynamic | — | The values input consumed by `copyNumberArray`. |
View source
# copySpawnParmsToGlobals
function copySpawnParmsToGlobals(server, clientValue)
Transfer data for copy spawn parms to globals.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `copySpawnParmsToGlobals`. |
View source
# create
function create(maxClients)
Implements the `create` operation for `miniquake.server` (create).
| Parameter | Type | Default | Description |
|---|
maxClients | dynamic | — | The max clients input consumed by `create`. |
View source
# createEdictRuntime
function createEdictRuntime(maxEdicts, reservedClients)
Create and initialize edict runtime.
| Parameter | Type | Default | Description |
|---|
maxEdicts | dynamic | — | The max edicts input consumed by `createEdictRuntime`. |
reservedClients | dynamic | — | The reserved clients input consumed by `createEdictRuntime`. |
View source
# createQuakeCContext
function createQuakeCContext(server, filesystem, registry, commandSystem, runtime)
Create and initialize quake ccontext.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
filesystem | dynamic | — | The filesystem input consumed by `createQuakeCContext`. |
registry | dynamic | — | The registry input consumed by `createQuakeCContext`. |
commandSystem | dynamic | — | The command system input consumed by `createQuakeCContext`. |
runtime | dynamic | — | Time value used by the operation. |
View source
# createServerClient
function createServerClient(index)
Create and initialize server client.
| Parameter | Type | Default | Description |
|---|
index | dynamic | — | Zero-based index of the requested entry. |
View source
# defaultLightStyles
function defaultLightStyles()
Implements the `defaultLightStyles` operation for `miniquake.server` (default light styles).
View source
# distributeReliableDatagram
function distributeReliableDatagram(server)
Implements the `distributeReliableDatagram` operation for `miniquake.server` (distribute reliable datagram).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# dropClient
function dropClient(server, client, crashed)
Release state for drop client.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
crashed | dynamic | — | The crashed input consumed by `dropClient`. |
View source
# dropTimedOutClients
function dropTimedOutClients(server, timeoutSeconds)
Release state for drop timed out clients.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
timeoutSeconds | dynamic | — | The timeout seconds input consumed by `dropTimedOutClients`. |
View source
# ensureSynchronizedBaseline
function ensureSynchronizedBaseline(item, entityIndex)
Ensure sufficient storage or state for synchronized baseline.
| Parameter | Type | Default | Description |
|---|
item | dynamic | — | The item input consumed by `ensureSynchronizedBaseline`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
View source
# ensureSynchronizedEdict
function ensureSynchronizedEdict(server, entityIndex)
Ensure sufficient storage or state for synchronized edict.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
View source
# entityCenter
function entityCenter(item)
Implements the `entityCenter` operation for `miniquake.server` (entity center).
| Parameter | Type | Default | Description |
|---|
item | dynamic | — | The item input consumed by `entityCenter`. |
View source
# entityFloatValue
function entityFloatValue(server, item, fieldName, fallback)
Return entity float value derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
item | dynamic | — | The item input consumed by `entityFloatValue`. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# entityIsPriorityProjectile
function entityIsPriorityProjectile(item)
Report whether an entity is a latency-sensitive projectile that must be scheduled before ordinary snapshot entities. Rockets and expansion-pack missiles use MOVETYPE_FLYMISSILE; the stock grenade is a bouncing entity and therefore also needs its model-name discriminator.
| Parameter | Type | Default | Description |
|---|
item | dynamic | — | The item input consumed by `entityIsPriorityProjectile`. |
View source
# entityUpdateBits
function entityUpdateBits(server, item)
Return entity update bits derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
item | dynamic | — | The item input consumed by `entityUpdateBits`. |
View source
# entityUpdateValues
function entityUpdateValues(server, item)
Return entity update values derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
item | dynamic | — | The item input consumed by `entityUpdateValues`. |
View source
# entityVisible
function entityVisible(server, pvs, item, clientEdict)
Report whether entity visible holds for the active state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
pvs | dynamic | — | The pvs input consumed by `entityVisible`. |
item | dynamic | — | The item input consumed by `entityVisible`. |
clientEdict | dynamic | — | The client edict input consumed by `entityVisible`. |
View source
# executePusherThink
function executePusherThink(server, pusherIndex)
Execute pusher think.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
pusherIndex | dynamic | — | Zero-based index of the requested entry. |
View source
# executeQcFunction
function executeQcFunction(server, functionName, selfIndex, otherIndex)
Execute qc function.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
functionName | dynamic | — | Name that identifies the requested value or resource. |
selfIndex | dynamic | — | Zero-based index of the requested entry. |
otherIndex | dynamic | — | Zero-based index of the requested entry. |
View source
# executeStringCommand
function executeStringCommand(server, client, text, player)
Execute string command.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
text | dynamic | — | Text to parse or process. |
player | dynamic | — | The player input consumed by `executeStringCommand`. |
View source
# failSpawn
function failSpawn(server, result)
Report spawn and return the corresponding failure status.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
result | dynamic | — | Result value to report or translate into a status code. |
View source
# finishChangeLevel
function finishChangeLevel(server, snapshot)
Finalize state for finish change level.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
snapshot | dynamic | — | The snapshot input consumed by `finishChangeLevel`. |
View source
# flushQuakeCEvents
function flushQuakeCEvents(server)
Implements the `flushQuakeCEvents` operation for `miniquake.server` (flush quake c events).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# frame
function frame(server, player, frameTime, registry)
Implements the `frame` operation for `miniquake.server` (frame).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
player | dynamic | — | The player input consumed by `frame`. |
frameTime | dynamic | — | Time value used by the operation. |
registry | dynamic | — | The registry input consumed by `frame`. |
View source
# frameMode
function frameMode(server, player, frameTime, registry, simulate)
Advance mode by one processing step.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
player | dynamic | — | The player input consumed by `frameMode`. |
frameTime | dynamic | — | Time value used by the operation. |
registry | dynamic | — | The registry input consumed by `frameMode`. |
simulate | dynamic | — | The simulate input consumed by `frameMode`. |
View source
# globalSpawnParmOffset
function globalSpawnParmOffset(machine, index)
Return global spawn parm offset derived from the active module state.
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `globalSpawnParmOffset`. |
index | dynamic | — | Zero-based index of the requested entry. |
View source
# hasBspSuffix
function hasBspSuffix(name)
Report whether bsp suffix.
| Parameter | Type | Default | Description |
|---|
name | dynamic | — | Stable name that identifies the requested object or option. |
View source
# Host_Begin_f
function Host_Begin_f(clientValue)
Apply the Quake-compatible host begin f behavior.
| Parameter | Type | Default | Description |
|---|
clientValue | dynamic | — | The client value input consumed by `Host_Begin_f`. |
View source
# Host_Color_f
function Host_Color_f(server, clientValue, args)
Apply the Quake-compatible host color f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Color_f`. |
args | dynamic | — | Command-line arguments supplied by the host process. |
View source
# Host_Fly_f
function Host_Fly_f(server, clientValue)
Apply the Quake-compatible host fly f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Fly_f`. |
View source
# Host_Give_f
function Host_Give_f(server, clientValue, args)
Apply the Quake-compatible host give f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Give_f`. |
args | dynamic | — | Command-line arguments supplied by the host process. |
View source
# Host_God_f
function Host_God_f(server, clientValue)
Apply the Quake-compatible host god f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_God_f`. |
View source
# Host_Invisible_f
function Host_Invisible_f(server, clientValue)
Toggle the MiniQuake AI-invisibility cheat. The stock FL_NOTARGET bit keeps standard QuakeC and compatible mods on their original target-selection path.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Invisible_f`. |
View source
# Host_Kick_f
function Host_Kick_f(server, sourceClient, args)
Apply the Quake-compatible host kick f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
sourceClient | dynamic | — | The source client input consumed by `Host_Kick_f`. |
args | dynamic | — | Command-line arguments supplied by the host process. |
View source
# Host_Kill_f
function Host_Kill_f(server, clientValue)
Apply the Quake-compatible host kill f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Kill_f`. |
View source
# Host_Name_f
function Host_Name_f(server, clientValue, args)
Apply the Quake-compatible host name f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Name_f`. |
args | dynamic | — | Command-line arguments supplied by the host process. |
View source
# Host_Noclip_f
function Host_Noclip_f(server, clientValue)
Apply the Quake-compatible host noclip f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Noclip_f`. |
View source
# Host_Notarget_f
function Host_Notarget_f(server, clientValue)
Apply the Quake-compatible host notarget f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Notarget_f`. |
View source
# Host_Pause_f
function Host_Pause_f(server, clientValue)
Apply the Quake-compatible host pause f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Pause_f`. |
View source
# Host_Ping_f
function Host_Ping_f(server, requester)
Apply the Quake-compatible host ping f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
requester | dynamic | — | The requester input consumed by `Host_Ping_f`. |
View source
# Host_PreSpawn_f
function Host_PreSpawn_f(server, clientValue)
Apply the Quake-compatible host pre spawn f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_PreSpawn_f`. |
View source
# Host_Say
function Host_Say(server, sender, args, teamOnly)
Apply the Quake-compatible host say behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
sender | dynamic | — | The sender input consumed by `Host_Say`. |
args | dynamic | — | Command-line arguments supplied by the host process. |
teamOnly | dynamic | — | The team only input consumed by `Host_Say`. |
View source
# Host_Say_f
function Host_Say_f(server, sender, args)
Apply the Quake-compatible host say f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
sender | dynamic | — | The sender input consumed by `Host_Say_f`. |
args | dynamic | — | Command-line arguments supplied by the host process. |
View source
# Host_Say_Team_f
function Host_Say_Team_f(server, sender, args)
Apply the Quake-compatible host say team f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
sender | dynamic | — | The sender input consumed by `Host_Say_Team_f`. |
args | dynamic | — | Command-line arguments supplied by the host process. |
View source
# Host_Spawn_f
function Host_Spawn_f(server, clientValue, player)
Apply the Quake-compatible host spawn f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `Host_Spawn_f`. |
player | dynamic | — | The player input consumed by `Host_Spawn_f`. |
View source
# Host_Status_f
function Host_Status_f(server, requester)
Apply the Quake-compatible host status f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
requester | dynamic | — | The requester input consumed by `Host_Status_f`. |
View source
# Host_Tell_f
function Host_Tell_f(server, sender, args)
Apply the Quake-compatible host tell f behavior.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
sender | dynamic | — | The sender input consumed by `Host_Tell_f`. |
args | dynamic | — | Command-line arguments supplied by the host process. |
View source
# loadEdicts
function loadEdicts(server, map)
Read and validate edicts.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
map | dynamic | — | The map input consumed by `loadEdicts`. |
View source
# makePlayerEdict
function makePlayerEdict(number)
Create and initialize player edict.
| Parameter | Type | Default | Description |
|---|
number | dynamic | — | The number input consumed by `makePlayerEdict`. |
View source
# modelIndex
function modelIndex(server, name)
Return model index derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
name | dynamic | — | Stable name that identifies the requested object or option. |
View source
# movePusher
function movePusher(server, pusherIndex, moveTime)
SV_PushMove. The pusher is moved first, every affected entity is carried by the same delta, and the complete operation is rolled back when one entity cannot be displaced. This is the stock Quake door/platform/train contract.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
pusherIndex | dynamic | — | Zero-based index of the requested entry. |
moveTime | dynamic | — | Time value used by the operation. |
View source
# moveQcEntity
function moveQcEntity(server, entityIndex, frameTime, gravity)
Transfer data for move qc entity.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
frameTime | dynamic | — | Time value used by the operation. |
gravity | dynamic | — | The gravity input consumed by `moveQcEntity`. |
View source
# numberArray
function numberArray(count, defaultValue)
Implements the `numberArray` operation for `miniquake.server` (number array).
| Parameter | Type | Default | Description |
|---|
count | dynamic | — | Number of entries or units to process. |
defaultValue | dynamic | — | The default value input consumed by `numberArray`. |
View source
# physicsFrameParameters
function physicsFrameParameters(registry)
Apply server-physics frame parameters semantics.
| Parameter | Type | Default | Description |
|---|
registry | dynamic | — | The registry input consumed by `physicsFrameParameters`. |
View source
# physicsPusher
function physicsPusher(server, entityIndex, frameTime)
Apply server-physics pusher semantics.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
frameTime | dynamic | — | Time value used by the operation. |
View source
# placeClient
function placeClient(server, client, player)
Place one client at the new level's selected spawn point.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `placeClient`. |
View source
# playerProtocolFlags
function playerProtocolFlags(player)
PlayerState keeps groundedness in `onGround`, while the original network writer consumes FL_ONGROUND from ent->v.flags. Rebuild this mirrored bit for PlayerState-only adapter paths so stale flags cannot drop or invent SU_ONGROUND. QuakeC-backed paths still replace the value with QC flags.
| Parameter | Type | Default | Description |
|---|
player | dynamic | — | The player input consumed by `playerProtocolFlags`. |
View source
# playerStateForClient
function playerStateForClient(server, clientValue, hostPlayer)
The listen-server loopback client shares the host's render/input PlayerState. Every remote client needs an independent mirror of its own QuakeC edict. Socketless single-client fixtures predate ServerClient.playerState and keep using the supplied host state so their public frameMode contract is stable.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `playerStateForClient`. |
hostPlayer | dynamic | — | The host player input consumed by `playerStateForClient`. |
View source
# precacheClientFrameLookups
function precacheClientFrameLookups(server, fallbackPlayer)
Warm the pure field/function lookup paths used by the first client physics frame. No QuakeC code is executed and no game time advances; authoritative player values are written and read back unchanged.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
fallbackPlayer | dynamic | — | The fallback player input consumed by `precacheClientFrameLookups`. |
View source
# prepareReliableMessages
function prepareReliableMessages(server)
Implements the `prepareReliableMessages` operation for `miniquake.server` (prepare reliable messages).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# preserveClientConnections
function preserveClientConnections(server)
Implements the `preserveClientConnections` operation for `miniquake.server` (preserve client connections).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# privilegedCommandAllowed
inline function privilegedCommandAllowed(server, clientValue)
Implements the `privilegedCommandAllowed` operation for `miniquake.server` (privileged command allowed).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `privilegedCommandAllowed`. |
View source
# processReliableClientAt
function processReliableClientAt(server, clientValue, realtime)
Execute reliable client at.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `processReliableClientAt`. |
realtime | dynamic | — | Time value used by the operation. |
View source
# protocolBaseline
function protocolBaseline(server, item)
Implements the `protocolBaseline` operation for `miniquake.server` (protocol baseline).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
item | dynamic | — | The item input consumed by `protocolBaseline`. |
View source
# protocolClientData
function protocolClientData(server, client, player)
Return protocol client data derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `protocolClientData`. |
View source
# pumpClientMessages
function pumpClientMessages(server, player)
Advance client messages by one processing step.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
player | dynamic | — | The player input consumed by `pumpClientMessages`. |
View source
# qcEntityVector
function qcEntityVector(server, entityIndex, name)
Return qc entity vector derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
name | dynamic | — | Stable name that identifies the requested object or option. |
View source
# qcFloat
function qcFloat(machine, entityIndex, fieldName, fallback)
Implements the `qcFloat` operation for `miniquake.server` (qc float).
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `qcFloat`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# qcFloatAt
function qcFloatAt(machine, entityIndex, offset, fallback)
Implements the `qcFloatAt` operation for `miniquake.server` (qc float at).
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `qcFloatAt`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
offset | dynamic | — | Zero-based offset of the requested data. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# qcSetFlags
function qcSetFlags(server, entityIndex, flags)
Implements the `qcSetFlags` operation for `miniquake.server` (qc set flags).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
flags | dynamic | — | The flags input consumed by `qcSetFlags`. |
View source
# qcString
function qcString(machine, entityIndex, fieldName, fallback)
Implements the `qcString` operation for `miniquake.server` (qc string).
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `qcString`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# qcStringAt
function qcStringAt(machine, entityIndex, offset, fallback)
Implements the `qcStringAt` operation for `miniquake.server` (qc string at).
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `qcStringAt`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
offset | dynamic | — | Zero-based offset of the requested data. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# qcVector
function qcVector(machine, entityIndex, fieldName, fallback)
Return qc vector derived from the active module state.
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `qcVector`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# qcWord
function qcWord(machine, entityIndex, fieldName, fallback)
Implements the `qcWord` operation for `miniquake.server` (qc word).
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `qcWord`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# qcWordAt
function qcWordAt(machine, entityIndex, offset, fallback)
Implements the `qcWordAt` operation for `miniquake.server` (qc word at).
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `qcWordAt`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
offset | dynamic | — | Zero-based offset of the requested data. |
fallback | dynamic | — | Value to use when the requested input is unavailable or invalid. |
View source
# queuedSoundOrigin
function queuedSoundOrigin(server, entityIndex)
Add state for queued sound origin.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
View source
# readClientMessage
function readClientMessage(server, client, data, player)
Read and validate client message.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
data | dynamic | — | Input data consumed by the operation. |
player | dynamic | — | The player input consumed by `readClientMessage`. |
View source
# readMove
function readMove(server, reader, client)
Read and validate move.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
reader | dynamic | — | The reader input consumed by `readMove`. |
client | dynamic | — | Client state participating in the operation. |
View source
# recomputeEdictCount
function recomputeEdictCount(server)
Return recompute edict count derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# requireSynchronizedVector
function requireSynchronizedVector(value, entityIndex, fieldName)
Validate synchronized vector and report any invalid state.
| Parameter | Type | Default | Description |
|---|
value | dynamic | — | Value consumed by `requireSynchronizedVector`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
View source
# resetClientMessageForConnect
function resetClientMessageForConnect(clientValue)
Update module state for client message for connect.
| Parameter | Type | Default | Description |
|---|
clientValue | dynamic | — | The client value input consumed by `resetClientMessageForConnect`. |
View source
# resetPlayerForSpawn
function resetPlayerForSpawn(player, origin, angles)
Reset the detached PlayerState mirror like SV_SpawnServer's cleared client edict before ClientConnect and PutClientInServer initialize the new level.
| Parameter | Type | Default | Description |
|---|
player | dynamic | — | The player input consumed by `resetPlayerForSpawn`. |
origin | dynamic | — | World-space origin of the operation. |
angles | dynamic | — | Orientation angles used by the operation. |
View source
# resizeClients
function resizeClients(server, requested)
Implements the `resizeClients` operation for `miniquake.server` (resize clients).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
requested | dynamic | — | The requested input consumed by `resizeClients`. |
View source
# resizeSynchronizedEdictArray
function resizeSynchronizedEdictArray(server, requiredCount)
Implements the `resizeSynchronizedEdictArray` operation for `miniquake.server` (resize synchronized edict array).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
requiredCount | dynamic | — | Number of entries or units to process. |
View source
# resolvePlayerEntityCollision
function resolvePlayerEntityCollision(server, clientValue, player, oldOrigin)
Implements the `resolvePlayerEntityCollision` operation for `miniquake.server` (resolve player entity collision).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `resolvePlayerEntityCollision`. |
player | dynamic | — | The player input consumed by `resolvePlayerEntityCollision`. |
oldOrigin | dynamic | — | The old origin input consumed by `resolvePlayerEntityCollision`. |
View source
# runEntityThink
function runEntityThink(server, entityIndex, frameTime)
Execute entity think.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
frameTime | dynamic | — | Time value used by the operation. |
View source
# runNonClientPhysics
function runNonClientPhysics(server, frameTime, registry)
Execute non client physics.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
frameTime | dynamic | — | Time value used by the operation. |
registry | dynamic | — | The registry input consumed by `runNonClientPhysics`. |
View source
# runNonClientPhysicsWithRetouch
function runNonClientPhysicsWithRetouch(server, frameTime, registry, forceRetouch)
Execute non client physics with retouch.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
frameTime | dynamic | — | Time value used by the operation. |
registry | dynamic | — | The registry input consumed by `runNonClientPhysicsWithRetouch`. |
forceRetouch | dynamic | — | The force retouch input consumed by `runNonClientPhysicsWithRetouch`. |
View source
# runQcBlocked
function runQcBlocked(server, pusherIndex, otherIndex)
Execute qc blocked.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
pusherIndex | dynamic | — | Zero-based index of the requested entry. |
otherIndex | dynamic | — | Zero-based index of the requested entry. |
View source
# runQcTouch
function runQcTouch(server, entityIndex, otherIndex)
Execute qc touch.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
otherIndex | dynamic | — | Zero-based index of the requested entry. |
View source
# runQuakeCFrame
function runQuakeCFrame(server, frameTime)
Execute quake cframe.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
frameTime | dynamic | — | Time value used by the operation. |
View source
# runWorldPhysicsWithRetouch
function runWorldPhysicsWithRetouch(server, frameTime, registry, forceRetouch)
Execute world physics with retouch.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
frameTime | dynamic | — | Time value used by the operation. |
registry | dynamic | — | The registry input consumed by `runWorldPhysicsWithRetouch`. |
forceRetouch | dynamic | — | The force retouch input consumed by `runWorldPhysicsWithRetouch`. |
View source
# saveSpawnParmsForChange
function saveSpawnParmsForChange(server)
Encode and write spawn parms for change.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# sendBuffer
function sendBuffer(client, buffer)
Send buffer through the active connection.
| Parameter | Type | Default | Description |
|---|
client | dynamic | — | Client state participating in the operation. |
buffer | dynamic | — | The buffer input consumed by `sendBuffer`. |
View source
# sendClientEye
sendClientEye
SV_WriteEntitiesToClient uses one stack vec3 for the client eye position in the C engine. Keep the MiniLang equivalent as a stable scratch value rather than allocating two temporary Vec3 objects for every client snapshot.
View source
# sendClientFrame
function sendClientFrame(server, client, player)
Send client frame through the active connection.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `sendClientFrame`. |
View source
# sendClientMessages
function sendClientMessages(server, player)
Send client messages through the active connection.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
player | dynamic | — | The player input consumed by `sendClientMessages`. |
View source
# sendClientMessagesAt
function sendClientMessagesAt(server, player, realtime)
Send client messages at through the active connection.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
player | dynamic | — | The player input consumed by `sendClientMessagesAt`. |
realtime | dynamic | — | Time value used by the operation. |
View source
# sendNopAt
function sendNopAt(server, clientValue, realtime)
Send nop at through the active connection.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `sendNopAt`. |
realtime | dynamic | — | Time value used by the operation. |
View source
# sendReconnect
function sendReconnect(server)
Send reconnect through the active connection.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# sendReliableMessages
function sendReliableMessages(server)
Send reliable messages through the active connection.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# sendReliableMessagesAt
function sendReliableMessagesAt(server, realtime)
Reliable-only pump used by the explicit local signon loop. The full server frame calls sendClientMessagesAt so spawned clients receive their unreliable datagram before this reliable phase.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
realtime | dynamic | — | Time value used by the operation. |
View source
# sendServerInfo
function sendServerInfo(server, client)
Send server info through the active connection.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
View source
# serverGameType
function serverGameType(server)
Return server game type derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# serverProgsCrc
function serverProgsCrc(server)
Return server progs crc derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# setClientColors
function setClientColors(server, clientValue, topValue, bottomValue)
Update module state for client colors.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `setClientColors`. |
topValue | dynamic | — | The top value input consumed by `setClientColors`. |
bottomValue | dynamic | — | The bottom value input consumed by `setClientColors`. |
View source
# setClientFloat
function setClientFloat(server, clientValue, fieldName, value)
Update module state for client float.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `setClientFloat`. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
value | dynamic | — | Value consumed by `setClientFloat`. |
View source
# setClientIdealPitch
function setClientIdealPitch(server, client, player, pitchScale)
SV_SetIdealPitch. This mirrors sv_user.c's six point traces and deliberately truncates each sampled height delta to the original C int `step`.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `setClientIdealPitch`. |
pitchScale | dynamic | — | The pitch scale input consumed by `setClientIdealPitch`. |
View source
# setClientName
function setClientName(server, clientValue, newName)
Update module state for client name.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `setClientName`. |
newName | dynamic | — | Name that identifies the requested value or resource. |
View source
# setGiveField
function setGiveField(server, clientValue, name, value)
Update module state for give field.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `setGiveField`. |
name | dynamic | — | Stable name that identifies the requested object or option. |
value | dynamic | — | Value consumed by `setGiveField`. |
View source
# setQcEntityFloat
function setQcEntityFloat(server, entityIndex, fieldName, value)
Update module state for qc entity float.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
value | dynamic | — | Value consumed by `setQcEntityFloat`. |
View source
# setQcEntityVector
function setQcEntityVector(server, entityIndex, fieldName, value)
Update module state for qc entity vector.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
value | dynamic | — | Value consumed by `setQcEntityVector`. |
View source
# setQcEntityWord
function setQcEntityWord(server, entityIndex, fieldName, value)
Update module state for qc entity word.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
value | dynamic | — | Value consumed by `setQcEntityWord`. |
View source
# setSynchronizedVector
function setSynchronizedVector(value, entityIndex, fieldName, x, y, z)
Update module state for synchronized vector.
| Parameter | Type | Default | Description |
|---|
value | dynamic | — | Value consumed by `setSynchronizedVector`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
x | dynamic | — | The x input consumed by `setSynchronizedVector`. |
y | dynamic | — | The y input consumed by `setSynchronizedVector`. |
z | dynamic | — | The z input consumed by `setSynchronizedVector`. |
View source
# shutdown
function shutdown(server)
Implements the `shutdown` operation for `miniquake.server` (shutdown).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# soundIndex
function soundIndex(server, name)
Return sound index derived from the active module state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
name | dynamic | — | Stable name that identifies the requested object or option. |
View source
# spawn
function spawn(server, filesystem, mapName, skill)
Implements the `spawn` operation for `miniquake.server` (spawn).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
filesystem | dynamic | — | The filesystem input consumed by `spawn`. |
mapName | dynamic | — | Name of the map to load or inspect. |
skill | dynamic | — | The skill input consumed by `spawn`. |
View source
# spawnRuntime
function spawnRuntime(server, filesystem, mapName, skill, registry, commandSystem)
Allocate and initialize runtime.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
filesystem | dynamic | — | The filesystem input consumed by `spawnRuntime`. |
mapName | dynamic | — | Name of the map to load or inspect. |
skill | dynamic | — | The skill input consumed by `spawnRuntime`. |
registry | dynamic | — | The registry input consumed by `spawnRuntime`. |
commandSystem | dynamic | — | The command system input consumed by `spawnRuntime`. |
View source
# syncCommandToQuakeC
function syncCommandToQuakeC(server, clientValue)
Update module state for command to quake c.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `syncCommandToQuakeC`. |
View source
# syncEstablishedQcVectorIntoAt
function syncEstablishedQcVectorIntoAt(machine, entityIndex, offset, target, x, y, z)
Copy one snapshot vector into an established mirror slot. Spawn and load synchronization have already validated every nested Vec3 before the server can publish snapshots, so repeating a dynamic type-name lookup here for four vectors on every live edict only burns frame time. Keep the guarded helper above for lifecycle boundaries where incomplete external state is possible.
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `syncEstablishedQcVectorIntoAt`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
offset | dynamic | — | Zero-based offset of the requested data. |
target | dynamic | — | The target input consumed by `syncEstablishedQcVectorIntoAt`. |
x | dynamic | — | The x input consumed by `syncEstablishedQcVectorIntoAt`. |
y | dynamic | — | The y input consumed by `syncEstablishedQcVectorIntoAt`. |
z | dynamic | — | The z input consumed by `syncEstablishedQcVectorIntoAt`. |
View source
# synchronizedEdictOffsets
function synchronizedEdictOffsets(machine)
The C engine resolves ddef_t offsets while loading progs.dat and then uses direct word offsets for every edict. Resolve the MiniLang mirror's fixed synchronization set once per range instead of scanning fieldDefs 18 times for every live edict on every server frame.
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `synchronizedEdictOffsets`. |
View source
# synchronizedOffsetMachine
synchronizedOffsetMachine
Tracks the module-level synchronized offset machine state owned by `miniquake.server`.
View source
# synchronizedOffsets
synchronizedOffsets
Tracks the module-level synchronized offsets state owned by `miniquake.server`.
View source
# synchronizedVectorTarget
function synchronizedVectorTarget(value, entityIndex, fieldName, x, y, z)
The original server keeps edicts in one stable array and mutates their fields in place. Rebuilding every QuakeEdict and every nested Vec3 on each frame creates avoidable allocation pressure and makes object lifetime depend on expression-temporary GC roots. Keep the derived MiniLang mirror stable: allocate only when the high-water mark grows or a previously absent record appears, then copy raw QuakeC words into the existing structs.
| Parameter | Type | Default | Description |
|---|
value | dynamic | — | Value consumed by `synchronizedVectorTarget`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
x | dynamic | — | The x input consumed by `synchronizedVectorTarget`. |
y | dynamic | — | The y input consumed by `synchronizedVectorTarget`. |
z | dynamic | — | The z input consumed by `synchronizedVectorTarget`. |
View source
# syncLoadedQuakeCEdicts
function syncLoadedQuakeCEdicts(server, savedCount)
Update module state for loaded quake cedicts.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
savedCount | dynamic | — | Number of entries or units to process. |
View source
# syncPlayerFromQuakeC
function syncPlayerFromQuakeC(server, clientValue, player)
Update module state for player from quake c.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `syncPlayerFromQuakeC`. |
player | dynamic | — | The player input consumed by `syncPlayerFromQuakeC`. |
View source
# syncPlayerToQuakeC
function syncPlayerToQuakeC(server, clientValue, player)
Update module state for player to quake c.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `syncPlayerToQuakeC`. |
player | dynamic | — | The player input consumed by `syncPlayerToQuakeC`. |
View source
# syncQcVectorInto
function syncQcVectorInto(machine, entityIndex, fieldName, target, x, y, z)
Update module state for qc vector into.
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `syncQcVectorInto`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
target | dynamic | — | The target input consumed by `syncQcVectorInto`. |
x | dynamic | — | The x input consumed by `syncQcVectorInto`. |
y | dynamic | — | The y input consumed by `syncQcVectorInto`. |
z | dynamic | — | The z input consumed by `syncQcVectorInto`. |
View source
# syncQcVectorIntoAt
function syncQcVectorIntoAt(machine, entityIndex, offset, fieldName, target, x, y, z)
Update module state for qc vector into at.
| Parameter | Type | Default | Description |
|---|
machine | dynamic | — | The machine input consumed by `syncQcVectorIntoAt`. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
offset | dynamic | — | Zero-based offset of the requested data. |
fieldName | dynamic | — | Name that identifies the requested value or resource. |
target | dynamic | — | The target input consumed by `syncQcVectorIntoAt`. |
x | dynamic | — | The x input consumed by `syncQcVectorIntoAt`. |
y | dynamic | — | The y input consumed by `syncQcVectorIntoAt`. |
z | dynamic | — | The z input consumed by `syncQcVectorIntoAt`. |
View source
# syncQuakeCEdict
function syncQuakeCEdict(server, entityIndex)
Update module state for quake cedict.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
View source
# syncQuakeCEdictAt
function syncQuakeCEdictAt(server, entityIndex, offsets)
Update module state for quake cedict at.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
offsets | dynamic | — | The offsets input consumed by `syncQuakeCEdictAt`. |
View source
# syncQuakeCEdictRange
function syncQuakeCEdictRange(server, count)
Update module state for quake cedict range.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
count | dynamic | — | Number of entries or units to process. |
View source
# syncQuakeCEdicts
function syncQuakeCEdicts(server)
Update module state for quake cedicts.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# syncQuakeCSnapshotEdictAt
function syncQuakeCSnapshotEdictAt(server, entityIndex, offsets)
Synchronize only fields consumed by client snapshot encoding. Physics and collision already operate on the authoritative VM edicts; the full mirror remains available for lifecycle/save/compatibility boundaries.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
entityIndex | dynamic | — | Zero-based index of the requested entry. |
offsets | dynamic | — | The offsets input consumed by `syncQuakeCSnapshotEdictAt`. |
View source
# syncQuakeCSnapshotEdicts
function syncQuakeCSnapshotEdicts(server)
Update the stable client-snapshot mirror without copying server-only fields.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# touchPlayerTriggers
function touchPlayerTriggers(server, clientValue, player)
Implements the `touchPlayerTriggers` operation for `miniquake.server` (touch player triggers).
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
clientValue | dynamic | — | The client value input consumed by `touchPlayerTriggers`. |
player | dynamic | — | The player input consumed by `touchPlayerTriggers`. |
View source
# truncateBytes
function truncateBytes(text, maximum)
Return truncate bytes derived from the active module state.
| Parameter | Type | Default | Description |
|---|
text | dynamic | — | Text to parse or process. |
maximum | dynamic | — | Largest accepted value. |
View source
# updateReliableClientState
function updateReliableClientState(server)
Update module state for reliable client state.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
View source
# writeBaseline
function writeBaseline(buffer, item)
Writes baseline for `miniquake.server`.
| Parameter | Type | Default | Description |
|---|
buffer | dynamic | — | The buffer input consumed by `writeBaseline`. |
item | dynamic | — | The item input consumed by `writeBaseline`. |
View source
# writeBegin
function writeBegin(client)
Encode and write begin.
| Parameter | Type | Default | Description |
|---|
client | dynamic | — | Client state participating in the operation. |
View source
# writeClientData
function writeClientData(buffer, player)
Encode and write client data.
| Parameter | Type | Default | Description |
|---|
buffer | dynamic | — | The buffer input consumed by `writeClientData`. |
player | dynamic | — | The player input consumed by `writeClientData`. |
View source
# writeClientDataForClient
function writeClientDataForClient(buffer, server, client, player)
Encode and write client data for client.
| Parameter | Type | Default | Description |
|---|
buffer | dynamic | — | The buffer input consumed by `writeClientDataForClient`. |
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `writeClientDataForClient`. |
View source
# writeClientDataWithFlags
function writeClientDataWithFlags(buffer, player, serverFlags)
Encode and write client data with flags.
| Parameter | Type | Default | Description |
|---|
buffer | dynamic | — | The buffer input consumed by `writeClientDataWithFlags`. |
player | dynamic | — | The player input consumed by `writeClientDataWithFlags`. |
serverFlags | dynamic | — | The server flags input consumed by `writeClientDataWithFlags`. |
View source
# writeDamage
function writeDamage(server, client, buffer)
Encode and write damage.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
buffer | dynamic | — | The buffer input consumed by `writeDamage`. |
View source
# writeDamageAndAngle
function writeDamageAndAngle(server, client, player, buffer)
Encode and write damage and angle.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `writeDamageAndAngle`. |
buffer | dynamic | — | The buffer input consumed by `writeDamageAndAngle`. |
View source
# writeEntityUpdate
function writeEntityUpdate(server, buffer, item)
Encode and write entity update.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
buffer | dynamic | — | The buffer input consumed by `writeEntityUpdate`. |
item | dynamic | — | The item input consumed by `writeEntityUpdate`. |
View source
# writeFixAngle
function writeFixAngle(server, client, player, buffer)
Encode and write fix angle.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `writeFixAngle`. |
buffer | dynamic | — | The buffer input consumed by `writeFixAngle`. |
View source
# writePlannedEntityUpdate
function writePlannedEntityUpdate(server, buffer, item)
Encode and write planned entity update.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
buffer | dynamic | — | The buffer input consumed by `writePlannedEntityUpdate`. |
item | dynamic | — | The item input consumed by `writePlannedEntityUpdate`. |
View source
# writePlannedEntityUpdateReserved
function writePlannedEntityUpdateReserved(server, buffer, item, reservedBytes)
Encode and write planned entity update reserved.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
buffer | dynamic | — | The buffer input consumed by `writePlannedEntityUpdateReserved`. |
item | dynamic | — | The item input consumed by `writePlannedEntityUpdateReserved`. |
reservedBytes | dynamic | — | Byte data consumed by the operation. |
View source
# writePlayerUpdate
function writePlayerUpdate(server, buffer, client, player)
Encode and write player update.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
buffer | dynamic | — | The buffer input consumed by `writePlayerUpdate`. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `writePlayerUpdate`. |
View source
# writeQueuedParticle
function writeQueuedParticle(server, event)
Encode and write queued particle.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
event | dynamic | — | Runtime event to process. |
View source
# writeQueuedSound
function writeQueuedSound(server, event)
Encode and write queued sound.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
event | dynamic | — | Runtime event to process. |
View source
# writeSignonStage2
function writeSignonStage2(server, client)
Encode and write signon stage2.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
View source
# writeSpawn
function writeSpawn(server, client, player)
Encode and write spawn.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
client | dynamic | — | Client state participating in the operation. |
player | dynamic | — | The player input consumed by `writeSpawn`. |
View source
# writeVisibleEntityClassReserved
function writeVisibleEntityClassReserved(server, buffer, pvs, clientEdict, reservedBytes, priorityProjectiles)
Write one snapshot class while retaining the Protocol-15 packet budget. The caller selects either priority projectiles or ordinary entities; the client edict is handled separately so it can never be duplicated.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
buffer | dynamic | — | The buffer input consumed by `writeVisibleEntityClassReserved`. |
pvs | dynamic | — | The pvs input consumed by `writeVisibleEntityClassReserved`. |
clientEdict | dynamic | — | The client edict input consumed by `writeVisibleEntityClassReserved`. |
reservedBytes | dynamic | — | Byte data consumed by the operation. |
priorityProjectiles | dynamic | — | The priority projectiles input consumed by `writeVisibleEntityClassReserved`. |
View source
# writeVisibleEntityUpdatesReserved
function writeVisibleEntityUpdatesReserved(server, buffer, pvs, clientEdict, reservedBytes)
Write a complete visible-entity snapshot with the player and active projectiles ahead of less time-sensitive entities. Protocol 15 accepts fast updates in any entity order. Prioritization prevents a high-numbered rocket or grenade from disappearing when a dense PVS reaches MAX_DATAGRAM.
| Parameter | Type | Default | Description |
|---|
server | dynamic | — | Server state participating in the operation. |
buffer | dynamic | — | The buffer input consumed by `writeVisibleEntityUpdatesReserved`. |
pvs | dynamic | — | The pvs input consumed by `writeVisibleEntityUpdatesReserved`. |
clientEdict | dynamic | — | The client edict input consumed by `writeVisibleEntityUpdatesReserved`. |
reservedBytes | dynamic | — | Byte data consumed by the operation. |
View source
# zeroSpawnParms
function zeroSpawnParms()
Create the zero-initialized state for spawn parms.
View source