{"id":2854,"date":"2025-05-28T06:00:18","date_gmt":"2025-05-27T22:00:18","guid":{"rendered":"https:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/"},"modified":"2025-05-28T06:00:18","modified_gmt":"2025-05-27T22:00:18","slug":"%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e","status":"publish","type":"post","link":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/","title":{"rendered":"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce"},"content":{"rendered":"<div class=\"article_content clearfix\" id=\"article_content\">\n <link href=\"https:\/\/csdnimg.cn\/release\/blogv2\/dist\/mdeditor\/css\/editerView\/kdoc_html_views-1a98987dfd.css\" rel=\"stylesheet\"\/>\n <link href=\"https:\/\/csdnimg.cn\/release\/blogv2\/dist\/mdeditor\/css\/editerView\/ck_htmledit_views-704d5b9767.css\" rel=\"stylesheet\"\/>\n<div class=\"htmledit_views atom-one-light\" id=\"content_views\">\n<p>\n   \u6700\u8fd1\u5728\u5bb6\u95f2\u7740\u65e0\u4e8b\u5229\u7528Phaser\u5f15\u64ce\u662f\u5f00\u53d1\u4e86\u4e00\u6b3e\u5f13\u7bad\u5c04\u51fb\u5c0f\u6e38\u620f\u3002\u5e9f\u8bdd\u5c11\u8bf4\u5148\u770b\u6548\u679c\uff1a\n  <\/p>\n<p style=\"text-align:center;\">\n<\/p>\n<p>\n   \u5728\u7ebf\u4f53\u9a8c\uff1a\n  <\/p>\n<p style=\"text-align:center;\">\n<\/p>\n<p>\n   1\u3001\u6e38\u620f\u7684\u4e3b\u8981\u903b\u8f91\u5b9e\u73b0\uff1a\n  <\/p>\n<p>\n   GameState.js:\n  <\/p>\n<pre><code class=\"language-javascript\">export default class GameState extends Phaser.State {\n\n  init() {\n    this.eagle = null; \/\/ \u96c4\u9e70,\u6bcf1000\u5206\u51fa\u73b0\u4e00\u6b21\n    this.birds = []; \/\/ \u98de\u9e1f\u96c6\u5408\n    this.score = 0; \/\/ \u5f97\u5206\n    this.arrows = []; \/\/ arrow\u96c6\u5408\n    this.scoreText = null; \/\/ \u5f97\u5206\n    this.bowArrow = null; \/\/ \u5e95\u90e8\u5f13\u7bad\n    this.backButton = null; \/\/ \u8fd4\u56de\u6309\u94ae\n\n    \/\/ \u8ba1\u7b97arrow\u98de\u884c\u901f\u5ea6\n    this.arrowSpeed = windowHeight \/ 1600;\n\n    this.createBirdsIntervalId = 0;\n    this.recoverBirdsIntervalId = 0;\n    this.durationChangeIntervalId = 0;\n    this.collisionDetecIntervalId = 0;\n  },\n  preload(){\n  },\n  create(){\n  },\n  render(){},\n  update(){}\n}<\/code><\/pre>\n<p>\n   2\u3001\u5728preload\u4e2d\u6dfb\u52a0\u80cc\u666f\u56fe\u7247\u3001\u8fd4\u56de\u6309\u94ae\u548c\u5f13\u7bad\u56fe\u7247\uff1a\n  <\/p>\n<pre><code class=\"language-javascript\">preload() {\n    let that = this;\n    let game = this.game;\n\n    \/\/ \u521b\u5efa\u80cc\u666f\u56fe\u56fe\u7247\n    let gameBgImg = game.add.image(0, 0, \"gamebg1\");\n    gameBgImg.width = windowWidth;\n    gameBgImg.height = windowHeight;\n\n    \/\/ \u5f13\u7bad\u56fe\u7247\n    var bowArrow = game.add.image(windowWidth \/ 2, windowHeight - 80, \"bowarrow\");\n    this.bowArrow = bowArrow;\n    bowArrow.anchor.set(0.5);\n    bowArrow.scale.set(0.38);\n    bowArrow.inputEnabled = true;\n\n    var backImg = game.add.image(25, 25, \"back\");\n    backImg.anchor.set(0.5);\n    backImg.scale.set(0.8);\n    this.backButton = backImg;\n    \/\/ \u603b\u5206\u6570\n    var scoreText = game.add.text(windowWidth - 140, 25, \"\u5f97\u5206\uff1a0\", {\n      font: \"20px\",\n      fill: \"#f7db04\",\n      align: \"center\",\n      stroke: \"#f8abc5\",\n      strokeThickness: 0.5\n    })\n    this.scoreText = scoreText;\n    this.scoreText.anchor.set(0,0.5)\n    \/\/ \u5c06\u5f97\u5206\u548c\u8fd4\u56de\u6309\u94ae\u7f6e\u9876\n    setInterval(() =&gt; {\n      backImg.bringToTop();\n      scoreText.bringToTop();\n    }, 1);\n}<\/code><\/pre>\n<p>\n   3\u3001\u901a\u8fc7setInterval\u5411\u5c4f\u5e55\u4e2d\u6dfb\u52a0\u98de\u9e1f\uff08\u8fd9\u91cc\u7684\u6240\u6709\u52a8\u753b\u90fd\u672a\u4f7f\u7528\u7269\u7406\u5f15\u64ce\uff0c\u8fd8\u5f85\u8fdb\u4e00\u6b65\u7814\u7a76\uff0c\u4e0b\u9762\u6240\u6709\u4ee3\u7801\u540c\u7406\uff09\uff1a\n  <\/p>\n<pre><code class=\"language-javascript\">this.createBirdsIntervalId = setInterval(() =&gt; {\n      \/\/ \u6dfb\u52a0\u98de\u9e1f\n      for (var i = 0; i &lt; MAX_BIRD_NO - this.birds.length; i++) {\n        var birdKind = BIRD_KINDS[Math.floor(Math.random() * MAX_BIRD_NO)];\n        var kindName = birdKind[\"name\"];\n        var from = birdKind[\"from\"];\n        var scale = birdKind[\"scale\"];\n        var price = birdKind[\"price\"];\n\n        var bird = null;\n        var duration = DURATIONS[Math.floor(Math.random() * 3)] + Math.random() * 2000;\n        \/\/ \u4ece\u5de6\u5230\u53f3\n        if (from == \"left\") {\n          bird = this.game.add.sprite(-80 - Math.random() * windowWidth, 40 + Math.ceil(Math.random() * windowHeight * 0.5), kindName);\n          bird.animations.add('fly', null, 8, true);\n          bird.animations.play('fly', 8, true, true);\n          this.game.add.tween(bird).to({\n            x: windowWidth + 80\n          }, duration, \"Linear\", true, 0, -1, false);\n        } else { \/\/ \u4ece\u53f3\u5230\u5de6\n          bird = this.game.add.sprite(windowWidth * (1 + Math.random()) + 80, 40 + Math.ceil(Math.random() * windowHeight * 0.45), kindName);\n          bird.animations.add('fly', null, 8, true);\n          bird.animations.play('fly', 8, true, true);\n          this.game.add.tween(bird).to({\n            x: -80\n          }, duration, \"Linear\", true, 0, -1, false);\n        }\n        bird.anchor.set(0.5);\n        bird.scale.set(scale);\n        bird.zoom = scale;\n        bird.name = kindName;\n        bird.price = price;\n        bird.from = from;\n        bird.diedPic = birdKind[\"diedPic\"];\n\n        this.birds.push(bird);\n      }\n    }, 0);<\/code><\/pre>\n<p>\n   4\u3001\u98de\u9e1f\u98de\u51fa\u5c4f\u5e55\u56de\u6536\u98de\u9e1f\u5bf9\u8c61\uff1a\n  <\/p>\n<pre><code class=\"language-javascript\">this.recoverBirdsIntervalId = setInterval(() =&gt; {\n      \/\/ \u5982\u679c\u98de\u9e1f\u98de\u51fa\u5c4f\u5e55\u9500\u6bc1\u98de\u9e1f\u5bf9\u8c61\n      for (var i = 0; i &lt; this.birds.length; i++) {\n        var bird = this.birds[i];\n        if (this.birdHasFlyAway(bird)) {\n          this.birds.splice(i, 1)\n          i--;\n          bird.destroy();\n        }\n      }\n    }, 0);<\/code><\/pre>\n<p>\n   5\u3001\u78b0\u649e\u68c0\u6d4b\uff1a\n  <\/p>\n<pre><code class=\"language-javascript\">this.collisionDetecIntervalId = setInterval(() =&gt; {\n      \/\/ \u68c0\u6d4b\u78b0\u649e\n      for (var i = 0; i &lt; this.arrows.length; i++) {\n        var arrow = this.arrows[i];\n\n        \/\/ \u5982\u679c\u7bad\u77e2\u8d85\u51fa\u5c4f\u5e55\uff0c\u9500\u6bc1\n        if (arrow.x - windowWidth - arrow.height \/ 4 &gt; 0 ||\n          arrow.x &lt; -arrow.height \/ 2 + 10 ||\n          arrow.y &lt; -arrow.height \/ 2 + 10) {\n          this.arrows.splice(i, 1);\n          i--;\n          arrow.destroy();\n          continue;\n        }\n\n        if (this.eagle &amp;&amp; this.collisionDetec(this.eagle, arrow)) {\n          this.eagle.shoted++;\n          this.arrows.splice(i, 1);\n          i--;\n          \n          arrow.destroy();\n          if (this.eagle.shoted == 1) { \/\/ \u96c4\u9e70\u7b2c\u4e00\u6b21\u88ab\u5c04\u4e2d\u5f00\u59cb\u53d1\u8d77\u653b\u51fb\n            utils.playAudio(\"assets\/audio\/eagle.ogg\");\n            this.attack();\n          } else if (this.eagle.shoted == 3) { \/\/ \u5982\u679c\u88ab\u5c04\u4e2d\u4e09\u6b21\u96c4\u9e70\u88ab\u51fb\u6740\n            this.eagle.diedPic = this.eagle.x &lt; windowWidth \/ 2 ? \"eagle003\" : \"eagleback003\";\n            this.eagle.name = this.eagle.x &lt; windowWidth \/ 2 ? \"eagle\" : \"eagleback\";\n            this.eagle.zoom = EAGLE_SCALE;\n            utils.playAudio(\"assets\/audio\/eagledied.ogg\");\n            this.createDiedStatus(this.eagle, 100, 5);\n            this.eagle.destroy();\n            this.eagle = null;\n\n            this.createShowComboText(\"\u51fb\u6740\u96c4\u9e70 +120\");\n            this.changeScoreText(EAGLE_SCORE);\n          }\n          continue;\n        }\n\n        for (var j = 0; j &lt; this.birds.length; j++) {\n          var b = this.birds[j]\n          if (this.collisionDetec(b, arrow)) {\n            arrow.kiledBirdsNo++;\n            this.birds.splice(j, 1);\n            j--;\n            b.destroy();\n            this.killBird(b);\n            \/\/ b.animations.stop();\n            if (b.name == \"sgbird\") {\n              this.arrows.splice(i, 1);\n              i--;\n              \n              arrow.destroy();\n              break;\n            }\n          }\n        }\n      }\n    }, 0);<\/code><\/pre>\n<p>\n   6\u3001\u54cd\u5e94gameState\u5173\u95ed\u4e8b\u4ef6\uff1a\u5c06\u6240\u6709interval\u5220\u9664\u5e76\u89e3\u7ed1touch\u4e8b\u4ef6\uff08\u4ece\u7b2c2\u6bb5\u4ee3\u7801\u5230\u672c\u6bb5\u4ee3\u7801\u805a\u5728preload\u4e2d\uff09\uff1a\n  <\/p>\n<pre><code class=\"language-javascript\">this.state.onShutDownCallback = function () {\n      clearInterval(that.createBirdsIntervalId);\n      clearInterval(that.recoverBirdsIntervalId);\n      clearInterval(that.durationChangeIntervalId);\n      clearInterval(that.collisionDetecIntervalId);\n\n      that.offTouchEvents();\n    }<\/code><\/pre>\n<p>\n   7\u3001\u7ed1\u5b9atouchStart\uff0ctouchMove\uff0ctouchEnd\u4e8b\u4ef6\uff1a\n  <\/p>\n<pre><code class=\"language-javascript\">create() {\n    let game = this.game;\n    let that = this;\n    \/**\n     * \u8ba1\u7b97\u5f13\u7bad\u504f\u79fb\u89d2\u5ea6\n     *\/\n    function calAngle(x, y) {\n      if (y &gt;= 0) {\n        if (x &gt; 0) {\n          return 90;\n        }\n        if (x &lt; 0) {\n          return -90;\n        }\n      }\n      var z = Math.sqrt(x * x + y * y);\n      return Math.asin(x \/ z) * 180 \/ Math.PI;\n    }\n\n    wx.onTouchStart(touchStartCallback = (event) =&gt; {\n      \/\/ \u5982\u679c\u6309\u4e0b\u8fd4\u56de\u6309\u94ae\u8fd4\u56de\u5230\u5bfc\u822a\u9875\u9762\n      var x = event.changedTouches[0].clientX;\n      var y = event.changedTouches[0].clientY;\n      if (x &gt;= that.backButton.x - 20 &amp;&amp; x &lt;= that.backButton.x + 20 &amp;&amp;\n        y &gt;= that.backButton.y - 20 &amp;&amp; y &lt;= that.backButton.y + 20) {\n        if (!that.gameIsOver()) {\n          wx.showModal({\n            title: \"\u6e38\u620f\u63d0\u9192\",\n            content: \"\u6e38\u620f\u5c1a\u672a\u7ed3\u675f\u662f\u5426\u9000\u51fa\uff1f\",\n            cancelColor: 'red',\n            success: function (res) {\n              if (res.confirm) {\n                that.updateRanks();\n                game.state.start(\"NavState\");\n                that.shutdown();\n              }\n            }\n          })\n        } else {\n          game.state.start(\"NavState\");\n          that.shutdown();\n        }\n        return;\n      }\n\n      that.bowArrow.angle = calAngle(x - that.bowArrow.x, y - that.bowArrow.y);\n    });\n\n    wx.onTouchMove(touchMoveCallback = (event) =&gt; {\n      var x = event.changedTouches[0].clientX;\n      var y = event.changedTouches[0].clientY;\n      that.bowArrow.angle = calAngle(x - that.bowArrow.x, y - that.bowArrow.y);\n    });\n\n    wx.onTouchEnd(touchEndCallback = (event) =&gt; {\n      var x = event.changedTouches[0].clientX;\n      var y = event.changedTouches[0].clientY;\n\n      for (var i = 0; i &lt; that.arrows.length; i++) {\n        var arrow = that.arrows[i];\n        \/\/ \u5982\u679c\u7bad\u77e2\u8d85\u51fa2.2\u79d2\u672a\u9500\u6bc1\uff0c\u9500\u6bc1\n        if(new Date().getTime() - arrow.shootTime &gt;= 2200){\n          that.arrows.splice(i,1);\n          i--;\n          arrow.destroy();\n        }\n      }\n      that.bowArrow.angle = calAngle(x - that.bowArrow.x, y - that.bowArrow.y);\n\n      \/\/ arrow\u5728\u540c\u4e00\u65f6\u523b\u53ea\u80fd\u6709\u4e24\u4e2a\n      if (that.arrows.length &gt;= 2) return;\n      if (!canShoot) return;\n      canShoot = false;\n      setTimeout(()=&gt;{\n        canShoot = true;\n      },SHOOT_DURATION);\n      utils.playAudio(\"assets\/audio\/shoot.ogg\");\n\n      \/\/ \u53d1\u5c04\u7bad\u77e2\n      var arrow = game.add.image(windowWidth \/ 2, windowHeight - 80, \"arrow\");\n      arrow.shootTime = new Date().getTime();\n      arrow.anchor.set(0.5);\n      arrow.scale.set(0.38);\n      arrow.angle = that.bowArrow.angle;\n      \/\/ \u8ba1\u7b97\u7bad\u77e2\u7ec8\u70b9\u5750\u6807\uff08toX,toY\uff09\n      var rightAngle = calAngle(windowWidth - that.bowArrow.x, -that.bowArrow.y);\n      var leftAngle = -rightAngle;\n      var toX = -arrow.height \/ 2;\n      var toY = -arrow.height \/ 2;\n\n      if (arrow.angle &gt;= leftAngle &amp;&amp; arrow.angle &lt;= rightAngle) {\n        toX = Math.tan(-arrow.angle * Math.PI \/ 180) * (toY - arrow.y) + arrow.x;\n      } else if (arrow.angle &gt; rightAngle) {\n        toX = windowWidth - toX;\n      }\n      toY = (toX - arrow.x) \/ Math.tan(-arrow.angle * Math.PI \/ 180) + arrow.y;\n      var $z = Math.sqrt(Math.pow(toX - arrow.x, 2) + Math.pow(toY - arrow.y, 2));\n\n      game.add.tween(arrow).to({\n        x: toX,\n        y: toY\n      }, $z \/ that.arrowSpeed, \"Linear\", true, 0, -1, false);\n      \n      arrow.kiledBirdsNo = 0;\n\n      arrow.events.onDestroy.add(() =&gt; {\n        \n        var text = null;\n        var score = TWO_BIRDS_SCORE;\n        if (arrow.kiledBirdsNo == 2) {\n          \/\/ \u4e00\u7bad\u53cc\u96d5\n          text = \"\u4e00\u7bad\u53cc\u96d5 +\" + TWO_BIRDS_SCORE;\n        }\n        if (arrow.kiledBirdsNo == 3) {\n          \/\/ \u4e00\u77f3\u4e09\u9e1f\n          text = \"\u4e00\u77f3\u4e09\u9e1f +\" + THREE_BIRDS_SCORE;\n          score = THREE_BIRDS_SCORE;\n        }\n\n        if (text) {\n          utils.playAudio(\"assets\/audio\/combo.ogg\");\n          this.createShowComboText(text);\n          this.changeScoreText(score);\n        }\n      });\n\n      that.arrows.push(arrow);\n    })\n  }<\/code><\/pre>\n<p>\n   8\u3001\u521b\u5efa\u96c4\u9e70\u5bf9\u8c61\u5e76\u5224\u65ad\u6e38\u620f\u662f\u5426\u7ed3\u675f\uff1a\n  <\/p>\n<pre><code class=\"language-javascript\">  update() {\n    let that = this;\n\n    \/\/ \u6bcf\u589e\u52a0500\u5206\u51fa\u73b0\u4e00\u6b21\u96c4\u9e70\uff0c\u540c\u65f6\u4e00\u4e2a\u5c4f\u5e55\u4e2d\u53ea\u80fd\u51fa\u73b0\u4e00\u4e2a\n    if (this.score &gt;= 500 &amp;&amp; this.score % 500 &lt; EAGLE_SCORE &amp;&amp; !this.eagle) {\n      var eagleFrom = [\"right\", \"left\"][Math.floor(Math.random() * 2)];\n      var x = -80 - Math.random() * windowWidth,\n        y = 40 + Math.ceil(Math.random() * windowHeight * 0.45);\n      var toX = windowWidth + 80,\n        toY = 40 + Math.ceil(Math.random() * windowHeight * 0.45);\n\n      if (eagleFrom == \"right\") {\n        x = windowWidth * (1 + Math.random()) + 80;\n        toX = -80;\n      }\n\n      this.createNewEagle(eagleFrom, x, y, toX, toY);\n\n    } else if (this.eagle) { \/\/ \u96c4\u9e70\u4e00\u76f4\u5b58\u5728\u4e8e\u5c4f\u5e55\u4e2d\u9664\u975e\u88ab\u51fb\u6740\n      if ((this.eagle.from == \"right\" &amp;&amp; this.eagle.x &lt;= 20) ||\n        (this.eagle.from == \"left\" &amp;&amp; this.eagle.x &gt;= windowWidth - 20)) {\n        var from = this.eagle.from == \"left\" ? \"right\" : \"left\";\n        var x = this.eagle.x,\n          y = this.eagle.y;\n        var toX = windowWidth - 20,\n          toY = toY = 40 + Math.ceil(Math.random() * windowHeight * 0.45);;\n        if (from == \"right\") {\n          toX = 20;\n        }\n        this.createNewEagle(from, x, y, toX, toY);\n      }\n    }\n\n    if (this.gameIsOver()) {\n      utils.playAudio(\"assets\/audio\/gameover.ogg\");\n      var extText = this.updateRanks();\n\n      this.eagle.destroy();\n      this.eagle = null;\n      \/\/ console.log(\"gameOver\");\n      wx.showModal({\n        title: \"\u6e38\u620f\u63d0\u793a\",\n        content: \"Game Over\\r\\n\" + that.scoreText.text + extText,\n        cancelColor: 'red',\n        confirmText: \"\u65b0\u6e38\u620f\",\n        cancelText: \"\u9000\u51fa\",\n        confirmColor: \"blue\",\n        success: (res) =&gt; {\n          that.offTouchEvents();\n          if (res.confirm) {\n            that.state.restart(\"GameState\");\n          } else {\n            that.state.start(\"NavState\");\n          }\n        }\n      });\n    }\n  }<\/code><\/pre>\n<p>\n   9\u3001\u76f8\u5173\u8f85\u52a9\u51fd\u6570\n  <\/p>\n<pre><code class=\"language-javascript\">createNewEagle(from, x, y, toX, toY) {\n    var duration = DURATIONS[Math.floor(Math.random() * 3)] \/ 2.5 + Math.random() * 2000;\n    var tempEagle = this.eagle;\n    this.eagle = this.game.add.sprite(x, y, from == \"left\" ? \"eagle\" : \"eagleback\");\n    this.eagle.animations.add('fly', null, 8, true);\n    this.eagle.animations.play('fly', 8, true, true);\n    this.eagle.anchor.set(0.5);\n    this.eagle.scale.set(EAGLE_SCALE);\n    this.eagle.from = from;\n\n    this.game.add.tween(this.eagle).to({\n      x: toX,\n      y: toY\n    }, duration, \"Linear\", true, 0, -1, false);\n\n    if (tempEagle) {\n      this.eagle.shoted = tempEagle.shoted;\n      tempEagle.destroy();\n    } else {\n      this.eagle.shoted = 0;\n    }\n  }\n\n  render() {\n\n  }\n\n  \/\/ \u78b0\u649e\u68c0\u6d4b\n  collisionDetec(bird, arrow) {\n    \/\/ \u7bad\u77e2\u6d88\u5931\uff0c\u53d6\u6d88\u78b0\u649e\u68c0\u6d4b\n    if (!arrow) return false;\n    var birdStartPointer = {};\n    var birdEndPointer = {};\n\n    birdStartPointer.x = bird.x - bird.width \/ 2 + 5;\n    birdStartPointer.y = bird.y - 8;\n\n    birdEndPointer.x = bird.x + bird.width \/ 2 - 5;\n    birdEndPointer.y = bird.y + 8;\n\n    var arrowHalfHighet = arrow.height \/ 2 - 3;\n\n    var offsetX = arrowHalfHighet * Math.sin(arrow.angle * Math.PI \/ 180);\n    var offsetY = arrowHalfHighet * Math.cos(arrow.angle * Math.PI \/ 180);\n\n    var arrowHeadPointer = {};\n    arrowHeadPointer.x = arrow.x + offsetX;\n    arrowHeadPointer.y = arrow.y - offsetY;\n\n    \/\/ \u5982\u679c\u7bad\u5934\u8d85\u51fa\u5c4f\u5e55\u8303\u56f4\uff0c\u53d6\u6d88\u78b0\u649e\u68c0\u6d4b\n    if (arrowHeadPointer.x &lt; 0 || arrowHeadPointer.x &gt; windowWidth ||\n      arrowHeadPointer.y &gt; windowHeight - 80 ||\n      arrowHeadPointer.y &lt; 0) {\n      return false;\n    }\n    if (arrowHeadPointer.x &gt;= birdStartPointer.x &amp;&amp; arrowHeadPointer.x &lt;= birdEndPointer.x &amp;&amp;\n      arrowHeadPointer.y &gt;= birdStartPointer.y &amp;&amp; arrowHeadPointer.y &lt;= birdEndPointer.y) {\n      utils.playAudio(\"assets\/audio\/hited.ogg\");\n      return true;\n    } else {\n      return false;\n    }\n  }\n\n  attack() {\n    var eagleInLeft = windowWidth \/ 2 &gt; this.eagle.x;\n    var targetX = this.bowArrow.x,\n      targetY = this.bowArrow.y; \/\/ \u653b\u51fb\u70b9\u4e3a\u5e95\u90e8\u5f13\u7bad\u4e2d\u70b9\u5750\u6807\n\n    \/\/ \u4ece\u9ad8\u5904\u53d1\u8d77\u653b\u51fb\uff0c\u9ed8\u8ba4\u5728\u5de6\u4fa7\u88ab\u5c04\u4e2d\n    var prepareToX = 20 + (windowWidth \/ 2 - 20) * Math.random(),\n      prepareToY = this.eagle.y * Math.random();\n\n    var name = \"eaglepreattack\",\n      attackPic = \"eagle005\";\n\n    \/\/ \u5982\u679c\u5728\u53f3\u4fa7\u88ab\u5c04\u4e2d\n    if (!eagleInLeft) {\n      prepareToX = windowWidth \/ 2 + (windowWidth \/ 2 - 20) * Math.random();\n      name = \"eaglebackpreattack\";\n      attackPic = \"eagleback005\"\n    }\n\n    var te = this.eagle;\n    this.eagle = this.game.add.sprite(this.eagle.x, this.eagle.y, name);\n    this.eagle.anchor.set(0.5);\n    this.eagle.scale.set(EAGLE_SCALE);\n    this.eagle.animations.add('fly', null, 8, true);\n    this.eagle.animations.play('fly', 8, true, true);\n    this.eagle.shoted = te.shoted;\n    this.eagle.from = te.from;\n    te.destroy();\n\n    var offsetX = (prepareToX - this.eagle.x) \/ 100;\n    var offsetY = (prepareToY - this.eagle.y) \/ 100;\n\n    var times = 0;\n    let that = this;\n    this.eagle.intervalId = setInterval(() =&gt; {\n      times++;\n      that.eagle.x += offsetX;\n      that.eagle.y += offsetY;\n      if (times &gt; 100) {\n        var tempEagle = that.eagle;\n        that.eagle = that.game.add.sprite(that.eagle.x, that.eagle.y, name, attackPic);\n        this.eagle.anchor.set(0.5);\n        this.eagle.scale.set(EAGLE_SCALE);\n        that.eagle.shoted = tempEagle.shoted;\n        that.eagle.intervalId = tempEagle.intervalId;\n        that.eagle.from = tempEagle.from;\n        that.game.add.tween(that.eagle).to({\n          x: targetX,\n          y: targetY\n        }, EAGLE_DURATIONS, \"Linear\", true, 0, -1, false);\n        tempEagle.destroy();\n        clearInterval(that.eagle.intervalId);\n      }\n    }, 5);\n  }\n\n  createDiedStatus(bird, duration, times) {\n    \/\/ \u521b\u5efa\u5c0f\u9e1f\u6b7b\u4ea1\u56fe\u50cf\n    let that = this;\n    var diedImg = that.game.add.sprite(bird.x, bird.y, bird.name, bird.diedPic);\n    diedImg.anchor.set(0.5);\n    diedImg.scale.set(bird.zoom);\n\n    \/\/ \u5c38\u4f53\u95ea\u70c1\n    var tintChangedTimes = 0;\n    diedImg.intervalId = setInterval(() =&gt; {\n      \/\/ console.log(\"titmer...\");\n      tintChangedTimes++;\n      diedImg.tint = Math.random() * 0xffffff;\n      if (tintChangedTimes &gt; times) {\n        clearInterval(diedImg.intervalId);\n        diedImg.destroy();\n      }\n    }, duration);\n  }\n\n  \/\/ \u5224\u65ad\u98de\u9e1f\u662f\u5426\u98de\u51fa\u5c4f\u5e55\n  birdHasFlyAway(bird) {\n    if (bird.from == \"right\") {\n      if (bird.x + 80 &lt;= 1) {\n        return true;\n      }\n    } else {\n      if (windowWidth + 80 - bird.x &lt;= 1) {\n        return true;\n      }\n    }\n    return false;\n  }\n\n  changeScoreText(price) {\n    this.score = parseInt(this.scoreText.text.replace(\"\u5f97\u5206\uff1a\", \"\")) + price;\n    this.scoreText.text = \"\u5f97\u5206\uff1a\" + JSON.stringify(this.score);\n  }\n\n  gameIsOver() {\n    if (!this.eagle) return false;\n    var x = this.eagle.x,\n      y = this.eagle.y + 20;\n    var bowArrowStartPointer = {\n      x: this.bowArrow.x - this.bowArrow.width \/ 2,\n      y: this.bowArrow.y - 10\n    };\n    var bowarrowEndPointer = {\n      x: this.bowArrow.x + this.bowArrow.width \/ 2,\n      y: this.bowArrow.y + 10\n    };\n\n    return x &gt;= bowArrowStartPointer.x &amp;&amp; x &lt;= bowarrowEndPointer.x &amp;&amp;\n      y &gt;= bowArrowStartPointer.y &amp;&amp; y &lt;= bowarrowEndPointer.y;\n  }\n\n  killBird(bird) {\n    let that = this;\n    \/\/ \u5982\u679c\u5c0f\u9e1f\u8d85\u51fa\u5c4f\u5e55\u8303\u56f4\u4e0d\u8ba1\u5206\n    if (bird.x &lt; -bird.width \/ 2 || bird.x &gt; windowWidth + bird.width \/ 2) {\n      return;\n    }\n    \/\/ console.log(\"bird \" + bird.name + \" was killed.....\");\n    \/\/ console.log(\"bird width\/2:\" + bird.width \/ 2);\n    \/\/ \u521b\u5efa\u52a0\u5206text\n    var priceText = that.game.add.text(bird.x, bird.y - 10, \"+  \" + bird.price, {\n      font: \"20px\",\n      fill: \"#00FF00\",\n      align: \"center\",\n      stroke: \"#d4237a\",\n      strokeThickness: 1\n    });\n    \/\/ 250\u6beb\u79d2\u5185\u6d88\u5931,\u51fb\u6740\u5206\u6570\n    priceText.anchor.set(0.5);\n    var priceTextChangedTimes = 0;\n    priceText.intervalId = setInterval(() =&gt; {\n      priceText.y -= 2;\n      if (priceTextChangedTimes &gt; 10) {\n        clearInterval(priceText.intervalId)\n        priceText.destroy();\n      }\n      priceTextChangedTimes++;\n    }, 50);\n\n    this.createDiedStatus(bird, 100, 5);\n    this.changeScoreText(bird.price);\n  }\n\n  createShowComboText(text) {\n    var showTextChangedTimes = 0;\n    var showText = this.game.add.text(windowWidth \/ 2, windowHeight \/ 2, text, {\n      font: \"22px\",\n      fill: \"#f00b59\",\n      align: \"center\",\n      stroke: \"#f8abc5\",\n      strokeThickness: 0.5\n    });\n\n    showText.anchor.set(0.5);\n    showText.intervalId = setInterval(() =&gt; {\n      showText.y -= 1.5;\n      if (showTextChangedTimes &gt; 35) {\n        clearInterval(showText.intervalId);\n        showText.destroy();\n      }\n      showTextChangedTimes++;\n    }, 25);\n  }\n\n  updateRanks() {\n    if (!this.score) return 0;\n    var ranks = wx.getStorageSync('ranks');\n    var len = ranks.length;\n    var i = 0;\n    var item = {\n      time: utils.formatTime(new Date()),\n      score: this.score\n    };\n    while (i &lt; len &amp;&amp; ranks[i].score &gt; this.score) {\n      i++;\n    }\n\n    if (i == len &amp;&amp; len &lt; 10) {\n      ranks.push(item);\n    } else {\n      ranks.splice(i, 0, item);\n    }\n\n    if (ranks.length &gt; 10) ranks.splice(10, ranks.length - 10);\n\n    wx.setStorageSync('ranks', ranks);\n\n    return i == 0 ? \"\\r\\n\u65b0\u7684\u6700\u9ad8\u5206\uff1a\" + this.score : \"\";\n  }\n\n  offTouchEvents() {\n    wx.offTouchStart(touchStartCallback);\n    wx.offTouchMove(touchMoveCallback);\n    wx.offTouchEnd(touchEndCallback);\n  }\n<\/code><\/pre>\n<p>\n   \u81f3\u6b64\u5c0f\u6e38\u620f\u4e3b\u8981\u903b\u8f91\u5c31\u4e07\u6210\u4e86\u3002\u559c\u6b22\u7684\u8bdd\u53ef\u4ee5\u626b\u7801\u4f53\u9a8c\u4e00\u4e0b\u54e6\u3002\n  <\/p>\n<\/p><\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u6700\u8fd1\u5728\u5bb6\u95f2\u7740\u65e0\u4e8b\u5229\u7528Phaser\u5f15\u64ce\u662f\u5f00\u53d1\u4e86\u4e00\u6b3e\u5f13\u7bad\u5c04\u51fb\u5c0f\u6e38\u620f\u3002\u5e9f\u8bdd\u5c11\u8bf4\u5148\u770b\u6548\u679c\uff1a \u5728\u7ebf\u4f53\u9a8c\uff1a 1\u3001\u6e38\u620f\u7684\u4e3b\u8981 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":215,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[23],"tags":[],"class_list":["post-2854","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-23"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v24.6 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce - \u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0-phaser\u5f15\u64ce\/\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce - \u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51\" \/>\n<meta property=\"og:description\" content=\"\u6700\u8fd1\u5728\u5bb6\u95f2\u7740\u65e0\u4e8b\u5229\u7528Phaser\u5f15\u64ce\u662f\u5f00\u53d1\u4e86\u4e00\u6b3e\u5f13\u7bad\u5c04\u51fb\u5c0f\u6e38\u620f\u3002\u5e9f\u8bdd\u5c11\u8bf4\u5148\u770b\u6548\u679c\uff1a \u5728\u7ebf\u4f53\u9a8c\uff1a 1\u3001\u6e38\u620f\u7684\u4e3b\u8981 [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0-phaser\u5f15\u64ce\/\" \/>\n<meta property=\"og:site_name\" content=\"\u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51\" \/>\n<meta property=\"article:published_time\" content=\"2025-05-27T22:00:18+00:00\" \/>\n<meta property=\"og:image\" content=\"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"260\" \/>\n\t<meta property=\"og:image:height\" content=\"180\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/jpeg\" \/>\n<meta name=\"author\" content=\"admin@wunen\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin@wunen\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"10 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#article\",\"isPartOf\":{\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/\"},\"author\":{\"name\":\"admin@wunen\",\"@id\":\"https:\/\/www.wunen.com\/#\/schema\/person\/d5f7a6cf545656a9c90d507e64452db8\"},\"headline\":\"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce\",\"datePublished\":\"2025-05-27T22:00:18+00:00\",\"mainEntityOfPage\":{\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/\"},\"wordCount\":13,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/www.wunen.com\/#organization\"},\"image\":{\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#primaryimage\"},\"thumbnailUrl\":\"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg\",\"articleSection\":[\"\u5c04\u51fb\u6e38\u620f\"],\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/\",\"url\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/\",\"name\":\"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce - \u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51\",\"isPartOf\":{\"@id\":\"https:\/\/www.wunen.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#primaryimage\"},\"image\":{\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#primaryimage\"},\"thumbnailUrl\":\"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg\",\"datePublished\":\"2025-05-27T22:00:18+00:00\",\"breadcrumb\":{\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#primaryimage\",\"url\":\"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg\",\"contentUrl\":\"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg\",\"width\":260,\"height\":180},{\"@type\":\"BreadcrumbList\",\"@id\":\"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wunen.com\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wunen.com\/#website\",\"url\":\"https:\/\/www.wunen.com\/\",\"name\":\"\u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51\",\"description\":\"\u8f6f\u4ef6\u8d44\u8baf\u6765\u7269\u5ae9\",\"publisher\":{\"@id\":\"https:\/\/www.wunen.com\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wunen.com\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.wunen.com\/#organization\",\"name\":\"\u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51\",\"url\":\"https:\/\/www.wunen.com\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wunen.com\/#\/schema\/logo\/image\/\",\"url\":\"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/cropped-\u7269\u5ae9-1.png\",\"contentUrl\":\"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/cropped-\u7269\u5ae9-1.png\",\"width\":1024,\"height\":1024,\"caption\":\"\u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51\"},\"image\":{\"@id\":\"https:\/\/www.wunen.com\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wunen.com\/#\/schema\/person\/d5f7a6cf545656a9c90d507e64452db8\",\"name\":\"admin@wunen\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wunen.com\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/d90ec1e3faf77c4d4e66e40c29b85ff6401161e0502f401dae2f0e25b38ce25e?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/d90ec1e3faf77c4d4e66e40c29b85ff6401161e0502f401dae2f0e25b38ce25e?s=96&d=mm&r=g\",\"caption\":\"admin@wunen\"},\"sameAs\":[\"http:\/\/www.wunen.com\"],\"url\":\"http:\/\/www.wunen.com\/index.php\/author\/adminwunen\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce - \u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0-phaser\u5f15\u64ce\/","og_locale":"zh_CN","og_type":"article","og_title":"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce - \u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51","og_description":"\u6700\u8fd1\u5728\u5bb6\u95f2\u7740\u65e0\u4e8b\u5229\u7528Phaser\u5f15\u64ce\u662f\u5f00\u53d1\u4e86\u4e00\u6b3e\u5f13\u7bad\u5c04\u51fb\u5c0f\u6e38\u620f\u3002\u5e9f\u8bdd\u5c11\u8bf4\u5148\u770b\u6548\u679c\uff1a \u5728\u7ebf\u4f53\u9a8c\uff1a 1\u3001\u6e38\u620f\u7684\u4e3b\u8981 [&hellip;]","og_url":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0-phaser\u5f15\u64ce\/","og_site_name":"\u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51","article_published_time":"2025-05-27T22:00:18+00:00","og_image":[{"width":260,"height":180,"url":"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg","type":"image\/jpeg"}],"author":"admin@wunen","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin@wunen","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"10 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#article","isPartOf":{"@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/"},"author":{"name":"admin@wunen","@id":"https:\/\/www.wunen.com\/#\/schema\/person\/d5f7a6cf545656a9c90d507e64452db8"},"headline":"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce","datePublished":"2025-05-27T22:00:18+00:00","mainEntityOfPage":{"@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/"},"wordCount":13,"commentCount":0,"publisher":{"@id":"https:\/\/www.wunen.com\/#organization"},"image":{"@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#primaryimage"},"thumbnailUrl":"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg","articleSection":["\u5c04\u51fb\u6e38\u620f"],"inLanguage":"zh-Hans","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#respond"]}]},{"@type":"WebPage","@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/","url":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/","name":"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce - \u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51","isPartOf":{"@id":"https:\/\/www.wunen.com\/#website"},"primaryImageOfPage":{"@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#primaryimage"},"image":{"@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#primaryimage"},"thumbnailUrl":"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg","datePublished":"2025-05-27T22:00:18+00:00","breadcrumb":{"@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/"]}]},{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#primaryimage","url":"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg","contentUrl":"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/\u8d44\u8baf.jpg","width":260,"height":180},{"@type":"BreadcrumbList","@id":"http:\/\/www.wunen.com\/index.php\/2025\/05\/28\/%e5%be%ae%e4%bf%a1%e5%b0%84%e5%87%bb%e5%b0%8f%e6%b8%b8%e6%88%8f%e5%ae%9e%e7%8e%b0-phaser%e5%bc%95%e6%93%8e\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wunen.com\/"},{"@type":"ListItem","position":2,"name":"\u5fae\u4fe1\u5c04\u51fb\u5c0f\u6e38\u620f\u5b9e\u73b0\/Phaser\u5f15\u64ce"}]},{"@type":"WebSite","@id":"https:\/\/www.wunen.com\/#website","url":"https:\/\/www.wunen.com\/","name":"\u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51","description":"\u8f6f\u4ef6\u8d44\u8baf\u6765\u7269\u5ae9","publisher":{"@id":"https:\/\/www.wunen.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wunen.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"zh-Hans"},{"@type":"Organization","@id":"https:\/\/www.wunen.com\/#organization","name":"\u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51","url":"https:\/\/www.wunen.com\/","logo":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wunen.com\/#\/schema\/logo\/image\/","url":"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/cropped-\u7269\u5ae9-1.png","contentUrl":"http:\/\/www.wunen.com\/wp-content\/uploads\/2025\/03\/cropped-\u7269\u5ae9-1.png","width":1024,"height":1024,"caption":"\u7269\u5ae9\u8f6f\u4ef6\u8d44\u8baf\u7f51"},"image":{"@id":"https:\/\/www.wunen.com\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/www.wunen.com\/#\/schema\/person\/d5f7a6cf545656a9c90d507e64452db8","name":"admin@wunen","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wunen.com\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/d90ec1e3faf77c4d4e66e40c29b85ff6401161e0502f401dae2f0e25b38ce25e?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/d90ec1e3faf77c4d4e66e40c29b85ff6401161e0502f401dae2f0e25b38ce25e?s=96&d=mm&r=g","caption":"admin@wunen"},"sameAs":["http:\/\/www.wunen.com"],"url":"http:\/\/www.wunen.com\/index.php\/author\/adminwunen\/"}]}},"_links":{"self":[{"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/posts\/2854","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/comments?post=2854"}],"version-history":[{"count":0,"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/posts\/2854\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/media\/215"}],"wp:attachment":[{"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/media?parent=2854"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/categories?post=2854"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/www.wunen.com\/index.php\/wp-json\/wp\/v2\/tags?post=2854"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}