跳转到内容

DiagnosticsPluginOptions

此内容尚不支持你的语言。

Defined in: diagnostics/DiagnosticsPlugin.ts:44

optional captureLevel?: LogLevel

Defined in: diagnostics/DiagnosticsPlugin.ts:51

The lowest log level to collect. Error by default — a warning is something the engine handled, and a report full of them buries the one line that says a texture never loaded. Warn is the useful widening when chasing a specific complaint.


optional flushIntervalSec?: number

Defined in: diagnostics/Diagnostics.ts:63

Seconds between handing what has accumulated to the sink. Zero delivers on the next frame, which is rarely what a network sink wants.

DiagnosticsOptions.flushIntervalSec


optional maxDistinct?: number

Defined in: diagnostics/Diagnostics.ts:60

How many distinct problems to track at once. Reached, further NEW problems are dropped (counted in DiagnosticsAPI.dropped) while the ones already known keep counting.

Keeping the earliest rather than the newest is deliberate: when a game comes apart it comes apart in cascade, and the first distinct failure is the one that explains the next fifty. An LRU here would evict the cause and keep the consequences.

DiagnosticsOptions.maxDistinct