Table of Contents

Class S100LuaHost

Namespace
EncDotNet.S100.Scripting
Assembly
EncDotNet.S100.Core.dll

Prepares an ILuaContext with the S-100 host environment that portrayal catalogue Lua scripts expect. This includes colour-token lookup, context parameters (safety contour, etc.), and standard helper functions defined by the S-100 Portrayal Model.

public static class S100LuaHost
Inheritance
S100LuaHost
Inherited Members

Methods

Configure(ILuaContext, Func<string, string>, IReadOnlyDictionary<string, object?>)

Configures the Lua context with standard S-100 host functions and the provided colour palette and context parameters.

public static void Configure(ILuaContext context, Func<string, string> colorLookup, IReadOnlyDictionary<string, object?> contextParameters)

Parameters

context ILuaContext

The Lua context to configure.

colorLookup Func<string, string>

A function that resolves an S-52 colour token (e.g. "DEPVS") to an sRGB hex string (e.g. "#61B7FF") for the active palette.

contextParameters IReadOnlyDictionary<string, object>

Named context parameters (e.g. "SafetyContour" → 30.0) exposed to scripts.