Versions in this module Expand all Collapse all v0 v0.1.12 Nov 28, 2026 v0.1.11 Nov 26, 2026 Changes in this version + type AnimationSpecValue interface v0.1.10 Nov 23, 2026 Changes in this version type RuntimeFeatureID + func (id RuntimeFeatureID) Dependencies() []RuntimeFeatureID v0.1.9 Nov 21, 2026 v0.1.8 Nov 20, 2026 v0.1.7 Nov 14, 2026 v0.1.6 Nov 13, 2026 v0.1.5 Nov 12, 2026 v0.1.4 Nov 11, 2026 v0.1.3 Nov 9, 2026 v0.1.2 Nov 9, 2026 Changes in this version + const DefaultSceneFile + const ModFileName + const ModulePlanFile + const SceneDirectory + func ClampFloat32(value, minimum, maximum float32) float32 + func ClampFloat64(value, minimum, maximum float64) float64 + func MarshalModulePlan(plan *ProjectPlan) ([]byte, error) + func NormalizeEnvironmentPath(value string) (string, error) + func NormalizeLocalResourcePath(value string) (string, error) + func NormalizePrefabPath(value string) (string, error) + func NormalizeResourcePath(value string) (string, error) + func ParseColor(value string, alpha float32) (graphics.ColorRGBA, error) + func Queue2DEntityUploads(queue *graphics.UploadQueue, world *ecs.World, entity ecs.Entity) + func QueueEntityUploads(queue *graphics.UploadQueue, world *ecs.World, entity ecs.Entity) + func QueueParticlesEntityUploads(queue *graphics.UploadQueue, world *ecs.World, entity ecs.Entity) + func QueueSpatialEntityUploads(queue *graphics.UploadQueue, world *ecs.World, entity ecs.Entity) + func QueueSpineEntityUploads(queue *graphics.UploadQueue, world *ecs.World, entity ecs.Entity) + func QueueTilemapsEntityUploads(queue *graphics.UploadQueue, world *ecs.World, entity ecs.Entity) + func ResolveLocalResourcePath(baseDir, value string) (string, error) + func ResolveModResourcePath(id ModID, file string) (string, error) + func ResolveResourcePath(baseDir, value string) (string, error) + func ScenePath(id SceneID) string + func ValidateProjectSpec(spec ProjectSpec) error + type AmbientLightSpec struct + Brightness float32 + Color string + func NewAmbientLightSpec() AmbientLightSpec + func (s *AmbientLightSpec) UnmarshalJSON(data []byte) error + type AnimationClipSpec struct + BoolTracks []AnimationTrackSpec[bool] + Duration float32 + Events []AnimationEventSpec + FloatTracks []AnimationTrackSpec[float32] + Loop bool + SampleRate float32 + TextureTracks []AnimationTrackSpec[TextureSpec] + func DefaultAnimationClip(spec SceneNodeSpec) AnimationClipSpec + func (s AnimationClipSpec) Clone() AnimationClipSpec + func (s AnimationClipSpec) HasContent() bool + func (s AnimationClipSpec) Validate() error + type AnimationComponentSpec struct + Clip AnimationClipSpec + Speed float32 + func (s *AnimationComponentSpec) UnmarshalJSON(data []byte) error + type AnimationEventSpec struct + Name string + Time float32 + Value string + type AnimationKeyframeSpec struct + Curve scene.AnimationCurve + InTangent T + OutTangent T + Time float32 + Tween scene.AnimationTween + Value T + func (key AnimationKeyframeSpec[T]) EffectiveAnimationTween(defaultTween scene.AnimationTween) scene.AnimationTween + type AnimationTrackSpec struct + Binding scene.AnimationBinding + Keyframes []AnimationKeyframeSpec[T] + TimeCurve scene.AnimationCurve + TimeTween scene.AnimationTween + type AppConfig struct + Viewport SizeConfig + Window WindowConfig + type AreaLightSpec struct + Color string + Height float32 + Intensity float32 + Radius float32 + Range float32 + Shape render3d.AreaLightShape + Unit graphics.LightUnit + Width float32 + func NewAreaLightSpec() AreaLightSpec + func (s *AreaLightSpec) UnmarshalJSON(data []byte) error + func (s AreaLightSpec) Light() (render3d.AreaLight, error) + type BoxCollider2DSpec struct + Height float64 + Offset [2]float64 + Rotation float64 + Width float64 + func NewBoxCollider2DSpec() BoxCollider2DSpec + func (s *BoxCollider2DSpec) UnmarshalJSON(data []byte) error + type Bundle struct + func Load(source iofs.FS, root string) (*Bundle, error) + func LoadConfiguredWith[F ResourceFeature](source iofs.FS, root string, config EngineConfig) (*Bundle, error) + func LoadDefault() (*Bundle, error) + func LoadDefaultConfigured[F ResourceFeature](config EngineConfig) (*Bundle, error) + func LoadDirectoryConfigured[F ResourceFeature](dir string, config EngineConfig) (*Bundle, error) + func LoadDirectoryFromManifest[F ResourceFeature](dir string) (*Bundle, error) + func LoadDirectoryWithProfile[P LoadProfile, F ResourceFeature](dir string) (*Bundle, error) + func MustDefault() *Bundle + func MustLoadDefault(loader func(string) (*Bundle, error)) *Bundle + func (b *Bundle) AppConfig() AppConfig + func (b *Bundle) BeginPreloadScene(world *ecs.World, id SceneID) (*ScenePreloader, error) + func (b *Bundle) ClearColor() (graphics.ColorRGBA, bool) + func (b *Bundle) CompileAnimationClip(spec AnimationClipSpec) (*scene.AnimationClip, error) + func (b *Bundle) Dispose() error + func (b *Bundle) EntrySceneID() SceneID + func (b *Bundle) Has3D() bool + func (b *Bundle) HasUI() bool + func (b *Bundle) InstantiateEntryScene(world *ecs.World) (*SceneInstance, error) + func (b *Bundle) InstantiateScene(world *ecs.World, id SceneID) (*SceneInstance, error) + func (b *Bundle) ModelAnimation(modelID, animationName string) (*scene.AnimationClip, error) + func (b *Bundle) ModelDeformation(modelID string) (render3d.Deformation, error) + func (b *Bundle) ModelMaterials(modelID string) ([]graphics.StandardMaterial, error) + func (b *Bundle) ModelMorphTargets(modelID string) ([]ModelMorphTarget, error) + func (b *Bundle) ModelNodes(modelID string) ([]ModelNode, error) + func (b *Bundle) ModelRig(modelID string) (*ModelRig, error) + func (b *Bundle) ModelSkeleton(modelID string) ([]ModelJoint, error) + func (b *Bundle) ModelSkinWeights(modelID string) ([]ModelSkinVertex, error) + func (b *Bundle) PrefabIDs() []PrefabID + func (b *Bundle) PreloadScene(id SceneID) error + func (b *Bundle) PreloadSceneFor(device *render.Device, id SceneID) error + func (b *Bundle) PreloadScenes(ids ...SceneID) error + func (b *Bundle) Resources() *Resources + func (b *Bundle) SceneIDs() []SceneID + func (b *Bundle) ValidateSceneFeatures(id SceneID, installed func(RuntimeFeatureID) bool) error + func (b *Bundle) ViewportSize() (int, int, bool) + func (b *Bundle) WindowIcon() []byte + func (b *Bundle) WindowIconDecoder() window.IconDecoder + func (b *Bundle) WindowSize() (int, int, bool) + type Camera3DSpec struct + ClearColor string + Environment *EnvironmentSpec + Exposure graphics.Exposure + FXAA bool + Fog *FogSpec + Fov float32 + Near float32 + Order int + Quality render3d.Quality + SSAO *SSAOSpec + SSR *SSRSpec + ToneMapping graphics.ToneMapping + Viewport CameraViewport3DSpec + func NewCamera3DSpec() Camera3DSpec + func (s *Camera3DSpec) UnmarshalJSON(data []byte) error + type CameraViewport3DSpec struct + Height float32 + Width float32 + X float32 + Y float32 + type CircleCollider2DSpec struct + Offset [2]float64 + Radius float64 + func NewCircleCollider2DSpec() CircleCollider2DSpec + func (s *CircleCollider2DSpec) UnmarshalJSON(data []byte) error + type Collider2DSettingsSpec struct + Categories uint64 + CollisionType uint32 + Friction float64 + Group int32 + Mask uint64 + Restitution float64 + Sensor bool + func NewCollider2DSettingsSpec() Collider2DSettingsSpec + type Collider3DSettingsSpec struct + Categories uint64 + CollisionType uint32 + Friction float64 + Group int32 + Mask uint64 + Restitution float64 + Sensor bool + func NewCollider3DSettingsSpec() Collider3DSettingsSpec + type CollisionPieceSpec struct + Indices []uint32 + Position [3]float64 + Rotation [4]float64 + Vertices [][3]float64 + type CollisionResourceSpec struct + Cooked *enginephysics.CookedCollision + Indices []uint32 + Mode enginephysics.CollisionMode + Pieces []CollisionPieceSpec + Vertices [][3]float64 + type CompileCache struct + func (cache *CompileCache) Compile(source fs.FS, root string, definitions []ModID) (*ProjectPlan, error) + type CompoundCollider3DSpec struct + Model string + func NewCompoundCollider3DSpec() CompoundCollider3DSpec + func (s *CompoundCollider3DSpec) UnmarshalJSON(data []byte) error + type ControlSpec struct + Font string + FontSize float64 + Text string + type ConvexHullCollider3DSpec struct + Model string + func NewConvexHullCollider3DSpec() ConvexHullCollider3DSpec + func (s *ConvexHullCollider3DSpec) UnmarshalJSON(data []byte) error + type CoordinateSpace string + const CoordinateSpaceUI + const CoordinateSpaceWorld + type CreateProjectOptions struct + EngineDirectory string + EngineVersion string + Height int + ModulePath string + Title string + Width int + type DirectionalLightSpec struct + Color string + Illuminance float32 + Shadows *ShadowSpec + func NewDirectionalLightSpec() DirectionalLightSpec + func (s *DirectionalLightSpec) UnmarshalJSON(data []byte) error + type EmitterSpec struct + AlphaEnd float32 + AlphaStart float32 + Count int + Direction float32 + GravityX float32 + GravityY float32 + Height float32 + Lifetime float32 + Loop bool + Particles []string + Rate float32 + SizeMax float32 + SizeMin float32 + SpeedMax float32 + SpeedMin float32 + Spread float32 + Width float32 + type EngineConfig struct + Features []RuntimeFeatureID + ImageDecoders []ImageDecoderID + Resources []ResourceID + TextureCompression bool + TextureCompressionExcludes []string + func ReadEngineConfig(source iofs.FS, root string) (EngineConfig, error) + func (config EngineConfig) HasFeature(id RuntimeFeatureID) bool + func (config EngineConfig) HasResource(id ResourceID) bool + func (config EngineConfig) Validate() error + type EnvironmentSpec struct + Background bool + Exposure float32 + Intensity float32 + Path string + Rotation float32 + type FileResource struct + ID string + Path string + Stream bool + type FogSpec struct + Brightness float32 + Color string + Density float32 + End float32 + Mode render3d.FogMode + Start float32 + func NewFogSpec() *FogSpec + func (s *FogSpec) Settings() (render3d.FogSettings, error) + func (s *FogSpec) UnmarshalJSON(data []byte) error + type FontDecoder interface + DecodeFont func([]byte, string) (*onixtext.Font, error) + type Hooks struct + Destroy func(*T, *ScriptContext) error + Input func(*T, *ScriptContext, *scene.InputEventContext) error + InputMask scene.InputMask + Install func(*T, *ScriptContext) error + Update func(*T, *ScriptContext) error + type IconFeature struct + func (IconFeature[K]) ConfigureResources(context ResourceLoadContext, _ ResourceEntries) error + type ImageDecoder interface + DecodeImage func([]byte, string, graphics.TextureOptions) (*graphics.Texture, error) + type ImageDecoderID string + const ImageDecoderGIF + const ImageDecoderJPEG + const ImageDecoderPNG + const ImageDecoderWebP + type ImageFeature struct + func (ImageFeature[I]) ConfigureResources(context ResourceLoadContext, _ ResourceEntries) error + type LoadProfile interface + type MeshSpec struct + Indices []uint32 + Primitive string + Radius float32 + Sectors int + Size float32 + Stacks int + Vertices []MeshVertexSpec + type MeshVertexSpec struct + Normal [3]float32 + Position [3]float32 + UV [2]float32 + type ModCamera2DSpec struct + Clear *bool + ClearColor string + Order int + Scale float32 + Viewport scene.CameraViewport + type ModCollisionSpec struct + Emit string + type ModComponents struct + AmbientLight *AmbientLightSpec + Anchor *scene.Anchor + Animation *AnimationComponentSpec + AreaLight *AreaLightSpec + BoxCollider2D *BoxCollider2DSpec + Camera *Camera3DSpec + Camera2D *ModCamera2DSpec + CircleCollider2D *CircleCollider2DSpec + Collision *ModCollisionSpec + CompoundCollider3D *CompoundCollider3DSpec + ConvexHullCollider3D *ConvexHullCollider3DSpec + DirectionalLight *DirectionalLightSpec + Emitter *EmitterSpec + HTML *ModHTMLSpec + Input *ModInputSpec + Layout *engineui.Layout + Material *ModMaterial2DSpec + Model *ModelSpec + Particle *TextureSpec + PointLight *PointLightSpec + RigidBody2D *RigidBody2DSpec + RigidBody3D *RigidBody3DSpec + SegmentCollider2D *SegmentCollider2DSpec + Shader *ShaderComponentSpec + Size []float32 + Spine *ModSpineSpec + SpotLight *SpotLightSpec + Sprite *ModSpriteSpec + Text *TextComponentSpec + Tilemap *TilemapSpec + Trail *SpriteTrailSpec + TriangleMeshCollider3D *TriangleMeshCollider3DSpec + func (c ModComponents) ContentFeatures() (features ModContentFeatures) + type ModContentFeatures uint16 + const ModContentAll + const ModContentAnimations + const ModContentHTML + const ModContentLayout + const ModContentParticles + const ModContentPhysics2D + const ModContentSpatial + const ModContentSpine + const ModContentTilemaps + const ModContentTrail + type ModElementPlan struct + Parent int32 + Spec ModElementSpec + Transform ModTransform + type ModElementSpec struct + Components ModComponents + ID string + Parent string + Space CoordinateSpace + Transform ModTransformSpec + Visible *bool + type ModHTMLSpec struct + BoldFont string + Font string + PassThrough bool + Resource string + type ModID string + func NormalizeModPath(id ModID) (ModID, error) + type ModInputSpec struct + Files bool + Keyboard bool + Pointer bool + Text bool + type ModInstancePlan struct + Enabled bool + ID string + Mod uint32 + Parent int32 + Placement ModTransform + Slots []SlotValue + Visible bool + type ModInstanceSpec struct + Children []ModInstanceSpec + Enabled *bool + ID string + Mod ModID + Placement ModTransformSpec + Slots map[string]json.RawMessage + Visible *bool + type ModMaterial2D struct + Custom [4][4]float32 + func (m ModMaterial2D) Material2D() graphics.Material2DData + type ModMaterial2DSpec struct + Custom [4][4]float32 + type ModPlan struct + Elements []ModElementPlan + ID ModID + Resources []ModResourcePlan + Slots []SlotPlan + Spec ModSpec + Transform ModTransform + type ModResourcePlan struct + Kind string + Name string + Path string + type ModResourceSpec struct + Kind string + Path string + type ModSpec struct + Behavior string + Components ModComponents + Elements []ModElementSpec + Name string + Resources map[string]ModResourceSpec + Slots map[string]SlotSpec + Space CoordinateSpace + Transform ModTransformSpec + type ModSpineSpec struct + Animation string + Loop bool + Skin string + Source SpineSpec + Speed float32 + type ModSpriteSpec struct + Alpha *float32 + Color string + Size []float32 + Texture *TextureSpec + type ModTransform struct + Position [3]float32 + Rotation [3]float32 + Scale [3]float32 + type ModTransformSpec struct + Position []float32 + Rotation []float32 + Scale []float32 + type ModelAnimationSource struct + BlendMode int + Duration float32 + Name string + Tracks []ModelAnimationTrackSource + type ModelAnimationTrackSource struct + Name string + Times []float32 + Type string + Values []float32 + type ModelJoint struct + InverseBind [16]float32 + Name string + Node int32 + Parent int32 + type ModelMaterialSpec struct + BaseColor string + Emissive string + EmissiveStrength float32 + EmissiveStrengthSet bool + IOR float32 + IORSet bool + Metallic float32 + MetallicSet bool + PerceptualRoughness float32 + RoughnessSet bool + Shader string + func (s *ModelMaterialSpec) UnmarshalJSON(data []byte) error + func (s ModelMaterialSpec) MarshalJSON() ([]byte, error) + type ModelMorphTarget struct + Name string + NormalDelta [][3]float32 + PositionDelta [][3]float32 + TangentDelta [][3]float32 + type ModelNode struct + Local [16]float32 + Name string + Parent int32 + Path string + World [16]float32 + type ModelPose struct + Deformation render3d.Deformation + func (p *ModelPose) NodeMatrix(index int) mgl32.Mat4 + func (p *ModelPose) Sample(clip *ModelPoseClip, time float32, loop bool) + type ModelPoseClip struct + Duration float32 + Name string + type ModelRig struct + func (r *ModelRig) Animation(name string) (*ModelPoseClip, error) + func (r *ModelRig) NewPose() *ModelPose + func (r *ModelRig) NodeIndex(name string) (int, error) + type ModelSkinVertex struct + Active bool + Joints [4]uint32 + Weights [4]float32 + type ModelSpec struct + AnimationPath string + Collision enginephysics.CollisionMode + CollisionPath string + ID string + Material ModelMaterialSpec + Mesh *MeshSpec + Path string + func (s ModelSpec) CookCollision(mesh *graphics.Mesh) (enginephysics.CookedCollision, error) + func (s ModelSpec) Validate() error + type NineSlice struct + Bottom int + Left int + Right int + Top int + func (s NineSlice) Validate(width, height int) error + type ParticleSpec struct + AlphaEnd float32 + AlphaStart float32 + Colors []string + Count int + Direction float32 + GravityX float32 + GravityY float32 + Height float32 + ID string + Lifetime float32 + Loop bool + Rate float32 + SizeMax float32 + SizeMin float32 + SpeedMax float32 + SpeedMin float32 + Spread float32 + Texture *TextureSpec + Width float32 + type PointLightSpec struct + Color string + Intensity float32 + LuxDistance float32 + Radius float32 + Range float32 + Shadows *PunctualShadowSpec + Unit graphics.LightUnit + func NewPointLightSpec() PointLightSpec + func (s *PointLightSpec) UnmarshalJSON(data []byte) error + func (s PointLightSpec) Light() (render3d.PointLight, error) + type PrefabID string + type PrefabInstance struct + func (p *PrefabInstance) Entity(id string) (ecs.Entity, bool) + func (p *PrefabInstance) Remove() int + func (p *PrefabInstance) Reset() bool + func (p *PrefabInstance) Root() ecs.Entity + func (p *PrefabInstance) SetVisible(visible bool) + type PrefabPool struct + func (p *PrefabPool) Acquire() *PrefabInstance + func (p *PrefabPool) AcquireSlot() (int, *PrefabInstance) + func (p *PrefabPool) Dispose() + func (p *PrefabPool) Instance(index int) *PrefabInstance + func (p *PrefabPool) Len() int + func (p *PrefabPool) Release(instance *PrefabInstance) bool + type PrefabResourceSpec struct + ID PrefabID + Path string + type PreprocessOptions struct + Progress func(module, asset string, completed, total int) + Root string + ShaderCompiler ShaderCompiler + ShaderTarget ShaderTarget + TextureEncoder func([]byte, string, graphics.TextureOptions) ([]byte, error) + type PreprocessedFile struct + Data []byte + Path string + Remove bool + SourcePath string + SourceSize int + func PreprocessManifests(source iofs.FS, options PreprocessOptions) ([]PreprocessedFile, error) + func PreprocessModShaders(source fs.FS, mod *ModPlan, options PreprocessOptions) ([]PreprocessedFile, error) + func PreprocessModuleAssets(source fs.FS, plan *ProjectPlan, options PreprocessOptions) ([]PreprocessedFile, error) + type ProjectPlan struct + Entry uint32 + Mods []ModPlan + Scenes []ScenePlan + Spec ProjectSpec + func CompileProject(source fs.FS, root string) (*ProjectPlan, error) + func CompileProjectDefinitions(source fs.FS, root string, definitions []ModID) (*ProjectPlan, error) + func CompileProjectDirectory(directory string) (*ProjectPlan, error) + func CreateProjectDirectory(directory string, options CreateProjectOptions) (*ProjectPlan, error) + func OpenModuleProject() (*ProjectPlan, fs.FS, error) + func ReadModulePlan(source fs.FS) (*ProjectPlan, error) + func (p *ProjectPlan) RuntimeFeatures() []RuntimeFeatureID + type ProjectSpec struct + ClearColor string + Engine EngineConfig + Entry SceneID + Scenes []SceneID + Types map[ValueType]ValueSchema + Viewport SizeConfig + Window WindowConfig + type PunctualShadowSpec struct + Bias float32 + Near float32 + NormalBias float32 + Resolution int + func NewPunctualShadowSpec() *PunctualShadowSpec + func (s *PunctualShadowSpec) UnmarshalJSON(data []byte) error + func (s PunctualShadowSpec) Settings() render3d.PunctualShadowSettings + type Render2DAnimationsProfile struct + type Render2DProfile struct + type ResourceComponentSpec struct + Resource string + type ResourceEntries struct + Audio []FileResource + type ResourceFeature interface + ConfigureResources func(ResourceLoadContext, ResourceEntries) error + type ResourceFeatureSet struct + func (ResourceFeatureSet[A, B]) ConfigureResources(context ResourceLoadContext, entries ResourceEntries) error + type ResourceID string + const ResourceAudio + const ResourceFonts + const ResourceHTML + const ResourceImages + const ResourceModels + const ResourceParticles + const ResourceShaders + const ResourceSpine + const ResourceTilemaps + const ResourceVideos + type ResourceLoadContext struct + func (context ResourceLoadContext) OpenBlob(path string) (*resource.Blob, error) + func (context ResourceLoadContext) ReadFile(path string) ([]byte, error) + func (context ResourceLoadContext) RegisterNamedResource[T any](kind, id string, registration ResourceRegistration[T]) error + func (context ResourceLoadContext) SetFontDecoder(decoder FontDecoder) + func (context ResourceLoadContext) SetImageDecoder(decoder ImageDecoder) + func (context ResourceLoadContext) SetWindowIconDecoder(decoder window.IconDecoder) + type ResourceRegistration struct + Dispose func(T) error + Load func() (T, error) + type ResourceStatistics struct + CacheHits uint64 + CacheMisses uint64 + ResidentResources uint64 + type Resources struct + func OpenModResources(source fs.FS, mod *ModPlan, feature ResourceFeature) (_ *Resources, resultErr error) + func (r *Resources) AppendModContent(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContent2D(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentAnimation(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentHTML(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentLayout(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentParticles(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentPhysics2D(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentSpatial(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentSpine(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentTilemaps(b *ecs.Bundle, c ModComponents) error + func (r *Resources) AppendModContentTrail(b *ecs.Bundle, c ModComponents) error + func (r *Resources) Atlas(path string) (*graphics.Atlas, error) + func (r *Resources) AtlasWithOptions(path string, options graphics.TextureOptions) (*graphics.Atlas, error) + func (r *Resources) Dispose() error + func (r *Resources) Font(id string) (*onixtext.Font, error) + func (r *Resources) HTML(id string) (string, error) + func (r *Resources) Material2DShader(id string) (*graphics.Material2DShader, error) + func (r *Resources) MeshShader(id string) (*graphics.MeshShader, error) + func (r *Resources) ModContent(c ModComponents) (ecs.Bundle, error) + func (r *Resources) ModelRig(name string) (*ModelRig, error) + func (r *Resources) ParseColor(value string, alpha float32) (graphics.ColorRGBA, error) + func (r *Resources) Shader(id string) (render.ShaderDescriptor, error) + func (r *Resources) Spine(id string) (*spineruntime.Resource, error) + func (r *Resources) Statistics() ResourceStatistics + func (r *Resources) Video(id string) (*Video, error) + func (resources *Resources) LoadNamedResource[T any](kind, id string) (T, error) + type RigidBody2DSpec struct + AngularDamping float64 + AngularVelocity float64 + FixedRotation bool + GravityScale float64 + Inertia float64 + LinearDamping float64 + Mass float64 + Type string + Velocity [2]float64 + func NewRigidBody2DSpec() RigidBody2DSpec + func (s *RigidBody2DSpec) UnmarshalJSON(data []byte) error + type RigidBody3DSpec struct + AngularDamping float64 + AngularVelocity [3]float64 + FixedRotation bool + GravityScale float64 + Inertia float64 + LinearDamping float64 + Mass float64 + Type string + Velocity [3]float64 + func NewRigidBody3DSpec() RigidBody3DSpec + func (s *RigidBody3DSpec) UnmarshalJSON(data []byte) error + type RuntimeFeatureID string + const FeatureAnimations2D + const FeatureFileDialogs + const FeatureInput2D + const FeatureParticles2D + const FeaturePhysics2D + const FeaturePhysics3D + const FeatureRender2D + const FeatureRender3D + const FeatureSpine2D + const FeatureSpriteTrails2D + const FeatureTilemaps2D + const FeatureUIControls + const FeatureUIHTML + const FeatureUIMarkdown + const FeatureUITextInput + const FeatureUIWidgets + const FeatureWebView + type SSAOSpec struct + Bias float32 + Radius float32 + ResolutionScale float32 + Samples int + Strength float32 + func NewSSAOSpec() *SSAOSpec + func (s *SSAOSpec) Settings() render3d.SSAOSettings + func (s *SSAOSpec) UnmarshalJSON(data []byte) error + type SSRSpec struct + EdgeFade float32 + MaxDistance float32 + MaxRoughness float32 + Steps int + Strength float32 + Thickness float32 + func NewSSRSpec() *SSRSpec + func (s *SSRSpec) Settings() render3d.SSRSettings + func (s *SSRSpec) UnmarshalJSON(data []byte) error + type SceneCatalogEntry struct + ID SceneID + Path string + type SceneComponent string + const SceneComponentAmbientLight + const SceneComponentAnimation + const SceneComponentAreaLight + const SceneComponentBoxCollider2D + const SceneComponentCamera + const SceneComponentCircleCollider2D + const SceneComponentCompoundCollider3D + const SceneComponentConvexHullCollider3D + const SceneComponentDirectionalLight + const SceneComponentHTML + const SceneComponentLayout + const SceneComponentModel + const SceneComponentParticle + const SceneComponentPointLight + const SceneComponentRigidBody2D + const SceneComponentRigidBody3D + const SceneComponentSegmentCollider2D + const SceneComponentSpine + const SceneComponentSpotLight + const SceneComponentSprite + const SceneComponentText + const SceneComponentTilemap + const SceneComponentTriangleMeshCollider3D + const SceneComponentWidget + type SceneComponents struct + AmbientLight *AmbientLightSpec + Animation *AnimationComponentSpec + AreaLight *AreaLightSpec + BoxCollider2D *BoxCollider2DSpec + Camera *Camera3DSpec + CircleCollider2D *CircleCollider2DSpec + CompoundCollider3D *CompoundCollider3DSpec + ConvexHullCollider3D *ConvexHullCollider3DSpec + DirectionalLight *DirectionalLightSpec + HTML *ResourceComponentSpec + Model *ResourceComponentSpec + Particle *ResourceComponentSpec + PointLight *PointLightSpec + RigidBody2D *RigidBody2DSpec + RigidBody3D *RigidBody3DSpec + SegmentCollider2D *SegmentCollider2DSpec + Spine *SpineComponentSpec + SpotLight *SpotLightSpec + Sprite *SpriteComponentSpec + Text *TextComponentSpec + Tilemap *ResourceComponentSpec + TriangleMeshCollider3D *TriangleMeshCollider3DSpec + func Components(values ...SceneComponent) SceneComponents + func (c *SceneComponents) Add(component SceneComponent) + func (c SceneComponents) Empty() bool + func (c SceneComponents) Has(component SceneComponent) bool + func (c SceneComponents) Has2D() bool + func (c SceneComponents) Has3D() bool + func (c SceneComponents) HasPhysics2D() bool + func (c SceneComponents) HasPhysics3D() bool + func (c SceneComponents) IsZero() bool + func (c SceneComponents) VisualsEmpty() bool + func (components SceneComponents) Clone() SceneComponents + type SceneExitPolicy string + const SceneExitDestroy + const SceneExitRetain + type SceneID string + type SceneInstance struct + Entities map[string]ecs.Entity + EntityIDs map[ecs.Entity]string + Roots []ecs.Entity + World *ecs.World + func (s *SceneInstance) ApplyNode(spec SceneNodeSpec) error + func (s *SceneInstance) ApplyNodeUnder(parentID string, spec SceneNodeSpec) error + func (s *SceneInstance) BindScripts() error + func (s *SceneInstance) Bounds(entity ecs.Entity) (float32, float32, float32, float32, bool) + func (s *SceneInstance) BoundsByID(id string) (float32, float32, float32, float32, bool) + func (s *SceneInstance) Child(parent ecs.Entity, id string) (ecs.Entity, error) + func (s *SceneInstance) CloneChildrenUnder(parent ecs.Entity, templateID, prefix string) (map[string]ecs.Entity, error) + func (s *SceneInstance) CloneNodeUnder(parent ecs.Entity, templateID, prefix string) (map[string]ecs.Entity, error) + func (s *SceneInstance) CloneRootsUnder(parent ecs.Entity, prefix string) (map[string]ecs.Entity, error) + func (s *SceneInstance) DispatchInputScripts(context *ecs.SystemContext, reader *ecs.MessageReader[scene.InputEvent]) error + func (s *SceneInstance) Dispose() + func (s *SceneInstance) Entity(id string) (ecs.Entity, error) + func (s *SceneInstance) EntityAt(path string) (ecs.Entity, error) + func (s *SceneInstance) EntityBySlot(slot ecs.EntitySlot) (ecs.Entity, bool) + func (s *SceneInstance) ID(entity ecs.Entity) string + func (s *SceneInstance) IsUI(entity ecs.Entity) bool + func (s *SceneInstance) MountPrefab(parent ecs.Entity, id PrefabID, instanceID string) (*PrefabInstance, error) + func (s *SceneInstance) MustChild(parent ecs.Entity, id string) ecs.Entity + func (s *SceneInstance) MustEntity(id string) ecs.Entity + func (s *SceneInstance) MustEntityAt(path string) ecs.Entity + func (s *SceneInstance) MustSlot(id string) ecs.EntitySlot + func (s *SceneInstance) NewPrefabPool(parent ecs.Entity, id PrefabID, prefix string, capacity int) (*PrefabPool, error) + func (s *SceneInstance) Path(id string) string + func (s *SceneInstance) Pick(worldPosition, viewportPosition mgl32.Vec2) (string, bool) + func (s *SceneInstance) RefreshTransforms() error + func (s *SceneInstance) RemoveNodes(ids ...string) int + func (s *SceneInstance) RenderItems() []SceneRenderItem + func (s *SceneInstance) ReplaceNodes(specs []SceneNodeSpec) error + func (s *SceneInstance) Resources() *Resources + func (s *SceneInstance) SceneID() SceneID + func (s *SceneInstance) SetModelResource(spec ModelSpec) error + func (s *SceneInstance) SetParticleResource(spec ParticleSpec) error + func (s *SceneInstance) SetScriptRegistry(registry ScriptRegistry) error + func (s *SceneInstance) SetSpineResource(spec SpineSpec) error + func (s *SceneInstance) SetTilemapResource(spec TilemapSpec) error + func (s *SceneInstance) Slot(id string) (ecs.EntitySlot, error) + func (s *SceneInstance) Switch(id SceneID) error + func (s *SceneInstance) TransformMatrix2D(entity ecs.Entity) (mgl32.Mat4, bool) + func (s *SceneInstance) UpdateScripts(context *ecs.SystemContext) error + func (scene *SceneInstance) BindControlEntity[T any](entity ecs.Entity, component T) error + func (scene *SceneInstance) BindControl[T any](id string, component T) error + func (scene *SceneInstance) Component[T any](id string) (*T, error) + func (scene *SceneInstance) RequireComponent[T any](id string) (ecs.EntitySlot, error) + type SceneNodeSpec struct + Alpha float32 + Anchor scene.Anchor + BlockInput bool + Children []SceneNodeSpec + Components SceneComponents + Control *ControlSpec + CoordinateSpace CoordinateSpace + Disabled bool + Height int + ID string + Layout *engineui.Layout + Order int + PassThrough bool + RenderLayers []uint + Rotation float32 + RotationX float32 + RotationY float32 + RotationZ float32 + ScaleX float32 + ScaleY float32 + ScaleZ float32 + Scripts []ScriptComponentSpec + TargetCamera string + Visible *bool + Widget *engineui.Widget + Width int + X float32 + Y float32 + Z float32 + func (s *SceneNodeSpec) UnmarshalJSON(data []byte) error + func (s SceneNodeSpec) Has3DComponents() bool + func (s SceneNodeSpec) HasComponent(component SceneComponent) bool + func (s SceneNodeSpec) IsEmpty() bool + type ScenePlan struct + ID SceneID + Instances []ModInstancePlan + Spec SceneSpec + Transform ModTransform + type ScenePreloader struct + func (p *ScenePreloader) Activate(current *SceneInstance) error + func (p *ScenePreloader) Advance(budget time.Duration) (bool, error) + func (p *ScenePreloader) AdvanceFor(device *render.Device, budget graphics.UploadBudget) (ready bool, err error) + func (p *ScenePreloader) CPUReady() bool + func (p *ScenePreloader) Discard() + func (p *ScenePreloader) GPUReadyFor(device *render.Device) bool + func (p *ScenePreloader) Ready() bool + func (p *ScenePreloader) ReadyFor(device *render.Device) bool + type SceneRenderItem struct + Depth float32 + Entity ecs.Entity + Material uint64 + Sequence uint64 + SortIndex int + UI bool + type SceneSpec struct + Behavior string + ExitPolicy SceneExitPolicy + Modules []ModInstanceSpec + Transform ModTransformSpec + type ScriptBinding struct + Bind func(*ScriptContext, ScriptComponentSpec) error + Destroy func(*ScriptContext) error + Input func(*ScriptContext, *scene.InputEventContext) error + InputMask scene.InputMask + Name string + Remove func(*ScriptContext) error + Update func(*ScriptContext) error + func Script[T any](name string, hooks Hooks[T]) ScriptBinding + type ScriptComponentSpec struct + Name string + Values map[string]json.RawMessage + func (spec ScriptComponentSpec) DecodeScriptValues[T any](target *T) error + type ScriptContext struct + Commands *ecs.Commands + Entity ecs.Entity + Scene *SceneInstance + World *ecs.World + func (context *ScriptContext) ListenInput(target ecs.Entity) error + type ScriptRegistry struct + func NewScriptRegistry(bindings ...ScriptBinding) ScriptRegistry + func (r ScriptRegistry) Empty() bool + func (r ScriptRegistry) InputMask() scene.InputMask + type SegmentCollider2DSpec struct + End [2]float64 + Radius float64 + Start [2]float64 + func NewSegmentCollider2DSpec() SegmentCollider2DSpec + func (s *SegmentCollider2DSpec) UnmarshalJSON(data []byte) error + type ShaderCompileRequest struct + ID string + Source []byte + SourcePath string + Target ShaderTarget + type ShaderCompileResult struct + Fragment []byte + HasFragmentEntry bool + HasVertexEntry bool + Metal []byte + Vertex []byte + WebGL2Generated bool + type ShaderCompiler interface + CompileShader func(ShaderCompileRequest) (ShaderCompileResult, error) + type ShaderComponentSpec struct + Compiled ShaderSources + Custom [4][4]float32 + WGSLFragment string + WGSLVertex string + func (s ShaderComponentSpec) HasSource() bool + func (s ShaderComponentSpec) SourcePaths() [2]string + type ShaderSources struct + DirectXFragment string + DirectXVertex string + Metal string + VulkanFragment string + VulkanVertex string + WGSLFragment string + WGSLVertex string + WebGL2Fragment string + WebGL2Generated bool + WebGL2Vertex string + WebGPUFragment string + WebGPUVertex string + func (s ShaderSources) HasSource() bool + func (s ShaderSources) SourcePaths() [11]string + func (s ShaderSources) Validate() error + type ShaderSpec struct + ID string + func (s ShaderSpec) Validate() error + type ShaderTarget uint8 + const ShaderTargetAll + const ShaderTargetDirectX + const ShaderTargetMetal + const ShaderTargetVulkan + const ShaderTargetWebGL2 + const ShaderTargetWebGPU + func (target ShaderTarget) String() string + type ShadowSpec struct + Bias float32 + CascadeBlend float32 + Cascades int + Depth float32 + Distance float32 + NormalBias float32 + Radius float32 + Resolution int + SplitLambda float32 + func NewShadowSpec() *ShadowSpec + func (s *ShadowSpec) UnmarshalJSON(data []byte) error + func (s ShadowSpec) Settings() render3d.ShadowSettings + type SizeConfig struct + Height int + Mode window.ViewportMode + Width int + type SlotFieldValue struct + Name string + Value SlotValue + type SlotPlan struct + Default SlotValue + Name string + Placement ModTransform + Type ValueType + Writable bool + type SlotSpec struct + Default json.RawMessage + Placement ModTransformSpec + Type ValueType + Writable *bool + type SlotValue struct + Bool bool + Fields []SlotFieldValue + Integer int64 + Number float64 + String string + Type ValueType + Vector [4]float32 + type SpineComponentSpec struct + Animation string + Loop bool + Resource string + Skin string + Speed float32 + func (s *SpineComponentSpec) UnmarshalJSON(data []byte) error + type SpineSpec struct + Atlas string + ID string + Skeleton string + Texture string + func (s SpineSpec) Validate() error + type SpotLightSpec struct + AspectRatio float32 + Color string + Height float32 + InnerConeAngle float32 + Intensity float32 + LuxDistance float32 + OuterConeAngle float32 + Radius float32 + Range float32 + RangeAttenuation bool + Reflector bool + Shadows *PunctualShadowSpec + Shape render3d.SpotLightShape + Unit graphics.LightUnit + Width float32 + func NewSpotLightSpec() SpotLightSpec + func (s *SpotLightSpec) UnmarshalJSON(data []byte) error + func (s SpotLightSpec) Light() (render3d.SpotLight, error) + type SpriteComponentSpec struct + Texture *TextureSpec + Trail *SpriteTrailSpec + func (s *SpriteComponentSpec) UnmarshalJSON(data []byte) error + type SpriteTrailSpec struct + AlphaEnd float32 + AlphaStart float32 + Interval float32 + Lifetime float32 + MaxSamples int + MinDistance float32 + type TextComponentSpec struct + Color string + Font string + FontSize float64 + LetterSpacing float32 + LineHeight float32 + MaxWidth float32 + OutlineColor string + OutlineWidth float32 + Shadow *TextShadow + TextAlignment string + Value string + WrapMode string + WrapWidth float32 + type TextShadow struct + Color string + OffsetX float32 + OffsetY float32 + type TextureSpec struct + Atlas string + Color string + Frame string + Image string + Mipmap bool + Slice *NineSlice + type TileRun struct + Length int + Value int + type TilemapSpec struct + Height int + ID string + TileHeight int + TileRuns []TileRun + TileWidth int + Tiles []int + Tileset string + Width int + func (s *TilemapSpec) Compact() + func (s *TilemapSpec) Expand() error + func (s *TilemapSpec) Normalize() + func (s TilemapSpec) Validate() error + type TriangleMeshCollider3DSpec struct + Model string + func NewTriangleMeshCollider3DSpec() TriangleMeshCollider3DSpec + func (s *TriangleMeshCollider3DSpec) UnmarshalJSON(data []byte) error + type ValueSchema struct + Fields map[string]ValueType + type ValueType string + const BoolValue + const ColorValue + const IntValue + const NumberValue + const StringValue + const Vec2Value + const Vec3Value + const VisualValue + type Video struct + func (v *Video) Bytes() ([]byte, error) + func (v *Video) Close() error + func (v *Video) Info() resource.AssetInfo + func (v *Video) Open() (io.ReadSeekCloser, error) + func (v *Video) ReadAll() ([]byte, error) + type WindowConfig struct + AlwaysOnTop *bool + Antialias *bool + Border *bool + CornerRadius int + DRMConnectorID uint32 + DRMDevice string + Decorations window.DecorationMode + FPS *int + Height int + Icon string + MaxDevicePixelRatio float64 + RenderScale float64 + Resizable *bool + Shadow *bool + ShowInTaskbar *bool + TPS *int + Title string + TitleBarHeight float64 + Transparent bool + Vsync *bool + Width int