sonic-radiance/sonic-radiance.love/scenes/battlesystem/actors/systems/actions/dashForward.lua

19 lines
552 B
Lua

local ChoregraphyActionParent = require "scenes.battlesystem.actors.systems.actions.parent"
local DashAction = ChoregraphyActionParent:extend()
function DashAction:new(system, args, effectArea)
DashAction.super.new(self, system, args, effectArea)
end
function DashAction:start()
self.actor:setMotionX(self.actor.direction, self.args.speed)
self.actor:blockChoregraphy(self.args.blockProcess, "action_dashForward")
end
function DashAction:getSignal(signal)
if (signal == "actorHaveFinished") then
self:finish()
end
end
return DashAction;