The setting position is invalid if you click the cocos button again.

problem description

cocos button click again to set the location is invalid (this.startBtn.x = 3000). The example is the

on the official website.

related codes

  startGame: function () {
        console.log("")
        this.enabled = true
        this.player.startMove(cc.v2(0, this.groundY))
        // this.startBtn.active = false
        this.startBtn.x = 3000  // 
        console.log(this.startBtn)
  },

  gameOver: function () {
    this.player.stopMove();
    this.startBtn.x = 0 // 
    // this.startBtn.active = true
 }
Jul.13,2021

did you add widget

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b3919b-2c16e.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b3919b-2c16e.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?