using System.Runtime.InteropServices; using LyraApi; using LyraApi.Ecs; using static ExampleWorld.wit.imports.lyra.api.IEcs; namespace LyraApi.Engine; [StructLayout(LayoutKind.Sequential)] public struct DeltaTime : IResource { public float Seconds; public static ulong TypeId => 83716348954; public static object? FromWasmResult(WorldResourceResult result) { return result.Tag switch { WorldResourceResult.NONE | WorldResourceResult.WASM_RESOURCE => null, WorldResourceResult.BYTES => MarshalUtils.FromBytes(result.AsBytes), _ => null, }; } }