Files
heros/assets/script/game/hero/UiHeroComp.ts
2025-01-12 23:58:35 +08:00

20 lines
449 B
TypeScript

import { _decorator, Component, Node, sp } from 'cc';
const { ccclass, property } = _decorator;
@ccclass('UiHeroComp')
export class UiHeroComp extends Component {
h_uuid:number=0
start() {
var spine = this.node.getChildByName("anm").getComponent('sp.Skeleton') as sp.Skeleton;
spine.setAnimation(0, 'Idle', true);
}
to_destroy(){
this.node.destroy()
}
update(deltaTime: number) {
}
}