Small type fixes.

This commit is contained in:
Davide Tantillo 2025-11-03 15:10:08 +01:00
parent 281d36e634
commit abbd63013b
4 changed files with 8 additions and 6 deletions

View File

@ -47,7 +47,6 @@ class SpineC3Instance extends globalThis.ISDKWorldInstanceBase {
this.propOffsetAngle = properties[9] as number;
this.propScaleX = properties[10] as number;
this.propScaleY = properties[11] as number;
}
this.assetLoader = new spine.AssetLoader();

View File

@ -1,6 +1,7 @@
// / <reference types="editor/sdk" />
import type { AnimationState, AssetLoader, Skeleton, SkeletonRendererCore, SpineBoundsProvider, TextureAtlas } from "@esotericsoftware/spine-construct3-lib";
import type { SpineC3PluginType } from "./type";
const SDK = globalThis.SDK;
@ -22,6 +23,8 @@ class SpineC3PluginInstance extends SDK.IWorldInstanceBase {
skins: string[] = [];
animation?: string;
_inst!: SDK.IWorldInstance & { errors: Record<string, string> };
private assetLoader: AssetLoader;
private skeletonRenderer: SkeletonRendererCore;
@ -53,7 +56,7 @@ class SpineC3PluginInstance extends SDK.IWorldInstanceBase {
this.assetLoader = new spine.AssetLoader();
this.skeletonRenderer = new spine.SkeletonRendererCore();
(this._inst as any).errors = this.errors;
this._inst.errors = this.errors;
}
Release () {
@ -169,8 +172,7 @@ class SpineC3PluginInstance extends SDK.IWorldInstanceBase {
// }
} else {
const sdkType = (this._sdkType as any);
const sdkType = this._sdkType as SpineC3PluginType;
const logo = sdkType.getSpineLogo(iRenderer);
if (logo) {

View File

@ -107,3 +107,4 @@ const PLUGIN_CLASS = class SpineC3Plugin extends SDK.IPluginBase {
SDK.Plugins.EsotericSoftware_SpineConstruct3 = PLUGIN_CLASS;
PLUGIN_CLASS.Register(PLUGIN_ID, PLUGIN_CLASS);

File diff suppressed because one or more lines are too long