import { _decorator, Component, Label, Node, RigidBody } from 'cc'; const { ccclass, property } = _decorator; export enum Cube_State{ live, wait, dead } @ccclass('Cube_Infor') export class Cube_Infor extends Component { @property(Label) txt:Label; @property(RigidBody) rigidbody:RigidBody; text:string; // lock:boolean = false; state:Cube_State = Cube_State.live; start() { } update(deltaTime: number) { } set Text(value:string){ this.txt.string = value; } get Text(){ return this.txt.string; } }