Class VanillaClientCheck
The client half of a "clients do not need it" check for a server-side mod: a client with BepInEx, ValheimCLI and the
mod's test adapter but not the mod (pin the mod absent in the client plan) goes to each place the mod touches
and must see nothing it cannot handle. Use Measure(ClientRound) as, or inside, a ClientRounds
measurement. For each of Points (or once where the player stands, when there are none) it arrives there
(Arrive(GameActor?, GameActor, HeightExpectation, TimeSpan, CancellationToken, bool, bool), {round}-vanilla-client-{n}-arrival.json), waits for a complete census of
the objects around the player and fails on any prefab hash the client cannot resolve, naming each
({round}-vanilla-client-{n}.json). Then, with ClientLogs, it scans the client's logs so far and
fails on the three quiet failures of a client without the mod: objects whose prefab is missing
(missing-prefab-hash), per-object RPCs with no handler (rpc-method-missing) and errors while objects
unload (nre-remove-objects) ({round}-vanilla-client-logs.json). Pass LogClassifications to
the run's teardown scan too, so the same lines fail the whole run wherever they appear.
public sealed class VanillaClientCheck
- Inheritance
-
objectVanillaClientCheck
Fields
LogPatterns
The log scan's patterns this check fails on.
public static readonly IReadOnlyList<string> LogPatterns
Field Value
- IReadOnlyList<string>
Properties
ArrivalTimeout
Each arrival's deadline (Arrive(GameActor?, GameActor, HeightExpectation, TimeSpan, CancellationToken, bool, bool)): more than zero, at most 10 minutes.
public TimeSpan ArrivalTimeout { get; init; }
Property Value
- TimeSpan
Cancellation
public CancellationToken Cancellation { get; init; }
Property Value
- CancellationToken
Capability
The adapter's census capability on the client, for example mymod.testing/unresolved-prefabs.
public required string Capability { get; init; }
Property Value
- string
CensusInterval
How often the census is re-read while the area loads.
public TimeSpan CensusInterval { get; init; }
Property Value
- TimeSpan
CensusTimeout
How long the area around the player may take to load before the census is complete.
public TimeSpan CensusTimeout { get; init; }
Property Value
- TimeSpan
ClientLogs
The client's logs to scan after the census, for example an owned Logs; null skips the scan.
public Func<IReadOnlyList<RunLog>>? ClientLogs { get; init; }
Property Value
- Func<IReadOnlyList<RunLog>>
KnownPrefabs
Prefab names that label an unresolved hash in a failure, typically the mod's own server-side prefabs.
public IReadOnlyList<string> KnownPrefabs { get; init; }
Property Value
- IReadOnlyList<string>
LogClassifications
Teardown classifications that make LogPatterns failures, each with its reason (the log scan requires
one). nre-remove-objects is already a failure by default.
public static IReadOnlyDictionary<string, LogClassification> LogClassifications { get; }
Property Value
- IReadOnlyDictionary<string, LogClassification>
Points
The places the mod touches, one arrival and census each; empty checks only where the player stands.
public IReadOnlyList<HeightExpectation> Points { get; init; }
Property Value
- IReadOnlyList<HeightExpectation>
Radius
The census radius around the player, in metres (at most 256).
public float Radius { get; init; }
Property Value
- float
Methods
Measure(ClientRound)
Runs the check in round, recording each part as a round step; the first failure is rethrown.
public void Measure(ClientRound round)
Parameters
roundClientRound
Problems(IEnumerable<LogFileScan>)
One line per LogPatterns count above zero in scans (with its first line), and one per
required log that is missing. Empty when the logs are clean.
public static IReadOnlyList<string> Problems(IEnumerable<LogFileScan> scans)
Parameters
scansIEnumerable<LogFileScan>
Returns
- IReadOnlyList<string>