sonic-bluestreak/sonic-bluestreak.love/scenes/menus/debugmenus/choregraphy/menu.lua

35 lines
1.1 KiB
Lua
Raw Permalink Normal View History

2021-11-25 10:57:13 +01:00
local commons = require "scenes.menus.commons.menu"
local listMenu = require "game.modules.menus.list"
local menu = {}
menu.commons = commons
menu.HeroChoregraphyWidget = listMenu.DualTextWidget:extend()
menu.EnnemyChoregraphyWidget = listMenu.DualTextWidget:extend()
-- ShowBackground
function menu.HeroChoregraphyWidget:new(scene, charName, skillData)
menu.HeroChoregraphyWidget.super.new(self, scene, charName, skillData.name, "")
self.character = charName
self.skillData = skillData
end
function menu.HeroChoregraphyWidget:action()
self.scene:playHeroChoregraphy(self.character, self.skillData)
self.scene.menusystem:deactivate()
end
-- ShowBackground
function menu.EnnemyChoregraphyWidget:new(scene, category, charName, skillData)
menu.EnnemyChoregraphyWidget.super.new(self, scene, charName, skillData.name, "")
self.category = category
self.character = charName
self.skillData = skillData
end
function menu.EnnemyChoregraphyWidget:action()
self.scene:playEnnemyChoregraphy(self.category, self.character, self.skillData)
self.scene.menusystem:deactivate()
end
return menu