diff --git a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/goTo.lua b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/goTo.lua new file mode 100644 index 0000000..a38c982 --- /dev/null +++ b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/goTo.lua @@ -0,0 +1,28 @@ +local StepParent = require "scenes.battlesystem.controllers.fighters.systems.choregraphy.step.parent" +local GoToStep = StepParent:extend() + +function GoToStep:new(controller, args) + GoToStep.super.new(self, controller, args) +end + +function GoToStep:start() + + local x, y = self:getStepCoordinate() + self.choregraphy.actor:goTo(x, y, self.arguments.duration) + + if (self.arguments.blockProcess == false) then + self:finish() + else + self.choregraphy.actor:blockChoregraphy(self.arguments.blockProcess, self, "goTo") + end +end + +function GoToStep:update(dt) + +end + +function GoToStep:getSignal(signal) + +end + +return GoToStep; diff --git a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/init.lua b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/init.lua index 2c8b191..2d6102b 100644 --- a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/init.lua +++ b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/init.lua @@ -3,12 +3,12 @@ local actions = {} local baseURI = "scenes.battlesystem.controllers.fighters.systems.choregraphy.step." actions["addGFX"] = require(baseURI .. "addGFX") ---actions["dashForward"] = require(baseURI .. "dashForward") ---actions["jump"] = require(baseURI .. "jump") +actions["goTo"] = require(baseURI .. "goTo") +actions["jumpTo"] = require(baseURI .. "jumpTo") +actions["jumpBack"] = require(baseURI .. "jumpBack") actions["playSFX"] = require(baseURI .. "playSFX") ---actions["sendDamage"] = require(baseURI .. "sendDamage") ---actions["sendDamageToPoint"] = require(baseURI .. "sendDamageToPoint") ---actions["setAnimation"] = require(baseURI .. "setAnimation") +actions["sendDamage"] = require(baseURI .. "sendDamage") +actions["setAnimation"] = require(baseURI .. "setAnimation") actions["wait"] = require(baseURI .. "wait") return actions diff --git a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/jumpBack.lua b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/jumpBack.lua new file mode 100644 index 0000000..0bf6000 --- /dev/null +++ b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/jumpBack.lua @@ -0,0 +1,28 @@ +local StepParent = require "scenes.battlesystem.controllers.fighters.systems.choregraphy.step.parent" +local JumpBackStep = StepParent:extend() + +function JumpBackStep:new(controller, args) + JumpBackStep.super.new(self, controller, args) +end + +function JumpBackStep:start() + + local x, y = self.choregraphy.actor.start.x, self.choregraphy.actor.start.y + self.choregraphy.actor:jumpTo(x, y, 0.5, self.arguments.duration, false, "outQuad") + + if (self.arguments.blockProcess == false) then + self:finish() + else + self.choregraphy.actor:blockChoregraphy(self.arguments.blockProcess, self, "jumpTo") + end +end + +function JumpBackStep:update(dt) + +end + +function JumpBackStep:getSignal(signal) + +end + +return JumpBackStep; diff --git a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/jumpTo.lua b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/jumpTo.lua new file mode 100644 index 0000000..978c2f1 --- /dev/null +++ b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/jumpTo.lua @@ -0,0 +1,28 @@ +local StepParent = require "scenes.battlesystem.controllers.fighters.systems.choregraphy.step.parent" +local JumpToStep = StepParent:extend() + +function JumpToStep:new(controller, args) + JumpToStep.super.new(self, controller, args) +end + +function JumpToStep:start() + + local x, y = self:getStepCoordinate() + self.choregraphy.actor:jumpTo(x, y, 1, self.arguments.duration, true, "inOutQuad") + + if (self.arguments.blockProcess == false) then + self:finish() + else + self.choregraphy.actor:blockChoregraphy(self.arguments.blockProcess, self, "jumpTo") + end +end + +function JumpToStep:update(dt) + +end + +function JumpToStep:getSignal(signal) + +end + +return JumpToStep; diff --git a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/sendDamage.lua b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/sendDamage.lua new file mode 100644 index 0000000..92e5548 --- /dev/null +++ b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/sendDamage.lua @@ -0,0 +1,22 @@ +local StepParent = require "scenes.battlesystem.controllers.fighters.systems.choregraphy.step.parent" +local SendDamage = StepParent:extend() + +local maputils = require "scenes.battlesystem.utils" + +function SendDamage:new(system, args) + SendDamage.super.new(self, system, args) +end + +function SendDamage:start() + local power = self.arguments.power + local accuracy = self.arguments.accuracy + local isSpecial = self.arguments.isSpecial + local isAerial = self.arguments.isAerial + + + + self.choregraphy.haveSentDamage = self.choregraphy:sendDamage(power, accuracy, isSpecial, isAerial) + self:finish() +end + +return SendDamage diff --git a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/setAnimation.lua b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/setAnimation.lua new file mode 100644 index 0000000..b7982f9 --- /dev/null +++ b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/setAnimation.lua @@ -0,0 +1,26 @@ +local StepParent = require "scenes.battlesystem.controllers.fighters.systems.choregraphy.step.parent" +local AnimationSetterStep = StepParent:extend() + +function AnimationSetterStep:new(controller, args) + AnimationSetterStep.super.new(self, controller, args) +end + +function AnimationSetterStep:start() + self.choregraphy.actor:changeAnimation(self.arguments.animation) + + if (self.arguments.blockProcess == false) then + self:finish() + else + self.choregraphy.actor:blockChoregraphy(self.arguments.blockProcess, self, "animation") + end +end + +function AnimationSetterStep:update(dt) + +end + +function AnimationSetterStep:getSignal(signal) + +end + +return AnimationSetterStep;