hook anchors. player animation fixed.

This commit is contained in:
lustlion
2022-02-15 10:21:24 +01:00
parent f6541068e0
commit 8def86ade6
7 changed files with 70 additions and 18 deletions

View File

@@ -68,8 +68,8 @@ function Fairy:Smart()
local distance = math.sqrt(distance_x ^ 2 + distance_y ^ 2)
if distance < self.range then
self.vel.x = 0
self.vel.y = 0
self.vel.x = self.vel.x * 0.9
self.vel.y = self.vel.y * 0.9
else
self.vel.x = math.cos(angle)*self.speed
self.vel.y = math.sin(angle)*self.speed