const {ccclass, property} = cc._decorator;
@ccclass
export default class RotateForever extends cc.Component {
@property({type: cc.Integer, displayName:"速度1圈多少秒"})
time : number = 20;
onLoad () {
cc.tween(this.node)
.repeatForever(
cc.tween(this.node)
.by(this.time, {angle : -360})
.start()
)
.start()
}
}