我看的2.x版本的方法 import { _decorator, Component, Node } from ‘cc’;
import { beichuxian } from ‘./beichuxian’;
const { ccclass, property } = _decorator;
@ccclass(‘NewComponent’)
export class NewComponent extends Component {
@property(beichuxian)
beichuxian2: beichuxian = null
start() {
this.node.on(Node.EventType.MOUSE_DOWN, (Event) => {
console.log(“我被触发了”)
this.beichuxian2.node.active = true
})
报错了 在3.x中该怎么写啊





