From cf7be0cb5579d0c13076cc2b5fd7819aa93927c8 Mon Sep 17 00:00:00 2001 From: Kazhnuz Date: Sun, 18 Jul 2021 18:57:54 +0200 Subject: [PATCH] feat: add stopMov step action --- .../datas/parsers/choregraphystep.lua | 1 + .../systems/choregraphy/step/init.lua | 1 + .../systems/choregraphy/step/stopMov.lua | 21 +++++++++++++++++++ 3 files changed, 23 insertions(+) create mode 100644 sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/stopMov.lua diff --git a/sonic-radiance.love/datas/parsers/choregraphystep.lua b/sonic-radiance.love/datas/parsers/choregraphystep.lua index da2a424..8f4966d 100644 --- a/sonic-radiance.love/datas/parsers/choregraphystep.lua +++ b/sonic-radiance.love/datas/parsers/choregraphystep.lua @@ -17,6 +17,7 @@ return { ["addQTE"] = {"qteData", "origin", "blockProcess"}, ["setCounter"] = {"counterName", "number", "relative"}, ["useItemEffect"] = {}, + ["stopMov"] = {}, --[name] = {args}, }, argumentWrapper = "arguments", 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 4b2080a..6412f89 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 @@ -6,6 +6,7 @@ actions["addGFX"] = require(baseURI .. "addGFX") actions["addQTE"] = require(baseURI .. "addQTE") actions["goTo"] = require(baseURI .. "goTo") actions["goTo3D"] = require(baseURI .. "goTo3D") +actions["stopMov"] = require(baseURI .. "stopMov") actions["jumpBack"] = require(baseURI .. "jumpBack") actions["jump"] = require(baseURI .. "jump") actions["playSFX"] = require(baseURI .. "playSFX") diff --git a/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/stopMov.lua b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/stopMov.lua new file mode 100644 index 0000000..492ef03 --- /dev/null +++ b/sonic-radiance.love/scenes/battlesystem/controllers/fighters/systems/choregraphy/step/stopMov.lua @@ -0,0 +1,21 @@ +local StepParent = require "scenes.battlesystem.controllers.fighters.systems.choregraphy.step.parent" +local StopMovStep = StepParent:extend() + +function StopMovStep:new(controller, args) + StopMovStep.super.new(self, controller, args, true) +end + +function StopMovStep:start() + self.choregraphy.actor:stopMoving() + self:finish() +end + +function StopMovStep:update(dt) + +end + +function StopMovStep:getSignal(signal) + +end + +return StopMovStep;