Skip to content

Instantly share code, notes, and snippets.

@hanshou101
Created April 17, 2019 03:49
Show Gist options
  • Save hanshou101/7646e879e66068684a6e70bbf2c1b13a to your computer and use it in GitHub Desktop.
Save hanshou101/7646e879e66068684a6e70bbf2c1b13a to your computer and use it in GitHub Desktop.
测试
// Learn cc.Class:
// - [Chinese] http://docs.cocos.com/creator/manual/zh/scripting/class.html
// - [English] http://www.cocos2d-x.org/docs/creator/en/scripting/class.html
// Learn Attribute:
// - [Chinese] http://docs.cocos.com/creator/manual/zh/scripting/reference/attributes.html
// - [English] http://www.cocos2d-x.org/docs/creator/en/scripting/reference/attributes.html
// Learn life-cycle callbacks:
// - [Chinese] http://docs.cocos.com/creator/manual/zh/scripting/life-cycle-callbacks.html
// - [English] http://www.cocos2d-x.org/docs/creator/en/scripting/life-cycle-callbacks.html
cc.Class({
extends: cc.Component,
properties: {
loading: cc.Node,
},
// LIFE-CYCLE CALLBACKS:
// onLoad () {},
start () {
this.loading.runAction( cc.repeatForever(cc.rotateBy(1.0, 360)) )
},
// update (dt) {},
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment