Files
itgmania212121/NoteSkins/dance/midi-vivid/NoteSkin.lua
T
2010-08-18 14:16:57 -05:00

117 lines
2.5 KiB
Lua

-- Haggen Daze
local ret = ... or {};
ret.RedirTable =
{
Up = "Down",
Down = "Down",
Left = "Down",
Right = "Down",
UpLeft = "Down",
UpRight = "Down",
};
local OldRedir = ret.Redir;
ret.Redir = function(sButton, sElement)
sButton = ret.RedirTable[sButton];
return sButton, sElement;
end
-- To have separate graphics for each hold part:
local OldRedir = ret.Redir;
ret.Redir = function(sButton, sElement)
-- Redirect non-hold, non-roll parts.
if string.find(sElement, "hold") or string.find(sElement, "roll") then
return sButton, sElement;
end
return OldRedir(sButton, sElement);
end
--[[
local OldFunc = ret.Load;
function ret.Load()
local t = OldFunc();
-- The main "Explosion" part just loads other actors; don't rotate
-- it. The "Hold Explosion" part should not be rotated.
if Var "Element" == "Explosion" or
Var "Element" == "Roll Explosion" then
t.BaseRotationZ = nil;
end
return t;
end
local OldRedir = ret.Redir;
ret.Redir = function(sButton, sElement)
sButton, sElement = OldRedir(sButton, sElement);
--we want to use custom hold/roll per direction, but
--keep global hold/roll heads and explosions.
if not string.find(sElement, "Head") and
not string.find(sElement, "Explosion") then
if string.find(sElement, "Hold") or
string.find(sElement, "Roll") then
return sButton, sElement;
end
end
sButton = ret.RedirTable[sButton];
return sButton, sElement;
end
]]
local OldFunc = ret.Load;
function ret.Load()
local t = OldFunc();
--Explosion should not be rotated; it calls other actors.
if Var "Element" == "Explosion" then
t.BaseRotationZ = nil;
end
return t;
end
ret.PartsToRotate =
{
["Receptor"] = true,
["Go Receptor"] = true,
["Ready Receptor"] = true,
["Tap Explosion Bright"] = true,
["Tap Explosion Dim"] = true,
["Tap Note"] = true,
["Tap Lift"] = true,
["Hold Head Active"] = true,
["Hold Head Inactive"] = true,
["Roll Head Active"] = true,
["Roll Head Inactive"] = true,
["Hold Explosion"] = true,
["Roll Explosion"] = true,
};
ret.Rotate =
{
Up = 180,
Down = 0,
Left = 90,
Right = -90,
UpLeft = 135,
UpRight = 225,
};
ret.Blank =
{
["Hold Topcap Active"] = true,
["Hold Topcap Inactive"] = true,
["Roll Topcap Active"] = true,
["Roll Topcap Inactive"] = true,
["Hold Tail Active"] = true,
["Hold Tail Inactive"] = true,
["Roll Tail Active"] = true,
["Roll Tail Inactive"] = true,
["Roll Explosion"] = true,
};
return ret;