Spaces:
Running
Running
Update game.js
Browse files
game.js
CHANGED
@@ -682,7 +682,7 @@ class Enemy {
|
|
682 |
|
683 |
// ํ์ฌ ํ์ ๊ฐ ๋ถ๋๋ฝ๊ฒ ์กฐ์ - ์ ํ ์๋๋ฅผ ๋๋ฆฌ๊ฒ ํ๊ธฐ ์ํด ์กฐ์
|
684 |
const rotationDiff = this.aiState.targetRotation - this.aiState.currentRotation;
|
685 |
-
let rotationStep = Math.sign(rotationDiff) * Math.min(Math.abs(rotationDiff), 0.
|
686 |
this.aiState.currentRotation += rotationStep;
|
687 |
|
688 |
// ๋ฉ์ ํ์ ์ ์ฉ
|
|
|
682 |
|
683 |
// ํ์ฌ ํ์ ๊ฐ ๋ถ๋๋ฝ๊ฒ ์กฐ์ - ์ ํ ์๋๋ฅผ ๋๋ฆฌ๊ฒ ํ๊ธฐ ์ํด ์กฐ์
|
684 |
const rotationDiff = this.aiState.targetRotation - this.aiState.currentRotation;
|
685 |
+
let rotationStep = Math.sign(rotationDiff) * Math.min(Math.abs(rotationDiff), 0.05); // ๊ธฐ์กด 0.02์์ 0.05๋ก ์์
|
686 |
this.aiState.currentRotation += rotationStep;
|
687 |
|
688 |
// ๋ฉ์ ํ์ ์ ์ฉ
|