|
@@ -11,13 +11,13 @@ cc.Class({
|
|
|
avatarSprite: cc.Sprite,
|
|
|
|
|
|
hasUser: {
|
|
|
- get: function() {
|
|
|
+ get: function () {
|
|
|
if (!this._hasUser) {
|
|
|
this._hasUser = false;
|
|
|
}
|
|
|
return this._hasUser;
|
|
|
},
|
|
|
- set: function(value) {
|
|
|
+ set: function (value) {
|
|
|
this._hasUser = value;
|
|
|
if (this._hasUser) {
|
|
|
this.inviteNode.active = false;
|
|
@@ -32,10 +32,10 @@ cc.Class({
|
|
|
|
|
|
// LIFE-CYCLE CALLBACKS:
|
|
|
|
|
|
- onLoad () {
|
|
|
+ onLoad() {
|
|
|
},
|
|
|
|
|
|
- start () {
|
|
|
+ start() {
|
|
|
|
|
|
},
|
|
|
|
|
@@ -46,13 +46,13 @@ cc.Class({
|
|
|
configData(userData) {
|
|
|
this.hasUser = true;
|
|
|
|
|
|
- if (userData.head) {
|
|
|
- Api.createImageFromUrl(userData.head, (spriteFrame) => {
|
|
|
- this.avatarSprite.spriteFrame = spriteFrame;
|
|
|
- });
|
|
|
- } else {
|
|
|
- this.avatarSprite.spriteFrame = null;
|
|
|
- }
|
|
|
+ // if (userData.head) {
|
|
|
+ Api.createImageFromUrl(userData.head, (spriteFrame) => {
|
|
|
+ this.avatarSprite.spriteFrame = spriteFrame;
|
|
|
+ });
|
|
|
+ // } else {
|
|
|
+ // this.avatarSprite.spriteFrame = null;
|
|
|
+ // }
|
|
|
},
|
|
|
|
|
|
// update (dt) {},
|