From 7364e5c206aa616134519fafc81ba3d8dfb7cc9f Mon Sep 17 00:00:00 2001 From: Kazhnuz Date: Sat, 25 Jul 2020 16:46:46 +0200 Subject: [PATCH] feat: add more coordinate system --- .../fighters/systems/choregraphy/step/parent.lua | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/parent.lua b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/parent.lua index 5d56108..5e5508a 100644 --- a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/parent.lua +++ b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/parent.lua @@ -20,6 +20,12 @@ function StepParent:getStepCoordinate() local target = self.choregraphy.action.target local x, y = target.actor:getCoordinate() return x + self.arguments.x, y + self.arguments.y + elseif (self.arguments.origin == "start") then + local x, y = self.choregraphy.actor.start.x, self.choregraphy.actor.start.y + return x + self.arguments.x, y + self.arguments.y + elseif (self.arguments.origin == "actor") then + local x, y = self.choregraphy.actor:getCoordinate() + return x + self.arguments.x, y + self.arguments.y end end