@pumpkin-plugins/distant-horizons-support-pumpkin API / session/protocol / validate
Function: validate()
validate(
state,peer,client,request,capacity?): {kind:number;reason:string; } |undefined
Defined in: packages/distant-horizons-support-pumpkin/src/session/protocol.ts:224
Checks a LOD request against the player's world, the negotiated configuration, the request range and the world border.
Parameters
state
peer
client
request
level
string
section
timestamp?
number
tracker
number
type
"request"
capacity?
boolean = true
Also enforce the request rate and the server's pending-work limit, as for a new request.
Returns
{ kind: number; reason: string; } | undefined
The rejection reason and wire kind, or undefined when the request can be served.