Remove SM5 default theme

This commit is contained in:
Martin Natano
2022-05-11 11:24:24 +02:00
parent d54bc6857f
commit 2ce8bcea76
572 changed files with 0 additions and 14252 deletions
-6
View File
@@ -122,12 +122,6 @@ Data/UserPrefs
Data/uPrefs
Data/GamePrefs/*.cfg
Data/Static.ini
Themes/pump
Themes/pump-*
Themes/optical-release
Themes/moonlight
Themes/ultralight
Themes/test
src/version.bin
src/verstub.cpp
src/build-*
-8
View File
@@ -1,8 +0,0 @@
local fSleepTime = THEME:GetMetric( Var "LoadingScreen","ScreenOutDelay");
return Def.ActorFrame {
StartTransitioningCommand=cmd(sleep,0.15+fSleepTime);
Def.Quad {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH+1,SCREEN_HEIGHT;draworder,10000);
StartTransitioningCommand=cmd(diffuse,color("0,0,0,0");diffusealpha,1;sleep,fSleepTime;linear,0.3;diffusealpha,0);
};
};
-7
View File
@@ -1,7 +0,0 @@
return Def.ActorFrame {
StartTransitioningCommand=cmd(sleep,0.15);
Def.Quad {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH+1,SCREEN_HEIGHT;draworder,10000);
StartTransitioningCommand=cmd(diffusealpha,0;diffuse,color("0,0,0,0");linear,0.3;diffusealpha,1);
};
};
Binary file not shown.

Before

Width:  |  Height:  |  Size: 302 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 52 KiB

@@ -1,32 +0,0 @@
-- You know what, I guess the "fancy UI background" theme option can be put to use.
if ThemePrefs.Get("FancyUIBG") then
return Def.ActorFrame {
Def.Quad {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;diffuse,color("#18060C");diffusetopedge,color("#000000"));
};
LoadActor("_base") .. {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;blend,'BlendMode_Add');
},
LoadActor("_barcode") .. {
InitCommand=cmd(zoomto,36,1024;diffuse,color("#882D47");x,SCREEN_LEFT+15;y,SCREEN_CENTER_Y;diffusealpha,0.1);
OnCommand=cmd(customtexturerect,0,0,1,1;texcoordvelocity,0,-0.1);
};
LoadActor("_barcode") .. {
InitCommand=cmd(zoomto,36,1024;diffuse,color("#882D47");x,SCREEN_RIGHT-15;y,SCREEN_CENTER_Y;diffusealpha,0.1);
OnCommand=cmd(customtexturerect,0,0,1,1;texcoordvelocity,0,0.1);
};
};
else
return Def.ActorFrame {
Def.Quad {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;diffuse,color("#18060C");diffusetopedge,color("#000000"));
};
LoadActor("_base") .. {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;blend,'BlendMode_Add');
},
};
end
@@ -1,10 +0,0 @@
return Def.ActorFrame {
Def.Quad {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH+1,SCREEN_HEIGHT);
StartTransitioningCommand=cmd(diffuse,color("0,0,0,0.5");sleep,5/60;diffusealpha,1;sleep,5/60);
};
LoadActor(THEME:GetPathS("_Screen","cancel")) .. {
IsAction= true,
StartTransitioningCommand=cmd(play);
};
};
@@ -1,7 +0,0 @@
return Def.ActorFrame {
StartTransitioningCommand=cmd(sleep,0.7);
Def.Quad {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH+1,SCREEN_HEIGHT;draworder,10000);
StartTransitioningCommand=cmd(diffusealpha,0;diffuse,color("0,0,0,0");sleep,0.6;linear,0.15;diffusealpha,0);
};
};
@@ -1 +0,0 @@
Fade in
Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.9 KiB

@@ -1,38 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = LoadActor(THEME:GetPathG("common bg", "base")) .. {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT)
};
-- Fade
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center);
Def.Quad {
InitCommand=cmd(scaletoclipped,SCREEN_WIDTH,SCREEN_HEIGHT);
OnCommand=cmd(diffuse,Color.Black;diffusealpha,0.8);
};
};
-- Emblem
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y);
OnCommand=cmd(diffusealpha,0.5);
LoadActor("_warning bg") .. {
};
};
-- Text
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y-120);
OnCommand=cmd(diffusealpha,0;linear,0.2;diffusealpha,1);
LoadFont("_roboto condensed Bold 48px") .. {
Text=Screen.String("Caution");
OnCommand=cmd(skewx,-0.1;diffuse,color("#E6BF7C");diffusebottomedge,color("#FFB682");strokecolor,color("#594420"));
};
LoadFont("Common Fallback Font") .. {
Text=Screen.String("CautionText");
InitCommand=cmd(y,128);
OnCommand=cmd(strokecolor,color("0,0,0,0.5");shadowlength,1;wrapwidthpixels,SCREEN_WIDTH/0.5);
};
};
--
return t
@@ -1,31 +0,0 @@
local timer_seconds = THEME:GetMetric(Var "LoadingScreen","TimerSeconds")
local t = Def.ActorFrame {}
-- Fade
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center),
Def.Quad {
InitCommand=cmd(scaletoclipped,SCREEN_WIDTH,SCREEN_HEIGHT),
OnCommand=function(self)
self:diffuse(Color.Black):diffusealpha(0):linear(0.5):diffusealpha(0.25)
self:sleep(timer_seconds/2):linear(timer_seconds/2-0.5):diffusealpha(1)
end,
OffCommand=cmd(stoptweening;sleep,0.4;decelerate,0.5;diffusealpha,1)
},
-- Warning Fade
Def.Quad {
InitCommand=cmd(y,16;scaletoclipped,SCREEN_WIDTH,250),
OnCommand=cmd(diffuse,Color.Black;diffusealpha,0.5;linear,timer_seconds;zoomtoheight,180),
OffCommand=cmd(stoptweening)
}
}
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center;y,SCREEN_CENTER_Y-56;zoom,1.5),
LoadFont("Common Fallback Font") .. {
Text="Continue?",
OnCommand=cmd(diffuse,color("#FF8312");diffusebottomedge,color("#FFD75B");shadowlength,1;strokecolor,color("#472211"))
}
}
return t
@@ -1 +0,0 @@
ScreenLogo background
@@ -1,75 +0,0 @@
return Def.ActorFrame{
-- "header"
Def.Quad {
InitCommand=cmd(vertalign,top;x,_screen.cx;zoomto,_screen.w,80),
OnCommand=function(self)
self:diffuse(ScreenColor("Default")):diffusetopedge(ColorDarkTone(ScreenColor("Default"))):diffusealpha(0.8)
end
},
-- The "header's" "shadow"
Def.Quad {
InitCommand=cmd(vertalign,top;x,_screen.cx;zoomto,SCREEN_WIDTH,8;y,80),
OnCommand=cmd(diffuse,Color("Black");fadebottom,1;diffusealpha,0.6)
},
-- "footer"
Def.Quad {
InitCommand=cmd(vertalign,bottom;x,_screen.cx;y,_screen.h;zoomto,_screen.w,96),
OnCommand=function(self)
self:diffuse(ScreenColor("Default")):diffusebottomedge(ColorDarkTone(ScreenColor("Default"))):diffusealpha(0.8)
end
},
-- The "footer's" "shadow"
Def.Quad {
InitCommand=cmd(vertalign,bottom;x,_screen.cx;y,_screen.h-96;zoomto,_screen.w,8),
OnCommand=cmd(diffuse,Color("Black");fadetop,1;diffusealpha,0.6)
},
-- A temporary frame for the jacket.
Def.Quad {
InitCommand=cmd(horizalign,right;vertalign,bottom;x,_screen.w-39;y,_screen.h-14;zoomto,192,192;diffuse,ColorDarkTone(ScreenColor("Default"));diffusealpha,0.9)
},
-- Jacket (real or not) of the currently playing song.
-- todo: make getting the jacket a bit more of a... global function?
Def.Sprite {
InitCommand=cmd(horizalign,right;vertalign,bottom;x,_screen.w-49;y,_screen.h-24),
OnCommand=function(self)
local song = GAMESTATE:GetCurrentSong()
if song and song:HasJacket() then
-- ...The jacket on ScreenEditMenu overlay uses LoadBanner instead of just Load.
-- Will it make any difference? ... I mean, probably not, but we'll see.
self:LoadBanner(song:GetJacketPath())
elseif song and song:HasBackground() then
self:LoadBanner(song:GetBackgroundPath())
else
self:LoadBanner(THEME:GetPathG("Common","fallback background"))
end
self:scaletoclipped(172,172)
end
},
-- Song title.
Def.BitmapText {
Font = "Common Fallback Font",
InitCommand=cmd(horizalign,right;x,_screen.w-250;y,_screen.h-64;strokecolor,color("#42292E")),
OnCommand=function(self)
local song = GAMESTATE:GetCurrentSong()
if song then
self:settext(song:GetDisplayFullTitle())
else
self:settext("")
end
end
},
-- Song artist.
Def.BitmapText {
Font = "Common Fallback Font",
InitCommand=cmd(horizalign,right;x,_screen.w-250;y,_screen.h-40;zoom,0.7;strokecolor,color("#42292E")),
OnCommand=function(self)
local song = GAMESTATE:GetCurrentSong()
if song then
self:settext(song:GetDisplayArtist())
else
self:settext("")
end
end
},
}
@@ -1,16 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = Def.ActorFrame {
FOV=90;
InitCommand=cmd(Center);
Def.Quad {
InitCommand=cmd(scaletoclipped,SCREEN_WIDTH,SCREEN_HEIGHT);
OnCommand=cmd(diffuse,ColorMidTone(color("#451A20"));diffusebottomedge,ColorMidTone(color("#5E2A30"));diffusealpha,0.9);
};
LoadActor (GetSongBackground()) .. {
InitCommand=cmd(scaletoclipped,SCREEN_WIDTH,SCREEN_HEIGHT);
OnCommand=cmd(diffusealpha,0.1;);
};
};
return t;
@@ -1,18 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center);
Def.Quad {
InitCommand=cmd(scaletoclipped,SCREEN_WIDTH,SCREEN_HEIGHT);
OnCommand=cmd(diffuse,color("#947B7E");diffusebottomedge,color("#D698A0"));
};
};
t[#t+1] = Def.ActorFrame {
Def.Quad {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y+20;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT*0.70);
OnCommand=cmd(diffuse,color("#61414B");diffusealpha,0.75);
};
};
return t;
@@ -1,6 +0,0 @@
local transition_params = {
color = color("#914D56"),
transition_type = "in"
}
return LoadActor(THEME:GetPathB("", "_transition"), transition_params)
@@ -1 +0,0 @@
_blank
@@ -1,78 +0,0 @@
local t = Def.ActorFrame {};
if not GAMESTATE:IsCourseMode() then
t[#t+1] = Def.ActorFrame {
LoadActor(THEME:GetPathG("ScreenEvaluation", "StageDisplay")) .. {
InitCommand=cmd(x,SCREEN_RIGHT-290;y,SCREEN_TOP+49);
OffCommand=cmd(sleep,0.175;decelerate,0.4;addy,-105),
}
}
else
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_RIGHT-290;y,SCREEN_TOP+49);
OffCommand=cmd(sleep,0.175;decelerate,0.4;addy,-105),
LoadActor(THEME:GetPathG("", "_sortFrame")) .. {
InitCommand=cmd(diffusealpha,0.9;zoom,1.5);
BeginCommand=function(self)
self:playcommand("Set")
end;
SetCommand=function(self)
local curStage = GAMESTATE:GetCurrentStage();
self:diffuse(StageToColor(curStage));
end
};
LoadFont("Common Italic Condensed") .. {
InitCommand=cmd(y,-1;zoom,1;shadowlength,1;uppercase,true);
BeginCommand=function(self)
self:playcommand("Set")
end;
CurrentSongChangedMessageCommand= cmd(playcommand,"Set"),
SetCommand=function(self)
local curStage = GAMESTATE:GetCurrentStage();
local course = GAMESTATE:GetCurrentCourse()
self:settext(string.upper(ToEnumShortString( course:GetCourseType() )))
-- StepMania is being stupid so we have to do this here;
self:diffuse(StageToColor(curStage)):diffusetopedge(ColorLightTone(StageToColor(curStage)));
self:diffusealpha(0):smooth(0.3):diffusealpha(1);
end;
};
}
end;
if GAMESTATE:HasEarnedExtraStage() then
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_RIGHT-290;y,SCREEN_TOP+49);
OffCommand=cmd(sleep,0.175;decelerate,0.4;addy,-105),
LoadActor(THEME:GetPathG("", "_sortFrame")) .. {
InitCommand=cmd(diffusealpha,0.9;zoom,1.5);
BeginCommand=function(self)
self:playcommand("Set")
end;
SetCommand=function(self)
local curStage = GAMESTATE:GetCurrentStage();
self:diffuse(StageToColor(curStage));
end
};
LoadActor(THEME:GetPathG("", "_sortFrame")) .. {
InitCommand=cmd(diffusealpha,0.9;zoom,1.5;diffuse,color("#FFFFFF");blend,'add');
BeginCommand=cmd(diffuseshift;effectcolor2,color("1,1,1,0.3");effectcolor2,color("1,1,1,0");effectperiod,2);
};
LoadFont("Common Italic Condensed") .. {
InitCommand=cmd(y,-1;zoom,1;shadowlength,1;uppercase,true;maxwidth,220);
BeginCommand=function(self)
self:playcommand("Set")
end;
CurrentSongChangedMessageCommand= cmd(playcommand,"Set"),
SetCommand=function(self)
local curStage = GAMESTATE:GetCurrentStage();
local text = string.upper(THEME:GetString("ScreenEvaluation", "ExtraUnlocked"))
self:settext(text)
-- StepMania is being stupid so we have to do this here;
self:diffuse(StageToColor(curStage)):diffusetopedge(ColorLightTone(StageToColor(curStage)));
self:diffusealpha(0):smooth(0.3):diffusealpha(1);
end;
};
}
end;
return t;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 543 B

@@ -1,422 +0,0 @@
local t = Def.ActorFrame {};
-- A very useful table...
local eval_lines = {
"W1",
"W2",
"W3",
"W4",
"W5",
"Miss",
"MaxCombo"
}
local eval_radar = {
Types = { 'Holds', 'Rolls', 'Hands', 'Mines', 'Lifts' },
}
local grade_area_offset = 16
local fade_out_speed = 0.3
local fade_out_pause = 0.08
-- And a function to make even better use out of the table.
local function GetJLineValue(line, pl)
if line == "Held" then
return STATSMAN:GetCurStageStats():GetPlayerStageStats(pl):GetHoldNoteScores("HoldNoteScore_Held")
elseif line == "MaxCombo" then
return STATSMAN:GetCurStageStats():GetPlayerStageStats(pl):MaxCombo()
else
return STATSMAN:GetCurStageStats():GetPlayerStageStats(pl):GetTapNoteScores("TapNoteScore_" .. line)
end
return "???"
end
-- You know what, we'll deal with getting the overall scores with a function too.
local function GetPlScore(pl, scoretype)
local primary_score = STATSMAN:GetCurStageStats():GetPlayerStageStats(pl):GetScore()
local secondary_score = FormatPercentScore(STATSMAN:GetCurStageStats():GetPlayerStageStats(pl):GetPercentDancePoints())
if PREFSMAN:GetPreference("PercentageScoring") then
primary_score, secondary_score = secondary_score, primary_score
end
if scoretype == "primary" then
return primary_score
else
return secondary_score
end
end
-- #################################################
-- That's enough functions; let's get this done.
-- Shared portion.
local mid_pane = Def.ActorFrame {
OnCommand=cmd(diffusealpha,0;sleep,0.3;decelerate,0.4;diffusealpha,1);
OffCommand=cmd(decelerate,0.3;diffusealpha,0);
-- Song/course banner.
Def.Sprite {
InitCommand=function(self)
local target = GAMESTATE:IsCourseMode() and GAMESTATE:GetCurrentCourse() or GAMESTATE:GetCurrentSong()
if target and target:HasBanner() then
self:Load(target:GetBannerPath())
else
self:Load(THEME:GetPathG("Common fallback", "banner"))
end
self:scaletoclipped(468,146):x(_screen.cx):y(_screen.cy-173):zoom(0.8)
end
},
-- Banner frame.
LoadActor("_bannerframe") .. {
InitCommand=cmd(x,_screen.cx;y,_screen.cy-172;zoom,0.8)
}
}
-- Song or Course Title
if not GAMESTATE:IsCourseMode() then
mid_pane[#mid_pane+1] = Def.BitmapText {
Font="Common Fallback",
InitCommand=function(self)
self:x(_screen.cx):y(_screen.cy+188-6):diffuse(color("#512232")):shadowlength(1):zoom(0.75):maxwidth(500)
end;
OnCommand=function(self)
local song = GAMESTATE:GetCurrentSong();
if song then
self:settext(song:GetDisplayMainTitle());
else
self:settext("");
end;
self:diffusealpha(0):sleep(1.0):decelerate(0.4):diffusealpha(1)
end,
OffCommand=cmd(decelerate,0.4;diffusealpha,0)
}
mid_pane[#mid_pane+1] = Def.BitmapText {
Font="Common Fallback",
InitCommand=function(self)
self:x(_screen.cx):y(_screen.cy+188+22-6):diffuse(color("#512232")):shadowlength(1):zoom(0.6):maxwidth(500)
end;
OnCommand=function(self)
local song = GAMESTATE:GetCurrentSong();
if song then
self:settext(song:GetDisplaySubTitle());
else
self:settext("");
end;
self:diffusealpha(0):sleep(1.1):decelerate(0.4):diffusealpha(1)
end,
OffCommand=cmd(decelerate,0.4;diffusealpha,0)
}
else
mid_pane[#mid_pane+1] = Def.BitmapText {
Font="Common Fallback",
InitCommand=function(self)
self:x(_screen.cx):y(_screen.cy+188-6):diffuse(color("#512232")):shadowlength(1):zoom(0.75):maxwidth(500)
end;
OnCommand=function(self)
local course = GAMESTATE:GetCurrentCourse()
self:settext(course:GetDisplayFullTitle())
self:diffusealpha(0):sleep(1.3):decelerate(0.4):diffusealpha(1)
end,
OffCommand=cmd(decelerate,0.4;diffusealpha,0)
}
end
-- Each line's text, and associated decorations.
for i, v in ipairs(eval_lines) do
local spacing = 38*i
local cur_line = "JudgmentLine_" .. v
mid_pane[#mid_pane+1] = Def.ActorFrame{
InitCommand=cmd(x,_screen.cx;y,(_screen.cy/1.48)+(spacing)),
Def.Quad {
InitCommand=cmd(zoomto,400,36;diffuse,JudgmentLineToColor(cur_line);fadeleft,0.5;faderight,0.5);
OnCommand=function(self)
self:diffusealpha(0):sleep(0.1 * i):decelerate(0.6):diffusealpha(1)
end;
OffCommand=function(self)
self:sleep(fade_out_pause * i):decelerate(fade_out_speed):diffusealpha(0)
end;
};
Def.BitmapText {
Font = "_roboto condensed Bold 48px",
InitCommand=cmd(zoom,0.6;diffuse,color("#000000");settext,string.upper(JudgmentLineToLocalizedString(cur_line)));
OnCommand=function(self)
self:diffusealpha(0):sleep(0.1 * i):decelerate(0.6):diffusealpha(0.8)
end;
OffCommand=function(self)
self:sleep(fade_out_pause * i):decelerate(fade_out_speed):diffusealpha(0)
end;
}
}
end
t[#t+1] = mid_pane
-- #################################################
-- Time to deal with all of the player stats. ALL OF THEM.
local eval_parts = Def.ActorFrame {}
for ip, p in ipairs(GAMESTATE:GetHumanPlayers()) do
-- Some things to help positioning
local step_count_offs = string.find(p, "P1") and -140 or 140
local grade_parts_offs = string.find(p, "P1") and -320 or 320
local p_grade = STATSMAN:GetCurStageStats():GetPlayerStageStats(p):GetGrade()
-- Step counts.
for i, v in ipairs(eval_lines) do
local spacing = 38*i
eval_parts[#eval_parts+1] = Def.BitmapText {
Font = "_overpass 36px",
InitCommand=cmd(x,_screen.cx + step_count_offs;y,(_screen.cy/1.48)+(spacing);diffuse,ColorDarkTone(PlayerColor(p));zoom,0.75;diffusealpha,1.0;shadowlength,1;maxwidth,120),
OnCommand=function(self)
self:settext(GetJLineValue(v, p))
if string.find(p, "P1") then
self:horizalign(right)
else
self:horizalign(left)
end
self:diffusealpha(0):sleep(0.1 * i):decelerate(0.6):diffusealpha(1)
end;
OffCommand=function(self)
self:sleep(fade_out_pause * i):decelerate(fade_out_speed):diffusealpha(0)
end;
}
end
-- Letter grade and associated parts.
eval_parts[#eval_parts+1] = Def.ActorFrame{
InitCommand=cmd(x,_screen.cx + grade_parts_offs;y,_screen.cy/1.91),
--Containers
Def.Quad {
InitCommand=cmd(zoomto,190,115;diffuse,ColorLightTone(PlayerColor(p));diffusebottomedge,color("#FEEFCA")),
OnCommand=function(self)
self:diffusealpha(0):decelerate(0.4):diffusealpha(0.5)
end,
OffCommand=cmd(decelerate,0.3;diffusealpha,0)
},
Def.Quad {
InitCommand=cmd(vertalign,top;y,60+grade_area_offset;zoomto,190,136;diffuse,color("#fce1a1")),
OnCommand=function(self)
self:diffusealpha(0):decelerate(0.4):diffusealpha(0.4)
end,
OffCommand=cmd(decelerate,0.3;diffusealpha,0)
},
LoadActor(THEME:GetPathG("GradeDisplay", "Grade " .. p_grade)) .. {
InitCommand=cmd(zoom,0.75);
OnCommand=function(self)
self:diffusealpha(0):zoom(1):sleep(0.63):decelerate(0.4):zoom(0.75):diffusealpha(1)
if STATSMAN:GetCurStageStats():GetPlayerStageStats(p):GetStageAward() then
self:sleep(0.1):decelerate(0.4):addy(-12);
else
self:addy(0);
end;
end;
OffCommand=cmd(decelerate,0.3;diffusealpha,0);
},
Def.BitmapText {
Font = "_roboto condensed 24px",
InitCommand=cmd(diffuse,Color.White;zoom,1;addy,38;maxwidth,160;uppercase,true;diffuse,ColorDarkTone(PlayerDarkColor(p));diffusetopedge,ColorMidTone(PlayerColor(p));shadowlength,1),
OnCommand=function(self)
if STATSMAN:GetCurStageStats():GetPlayerStageStats(p):GetStageAward() then
self:settext(THEME:GetString( "StageAward", ToEnumShortString(STATSMAN:GetCurStageStats():GetPlayerStageStats(p):GetStageAward()) ))
self:diffusealpha(0):zoomx(0.5):sleep(1):decelerate(0.4):zoomx(1):diffusealpha(1)
end
end;
OffCommand=cmd(decelerate,0.3;diffusealpha,0);
}
}
-- Primary score.
eval_parts[#eval_parts+1] = Def.BitmapText {
Font = "_overpass 36px",
InitCommand=cmd(horizalign,center;x,_screen.cx + (grade_parts_offs);y,(_screen.cy-59)+grade_area_offset;diffuse,ColorMidTone(PlayerColor(p));zoom,1;shadowlength,1;maxwidth,180),
OnCommand=function(self)
self:settext(GetPlScore(p, "primary")):diffusealpha(0):sleep(0.5):decelerate(0.3):diffusealpha(1)
end;
OffCommand=function(self)
self:decelerate(0.3):diffusealpha(0)
end;
}
-- Secondary score.
eval_parts[#eval_parts+1] = Def.BitmapText {
Font = "_overpass 36px",
InitCommand=cmd(horizalign,center;x,_screen.cx + (grade_parts_offs);y,(_screen.cy-59)+35+grade_area_offset;diffuse,ColorDarkTone(PlayerColor(p));zoom,0.75;shadowlength,1),
OnCommand=function(self)
self:settext(GetPlScore(p, "secondary")):diffusealpha(0):sleep(0.6):decelerate(0.3):diffusealpha(1)
end;
OffCommand=function(self)
self:sleep(0.1):decelerate(0.3):diffusealpha(0)
end;
}
eval_parts[#eval_parts+1] = Def.BitmapText {
Font = "Common Condensed",
InitCommand=cmd(horizalign,center;x,_screen.cx + (grade_parts_offs);y,(_screen.cy-50)+56+grade_area_offset;diffuse,ColorDarkTone(PlayerColor(p));zoom,0.75;shadowlength,1;maxwidth,180),
OnCommand=function(self)
local record = STATSMAN:GetCurStageStats():GetPlayerStageStats(p):GetPersonalHighScoreIndex()
local hasPersonalRecord = record ~= -1
self:visible(hasPersonalRecord);
local text = string.format(THEME:GetString("ScreenEvaluation", "PersonalRecord"), record+1)
self:settext(text)
self:diffusealpha(0):sleep(0.6):decelerate(0.3):diffusealpha(0.9)
end;
OffCommand=function(self)
self:sleep(0.1):decelerate(0.3):diffusealpha(0)
end;
}
-- Other stats (holds, mines, etc.)
for i, rc_type in ipairs(eval_radar.Types) do
local performance = STATSMAN:GetCurStageStats():GetPlayerStageStats(p):GetRadarActual():GetValue( "RadarCategory_"..rc_type )
local possible = STATSMAN:GetCurStageStats():GetPlayerStageStats(p):GetRadarPossible():GetValue( "RadarCategory_"..rc_type )
local label = THEME:GetString("RadarCategory", rc_type)
eval_parts[#eval_parts+1] = Def.ActorFrame {
InitCommand=function(self)
self:x(_screen.cx + (grade_parts_offs))
self:y((_screen.cy + 104 - 32) + (i-1)*32)
end;
OnCommand=function(self)
self:diffusealpha(0):sleep(0.1 * i):decelerate(0.5):diffusealpha(1)
end;
OffCommand=function(self)
self:sleep(0.13 * i):decelerate(0.6):diffusealpha(0)
end;
Def.Quad {
InitCommand=cmd(zoomto,190,28;diffuse,color("#fce1a1");diffusealpha,0.4);
};
Def.BitmapText {
Font = "Common Condensed",
InitCommand=cmd(zoom,0.8;x,-80;horizalign,left;diffuse,color("0,0,0,0.75");shadowlength,1),
BeginCommand=function(self)
self:settext(label .. ":")
end
};
Def.BitmapText {
Font = "_overpass 36px",
InitCommand=cmd(zoom,0.5;x,83;horizalign,right;maxwidth,200;diffuse,ColorDarkTone(PlayerColor(p));shadowlength,1),
BeginCommand=function(self)
self:settext(performance .. "/" .. possible)
end
};
};
end;
-- Options
eval_parts[#eval_parts+1] = Def.BitmapText {
Font = "Common Condensed",
InitCommand=cmd(horizalign,center;vertalign,top;x,_screen.cx + (grade_parts_offs);y,(_screen.cy+196+43);wrapwidthpixels,240;diffuse,ColorDarkTone(PlayerColor(p));zoom,0.75;shadowlength,1),
OnCommand=function(self)
self:settext(GAMESTATE:GetPlayerState(p):GetPlayerOptionsString(0))
self:diffusealpha(0):sleep(0.8):decelerate(0.6):diffusealpha(1)
end;
OffCommand=function(self)
self:sleep(0.1):decelerate(0.3):diffusealpha(0)
end;
};
end
t[#t+1] = eval_parts
-- todo: replace.
if GAMESTATE:IsHumanPlayer(PLAYER_1) == true then
if GAMESTATE:IsCourseMode() == false then
-- Difficulty banner
local grade_parts_offs = -320
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(horizalign,center;x,_screen.cx + grade_parts_offs;y,_screen.cy-96+grade_area_offset;visible,not GAMESTATE:IsCourseMode());
OnCommand=cmd(zoomx,0.3;diffusealpha,0;sleep,0.5;decelerate,0.4;zoomx,1;diffusealpha,1);
OffCommand=cmd(decelerate,0.4;diffusealpha,0);
LoadFont("Common Fallback") .. {
InitCommand=cmd(zoom,1;horizalign,center;shadowlength,1);
OnCommand=cmd(playcommand,"Set");
CurrentStepsP1ChangedMessageCommand=cmd(playcommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(playcommand,"Set");
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1 ~= nil then
local st = stepsP1:GetStepsType();
local diff = stepsP1:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cdp1 = GetCustomDifficulty(st, diff, courseType);
self:settext(string.upper(THEME:GetString("CustomDifficulty",ToEnumShortString(diff))) .. " " .. stepsP1:GetMeter());
self:diffuse(ColorDarkTone(CustomDifficultyToColor(cdp1)));
else
self:settext("")
end
else
self:settext("")
end
end
};
};
end;
end;
if GAMESTATE:IsHumanPlayer(PLAYER_2) == true then
if GAMESTATE:IsCourseMode() == false then
local grade_parts_offs = 320
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(horizalign,center;x,_screen.cx + grade_parts_offs;y,_screen.cy-96+grade_area_offset;visible,not GAMESTATE:IsCourseMode());
OnCommand=cmd(zoomx,0.3;diffusealpha,0;sleep,0.5;decelerate,0.4;zoomx,1;diffusealpha,1);
OffCommand=cmd(decelerate,0.4;diffusealpha,0);
LoadFont("Common Fallback") .. {
InitCommand=cmd(zoom,1;horizalign,center;shadowlength,1);
OnCommand=cmd(playcommand,"Set");
CurrentStepsP2ChangedMessageCommand=cmd(playcommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(playcommand,"Set");
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP2 ~= nil then
local st = stepsP2:GetStepsType();
local diff = stepsP2:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cdp2 = GetCustomDifficulty(st, diff, courseType);
self:settext(string.upper(THEME:GetString("CustomDifficulty",ToEnumShortString(diff))) .. " " .. stepsP2:GetMeter());
self:diffuse(ColorDarkTone(CustomDifficultyToColor(cdp2)));
else
self:settext("")
end
else
self:settext("")
end
end
};
};
end;
end;
t[#t+1] = StandardDecorationFromFileOptional("LifeDifficulty","LifeDifficulty");
t[#t+1] = StandardDecorationFromFileOptional("TimingDifficulty","TimingDifficulty");
if gameplay_pause_count > 0 then
t[#t+1]= Def.BitmapText{
Font= "Common Italic Condensed",
Text= THEME:GetString("PauseMenu", "pause_count") .. ": " .. gameplay_pause_count,
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y-130;shadowlength,1;maxwidth,140);
OnCommand=function(self)
self:diffuse(color("#FF0000")):diffusebottomedge(color("#512232")):zoom(0.8);
self:diffusealpha(0):sleep(1.5):smooth(0.3):diffusealpha(1);
end;
OffCommand=cmd(sleep,0.2;decelerate,0.3;diffusealpha,0);
}
end
return t;
@@ -1 +0,0 @@
_blank
@@ -1,168 +0,0 @@
local t = Def.ActorFrame {};
-- A very useful table...
local eval_lines = {
"W1",
"W2",
"W3",
"W4",
"W5",
"Miss",
"Held",
"MaxCombo"
}
local grade_area_offset = 16
local fade_out_speed = 0.3
local fade_out_pause = 0.08
-- And a function to make even better use out of the table.
local function GetJLineValue(line, pl)
if line == "Held" then
return STATSMAN:GetAccumPlayedStageStats():GetPlayerStageStats(pl):GetHoldNoteScores("HoldNoteScore_Held")
elseif line == "MaxCombo" then
return STATSMAN:GetAccumPlayedStageStats():GetPlayerStageStats(pl):MaxCombo()
else
return STATSMAN:GetAccumPlayedStageStats():GetPlayerStageStats(pl):GetTapNoteScores("TapNoteScore_" .. line)
end
return "???"
end
-- You know what, we'll deal with getting the overall scores with a function too.
local function GetPlScore(pl, scoretype)
local primary_score = STATSMAN:GetAccumPlayedStageStats():GetPlayerStageStats(pl):GetScore()
local secondary_score = FormatPercentScore(STATSMAN:GetAccumPlayedStageStats():GetPlayerStageStats(pl):GetPercentDancePoints())
if PREFSMAN:GetPreference("PercentageScoring") then
primary_score, secondary_score = secondary_score, primary_score
end
if scoretype == "primary" then
return primary_score
else
return secondary_score
end
end
-- Each line's text, and associated decorations.
for i, v in ipairs(eval_lines) do
local spacing = 38*i
local cur_line = "JudgmentLine_" .. v
t[#t+1] = Def.ActorFrame{
InitCommand=cmd(x,_screen.cx;y,(_screen.cy/1.48)+(spacing)),
Def.Quad {
InitCommand=cmd(zoomto,400,36;diffuse,JudgmentLineToColor(cur_line);fadeleft,0.5;faderight,0.5);
OnCommand=function(self)
self:diffusealpha(0):sleep(0.1 * i):decelerate(0.6):diffusealpha(0.8)
end;
OffCommand=function(self)
self:sleep(fade_out_pause * i):decelerate(fade_out_speed):diffusealpha(0)
end;
};
Def.BitmapText {
Font = "_roboto condensed Bold 48px",
InitCommand=cmd(zoom,0.6;diffuse,color("#000000");settext,string.upper(JudgmentLineToLocalizedString(cur_line)));
OnCommand=function(self)
self:diffusealpha(0):sleep(0.1 * i):decelerate(0.6):diffusealpha(0.8)
end;
OffCommand=function(self)
self:sleep(fade_out_pause * i):decelerate(fade_out_speed):diffusealpha(0)
end;
}
}
end
-- #################################################
-- Time to deal with all of the player stats. ALL OF THEM.
local eval_parts = Def.ActorFrame {}
for ip, p in ipairs(GAMESTATE:GetHumanPlayers()) do
-- Some things to help positioning
local step_count_offs = string.find(p, "P1") and -140 or 140
local grade_parts_offs = string.find(p, "P1") and -320 or 320
local p_grade = STATSMAN:GetAccumPlayedStageStats():GetPlayerStageStats(p):GetGrade()
-- Step counts.
for i, v in ipairs(eval_lines) do
local spacing = 38*i
eval_parts[#eval_parts+1] = Def.BitmapText {
Font = "_overpass 36px",
InitCommand=cmd(x,_screen.cx + step_count_offs;y,(_screen.cy/1.48)+(spacing);diffuse,ColorDarkTone(PlayerColor(p));zoom,0.75;diffusealpha,1.0;shadowlength,1),
OnCommand=function(self)
self:settext(GetJLineValue(v, p))
if string.find(p, "P1") then
self:horizalign(right)
else
self:horizalign(left)
end
self:diffusealpha(0):sleep(0.1 * i):decelerate(0.6):diffusealpha(1)
end;
OffCommand=function(self)
self:sleep(fade_out_pause * i):decelerate(fade_out_speed):diffusealpha(0)
end;
}
end
-- Letter grade and associated parts.
eval_parts[#eval_parts+1] = Def.ActorFrame{
InitCommand=cmd(x,_screen.cx + grade_parts_offs;y,_screen.cy/1.91),
--Containers.
Def.Quad {
InitCommand=cmd(zoomto,190,115;diffuse,ColorLightTone(PlayerColor(p));diffusebottomedge,color("#FEEFCA"));
OnCommand=function(self)
self:diffusealpha(0):decelerate(0.4):diffusealpha(0.5)
end,
OffCommand=cmd(decelerate,0.3;diffusealpha,0)
},
Def.Quad {
InitCommand=cmd(vertalign,top;y,60+grade_area_offset;zoomto,190,66;diffuse,color("#fce1a1"));
OnCommand=function(self)
self:diffusealpha(0):decelerate(0.4):diffusealpha(0.4)
end,
OffCommand=cmd(decelerate,0.3;diffusealpha,0)
},
LoadActor(THEME:GetPathG("GradeDisplay", "Grade " .. p_grade)) .. {
InitCommand=cmd(zoom,0.75);
OnCommand=function(self)
self:diffusealpha(0):zoom(1):sleep(0.63):decelerate(0.4):zoom(0.75):diffusealpha(1)
end;
OffCommand=cmd(decelerate,0.3;diffusealpha,0);
},
}
-- Primary score.
eval_parts[#eval_parts+1] = Def.BitmapText {
Font = "_overpass 36px",
InitCommand=cmd(horizalign,center;x,_screen.cx + (grade_parts_offs);y,(_screen.cy-65-26)+grade_area_offset;diffuse,ColorMidTone(PlayerColor(p));zoom,1;shadowlength,1;maxwidth,180),
OnCommand=function(self)
self:settext(GetPlScore(p, "primary")):diffusealpha(0):sleep(0.5):decelerate(0.3):diffusealpha(1)
end;
OffCommand=function(self)
self:decelerate(0.3):diffusealpha(0)
end;
}
-- Secondary score.
eval_parts[#eval_parts+1] = Def.BitmapText {
Font = "_overpass 36px",
InitCommand=cmd(horizalign,center;x,_screen.cx + (grade_parts_offs);y,(_screen.cy-65-26)+30+grade_area_offset;diffuse,ColorDarkTone(PlayerColor(p));zoom,0.75;shadowlength,1),
OnCommand=function(self)
self:settext(GetPlScore(p, "secondary")):diffusealpha(0):sleep(0.6):decelerate(0.3):diffusealpha(1)
end;
OffCommand=function(self)
self:sleep(0.1):decelerate(0.3):diffusealpha(0)
end;
}
end
t[#t+1] = eval_parts
return t;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

@@ -1,40 +0,0 @@
local timer_seconds = THEME:GetMetric(Var "LoadingScreen","TimerSeconds");
return Def.ActorFrame {
InitCommand=cmd(Center),
-- Fade
Def.ActorFrame {
InitCommand=cmd();
Def.Quad {
InitCommand=cmd(scaletoclipped,SCREEN_WIDTH,SCREEN_HEIGHT),
OnCommand=cmd(diffuse,Color.Black;diffusealpha,0;linear,0.5;diffusealpha,0.25;
sleep,timer_seconds/2;
linear,timer_seconds/2-0.5;diffusealpha,0.8),
},
},
Def.Quad {
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT),
OnCommand=cmd(diffuse,color("#000000")),
},
LoadActor("_diamond") .. {
InitCommand=cmd(diffusealpha,0);
OnCommand=cmd(rotationz,0;zoom,1;sleep,1;diffusealpha,1;linear,3;zoom,1;diffusealpha,0);
};
LoadActor("_sound") .. {
OnCommand=cmd(queuecommand,"Sound");
SoundCommand=cmd(play);
};
LoadActor(THEME:GetPathG("ScreenGameOver","gameover"))..{
OnCommand=cmd(zoomx,1.1;diffusealpha,0;sleep,1;decelerate,0.6;diffusealpha,1;zoomx,1);
},
LoadFont("Common Condensed")..{
Text=ScreenString("Play again soon!");
InitCommand=cmd(y,68;shadowlength,2);
OnCommand=cmd(diffusealpha,0;sleep,3;linear,0.3;diffusealpha,1);
},
}
@@ -1,3 +0,0 @@
local t = Def.ActorFrame {};
return t
@@ -1,14 +0,0 @@
local t = Def.ActorFrame{};
t[#t+1] = Def.Quad{
InitCommand=cmd(FullScreen;diffuse,color("1,0,0,0");blend,Blend.Multiply);
OnCommand=cmd(smooth,1;diffuse,color("0.75,0,0,0.75");decelerate,2;diffuse,color("0,0,0,1"));
};
t[#t+1] = Def.Quad{
InitCommand=cmd(FullScreen;diffuse,color("1,1,1,1");diffusealpha,0);
OnCommand=cmd(finishtweening;diffusealpha,1;decelerate,1.25;diffuse,color("1,0,0,0"));
};
t[#t+1] = LoadActor(THEME:GetPathS( Var "LoadingScreen", "failed" ) ) .. {
StartTransitioningCommand=cmd(play);
};
return t;
@@ -1,7 +0,0 @@
return LoadActor("go") .. {
InitCommand=cmd(Center;draworder,105);
StartTransitioningCommand=function(self)
self:zoom(1.3):diffusealpha(0):bounceend(0.25):zoom(1):diffusealpha(1);
self:linear(0.14):glow(BoostColor(Color("Blue"),1.75)):decelerate(0.3):glow(1,1,1,0):sleep(1-0.45):linear(0.25):diffusealpha(0);
end;
};
Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

@@ -1,37 +0,0 @@
if not GAMESTATE:IsCourseMode() then return Def.ActorFrame{} end; -- short circuit
local slideTime = 1.1;
local slideWait = 1.25;
local bottomSlide = 0.76;
local course = GAMESTATE:GetCurrentCourse()
local t = Def.ActorFrame{
-- background
Def.Sprite{
InitCommand=cmd(Center);
BeginCommand=function(self)
if course:GetBackgroundPath() then
self:Load( course:GetBackgroundPath() )
else
-- default to the BG of the first song in the course
self:LoadFromCurrentSongBackground()
end
end;
OnCommand=function(self)
self:scale_or_crop_background()
self:addy(SCREEN_HEIGHT):sleep(slideWait):smooth(slideTime):addy(-SCREEN_HEIGHT);
end;
};
-- alternate background
Def.Sprite{
InitCommand=cmd(Center);
BeginCommand=cmd(LoadFromCurrentSongBackground;scale_or_crop_background;diffusealpha,0);
OnCommand=cmd(playcommand,"Show");
ShowCommand=function(self)
if course:HasBackground() then
self:addy(SCREEN_HEIGHT):sleep(slideWait):smooth(slideTime):addy(-SCREEN_HEIGHT);
end
end;
};
};
return t;
@@ -1,19 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = Def.Sprite {
InitCommand=cmd(Center;diffusealpha,1);
BeginCommand=cmd(LoadFromCurrentSongBackground);
StartTransitioningCommand=function(self)
if PREFSMAN:GetPreference("StretchBackgrounds") then
self:SetSize(SCREEN_WIDTH,SCREEN_HEIGHT)
else
self:scale_or_crop_background()
end
self:linear(0.2)
self:diffusealpha(0)
end;
};
-- Pause menu
t[#t+1]= LoadActor(THEME:GetPathG("", "pause_menu"))
return t;
@@ -1,13 +0,0 @@
local t = Def.ActorFrame{};
if not GAMESTATE:IsCourseMode() then return t; end;
t[#t+1] = Def.Sprite {
InitCommand=cmd(Center);
BeforeLoadingNextCourseSongMessageCommand=function(self) self:LoadFromSongBackground( SCREENMAN:GetTopScreen():GetNextCourseSong() ) end;
ChangeCourseSongInMessageCommand=cmd(scale_or_crop_background);
StartCommand=cmd(diffusealpha,0;decelerate,0.5;diffusealpha,1);
FinishCommand=cmd(linear,0.1;glow,Color.Alpha(Color("White"),0.5);decelerate,0.4;glow,Color("Invisible");diffusealpha,0);
};
return t;
@@ -1,50 +0,0 @@
local raveChildren
local bg = Def.ActorFrame{
Def.Quad{
InitCommand=cmd(FullScreen;diffuse,color("0,0,0,0"));
StartTransitioningCommand=cmd(sleep,0.8;linear,3;diffusealpha,1);
};
Def.ActorFrame{
Name="RaveMessages";
InitCommand=function(self)
raveChildren = self:GetChildren()
self:visible(GAMESTATE:GetPlayMode() == 'PlayMode_Rave')
raveChildren.P1Win:visible(false)
raveChildren.P2Win:visible(false)
raveChildren.Draw:visible(false)
end;
OffCommand=function(self)
local p1Win = GAMESTATE:IsWinner(PLAYER_1)
local p2Win = GAMESTATE:IsWinner(PLAYER_2)
if GAMESTATE:IsWinner(PLAYER_1) then
raveChildren.P1Win:visible(true)
elseif GAMESTATE:IsWinner(PLAYER_2) then
raveChildren.P2Win:visible(true)
else
raveChildren.Draw:visible(true)
end
end;
LoadActor(THEME:GetPathG("_rave result","P1"))..{
Name="P1Win";
InitCommand=cmd(Center;cropbottom,1;fadebottom,1);
StartTransitioningCommand=cmd(sleep,1.8;linear,0.5;cropbottom,0;fadebottom,0;sleep,1.75;linear,0.25;diffusealpha,0);
};
LoadActor(THEME:GetPathG("_rave result","P2"))..{
Name="P2Win";
InitCommand=cmd(Center;cropbottom,1;fadebottom,1);
StartTransitioningCommand=cmd(sleep,1.8;linear,0.5;cropbottom,0;fadebottom,0;sleep,1.75;linear,0.25;diffusealpha,0);
};
LoadActor(THEME:GetPathG("_rave result","draw"))..{
Name="Draw";
InitCommand=cmd(Center;cropbottom,1;fadebottom,1);
StartTransitioningCommand=cmd(sleep,1.8;linear,0.5;cropbottom,0;fadebottom,0;sleep,1.75;linear,0.25;diffusealpha,0);
};
};
};
return bg
Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

@@ -1,140 +0,0 @@
--FullCombo base from moonlight by AJ
local pn = ...;
assert(pn);
local t = Def.ActorFrame{};
local pStats = STATSMAN:GetCurStageStats():GetPlayerStageStats(pn);
local function GetPosition(pn)
if Center1Player() then
return SCREEN_CENTER_X
else
return THEME:GetMetric("ScreenGameplay","Player".. ToEnumShortString(pn) .. "MiscX");
end;
end;
-- Reuse screen filter code for width-based explosion
local style = GAMESTATE:GetCurrentStyle()
local cols = style:ColumnsPerPlayer()
local padding = 8 -- 4px on each side
local arrowWidth = 96 -- until noteskin metrics are implemented...
local filterWidth = (arrowWidth * cols) + padding
-- Ripple
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(visible,false);
OffCommand=function(self)
if pStats:FullCombo() then
self:visible(true);
end;
end;
Def.Quad {
InitCommand=function(self)
self:diffusealpha(0):x( GetPosition(pn) ):y(SCREEN_CENTER_Y):blend('add'):zoomto(filterWidth,1)
end;
OffCommand=function(self)
if pStats:FullCombo() then
if pStats:FullComboOfScore('TapNoteScore_W1') == true then
self:diffuse(color("#A0DBF1"))
elseif pStats:FullComboOfScore('TapNoteScore_W2') == true then
self:diffuse(color("#F1E4A2"))
elseif pStats:FullComboOfScore('TapNoteScore_W3') == true then
self:diffuse(color("#ABE39B"))
end
self:diffusealpha(1):decelerate(1.4):zoomto(filterWidth,400):diffusealpha(0):fadetop(1):fadebottom(1);
end;
end;
};
};
-- Milestone ripple
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(visible,false);
OffCommand=function(self)
if pStats:FullCombo() then
self:visible(true);
end;
end;
LoadActor("_splash") .. {
InitCommand=function(self)
self:diffusealpha(0):x( GetPosition(pn) ):y(SCREEN_CENTER_Y):blend('add');
end;
OffCommand=function(self)
if pStats:FullCombo() then
if pStats:FullComboOfScore('TapNoteScore_W1') == true then
self:diffuse(color("#A0DBF1"))
elseif pStats:FullComboOfScore('TapNoteScore_W2') == true then
self:diffuse(color("#F1E4A2"))
elseif pStats:FullComboOfScore('TapNoteScore_W3') == true then
self:diffuse(color("#ABE39B"))
end
self:zoom(0.5):diffusealpha(0.5):decelerate(1):zoom(1):diffusealpha(0)
end;
end;
};
};
--W1
t[#t+1] = LoadActor(THEME:GetPathG("FullCombo", "W1 text")) .. {
InitCommand=cmd(diffusealpha,0;x,GetPosition(pn);y,SCREEN_CENTER_Y);
OffCommand=function(self)
local fct = STATSMAN:GetCurStageStats():GetPlayerStageStats(pn);
if fct:FullComboOfScore('TapNoteScore_W1') == true then
self:glowblink():effectperiod(0.05):effectcolor1(color("1,1,1,0")):effectcolor2(color("1,1,1,0.25"))
self:zoomy(0.75):zoomx(1.4):diffusealpha(0):decelerate(0.4):zoomx(0.75):diffusealpha(1):sleep(0.75):decelerate(0.5):zoom(1.1):diffusealpha(0)
elseif fct:FullComboOfScore('TapNoteScore_W2') == true then
self:visible(false);
elseif fct:FullComboOfScore('TapNoteScore_W3') == true then
self:visible(false);
else
self:visible(false);
end;
end;
};
--W1
t[#t+1] = LoadActor(THEME:GetPathG("FullCombo", "W2 text")) .. {
InitCommand=cmd(diffusealpha,0;x,GetPosition(pn);y,SCREEN_CENTER_Y);
OffCommand=function(self)
local fct = STATSMAN:GetCurStageStats():GetPlayerStageStats(pn);
if fct:FullComboOfScore('TapNoteScore_W1') == true then
self:visible(false);
elseif fct:FullComboOfScore('TapNoteScore_W2') == true then
self:zoomy(0.75):zoomx(1.4):diffusealpha(0):decelerate(0.4):zoomx(0.75):diffusealpha(1):sleep(0.5):decelerate(0.3):zoom(1.1):diffusealpha(0)
elseif fct:FullComboOfScore('TapNoteScore_W3') == true then
self:visible(false);
else
self:visible(false);
end;
end;
};
--W3
t[#t+1] = LoadActor(THEME:GetPathG("FullCombo", "W3 text")) .. {
InitCommand=cmd(diffusealpha,0;x,GetPosition(pn);y,SCREEN_CENTER_Y);
OffCommand=function(self)
local fct = STATSMAN:GetCurStageStats():GetPlayerStageStats(pn);
if fct:FullComboOfScore('TapNoteScore_W1') == true then
self:visible(false);
elseif fct:FullComboOfScore('TapNoteScore_W2') == true then
self:visible(false);
elseif fct:FullComboOfScore('TapNoteScore_W3') == true then
self:zoomy(0.75):zoomx(1.4):diffusealpha(0):decelerate(0.4):zoomx(0.75):diffusealpha(1):sleep(0.5):decelerate(0.3):zoom(1.1):diffusealpha(0)
else
self:visible(false);
end;
end;
};
-- Sound
t[#t+1] = LoadActor("_bolt") .. {
OffCommand=function(self)
local fct = STATSMAN:GetCurStageStats():GetPlayerStageStats(pn);
if fct:FullCombo() then
self:play();
end;
end;
};
return t;
@@ -1,236 +0,0 @@
local t = Def.ActorFrame {};
local function UpdateTime(self)
local c = self:GetChildren();
for pn in ivalues(PlayerNumber) do
local vStats = STATSMAN:GetCurStageStats():GetPlayerStageStats( pn );
local vTime;
local obj = self:GetChild( string.format("RemainingTime" .. PlayerNumberToString(pn) ) );
if vStats and obj then
vTime = vStats:GetLifeRemainingSeconds()
obj:settext( SecondsToMMSSMsMs( vTime ) );
end;
end;
end
local function songMeterScale(val) return scale(val,0,1,-380/2,380/2) end
if GAMESTATE:GetCurrentCourse() then
if GAMESTATE:GetCurrentCourse():GetCourseType() == "CourseType_Survival" then
-- RemainingTime
for pn in ivalues(PlayerNumber) do
local MetricsName = "RemainingTime" .. PlayerNumberToString(pn);
t[#t+1] = LoadActor( THEME:GetPathG( Var "LoadingScreen", "RemainingTime"), pn ) .. {
InitCommand=function(self)
self:player(pn);
self:name(MetricsName);
ActorUtil.LoadAllCommandsAndSetXY(self,Var "LoadingScreen");
end;
};
end
for pn in ivalues(PlayerNumber) do
local MetricsName = "DeltaSeconds" .. PlayerNumberToString(pn);
t[#t+1] = LoadActor( THEME:GetPathG( Var "LoadingScreen", "DeltaSeconds"), pn ) .. {
InitCommand=function(self)
self:player(pn);
self:name(MetricsName);
ActorUtil.LoadAllCommandsAndSetXY(self,Var "LoadingScreen");
end;
};
end
end;
end;
t.InitCommand=cmd(SetUpdateFunction,UpdateTime);
if GAMESTATE:GetPlayMode() ~= 'PlayMode_Rave' then
for ip, pn in ipairs(GAMESTATE:GetEnabledPlayers()) do
if ShowStandardDecoration("LifeMeterBar" .. ToEnumShortString(pn)) then
local life_type = GAMESTATE:GetPlayerState(pn):GetPlayerOptions("ModsLevel_Song"):LifeSetting()
t[#t+1] = LoadActor(THEME:GetPathG(Var "LoadingScreen", "lifebar_" .. ToEnumShortString(life_type)), pn) .. {
InitCommand=function(self)
self:name("LifeMeterBar" .. ToEnumShortString(pn))
ActorUtil.LoadAllCommandsAndSetXY(self,Var "LoadingScreen")
end
}
end
end;
for ip, pn in ipairs(GAMESTATE:GetEnabledPlayers()) do
local life_x_position = string.find(pn, "P1") and SCREEN_LEFT+40 or SCREEN_RIGHT-40
local life_tween = string.find(pn, "P1") and -1 or 1
local second_tween = string.find(pn, "P1") and 1 or -1
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,life_x_position;y,SCREEN_CENTER_Y;rotationz,-90);
OnCommand=cmd(addx,100*life_tween;sleep,0.25;decelerate,0.9;addx,100*second_tween);
OffCommand=cmd(sleep,1;decelerate,0.9;addx,100*life_tween);
LoadActor(THEME:GetPathG("LifeMeter", "bar frame")) .. {
};
Def.ActorFrame {
InitCommand=cmd(x,-207;y,0);
LoadActor("_diffdia") .. {
OnCommand=cmd(playcommand,"Set");
["CurrentSteps"..ToEnumShortString(pn).."ChangedMessageCommand"]=cmd(playcommand,"Set");
SetCommand=function(self)
steps_data = GAMESTATE:GetCurrentSteps(pn)
local song = GAMESTATE:GetCurrentSong();
if song then
if steps_data ~= nil then
local st = steps_data:GetStepsType();
local diff = steps_data:GetDifficulty();
local cd = GetCustomDifficulty(st, diff);
self:diffuse(CustomDifficultyToColor(cd));
end
end
end;
};
LoadFont("StepsDisplay description") .. {
InitCommand=cmd(zoom,0.75;horizalign,center;rotationz,90);
OnCommand=cmd(playcommand,"Set");
["CurrentSteps"..ToEnumShortString(pn).."ChangedMessageCommand"]=cmd(playcommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(playcommand,"Set");
SetCommand=function(self)
steps_data = GAMESTATE:GetCurrentSteps(pn)
local song = GAMESTATE:GetCurrentSong();
if song then
if steps_data ~= nil then
local st = steps_data:GetStepsType();
local diff = steps_data:GetDifficulty();
local cd = GetCustomDifficulty(st, diff);
self:settext(steps_data:GetMeter()):diffuse(color("#000000")):diffusealpha(0.8);
else
self:settext("")
end
else
self:settext("")
end
end
};
};
};
end;
end;
-- Move diamonds on battle
if GAMESTATE:GetPlayMode() == 'PlayMode_Rave' then
-- P1
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X-110;y,SCREEN_BOTTOM-55);
LoadActor("_diffdia") .. {
OnCommand=cmd(playcommand,"Set");
CurrentStepsP1ChangedMessageCommand=cmd(playcommand,"Set");
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1 ~= nil then
local st = stepsP1:GetStepsType();
local diff = stepsP1:GetDifficulty();
local cd = GetCustomDifficulty(st, diff);
self:diffuse(CustomDifficultyToColor(cd));
end
end
end;
};
LoadFont("StepsDisplay description") .. {
InitCommand=cmd(zoom,0.75;horizalign,center);
OnCommand=cmd(playcommand,"Set");
CurrentStepsP1ChangedMessageCommand=cmd(playcommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(playcommand,"Set");
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1 ~= nil then
local st = stepsP1:GetStepsType();
local diff = stepsP1:GetDifficulty();
local cd = GetCustomDifficulty(st, diff);
self:settext(stepsP1:GetMeter()):diffuse(color("#000000")):diffusealpha(0.8);
else
self:settext("")
end
else
self:settext("")
end
end
};
};
-- P2
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X+110;y,SCREEN_BOTTOM-55);
LoadActor("_diffdia") .. {
OnCommand=cmd(playcommand,"Set");
CurrentstepsP2ChangedMessageCommand=cmd(playcommand,"Set");
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP2 ~= nil then
local st = stepsP2:GetStepsType();
local diff = stepsP2:GetDifficulty();
local cd = GetCustomDifficulty(st, diff);
self:diffuse(CustomDifficultyToColor(cd));
end
end
end;
};
LoadFont("StepsDisplay description") .. {
InitCommand=cmd(zoom,0.75;horizalign,center);
OnCommand=cmd(playcommand,"Set");
CurrentstepsP2ChangedMessageCommand=cmd(playcommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(playcommand,"Set");
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP2 ~= nil then
local st = stepsP2:GetStepsType();
local diff = stepsP2:GetDifficulty();
local cd = GetCustomDifficulty(st, diff);
self:settext(stepsP2:GetMeter()):diffuse(color("#000000")):diffusealpha(0.8);
else
self:settext("")
end
else
self:settext("")
end
end
};
};
end;
t[#t+1] = StandardDecorationFromFileOptional("StageDisplay","StageDisplay");
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X+103;y,SCREEN_BOTTOM-25);
OnCommand=cmd(draworder,DrawOrder.Screen;addy,100;sleep,0.5;decelerate,0.7;addy,-100);
OffCommand=cmd(sleep,1;decelerate,0.9;addy,100);
Def.Quad {
InitCommand=cmd(zoomto,264,12);
OnCommand=cmd(diffuse,Color.Black;diffusealpha,0.3;fadeleft,0.05;faderight,0.05);
};
Def.Quad {
InitCommand=cmd(zoomto,2,8);
OnCommand=cmd(x,songMeterScale(0.25);diffuse,PlayerColor(pn);diffusealpha,0.5);
};
Def.Quad {
InitCommand=cmd(zoomto,2,8);
OnCommand=cmd(x,songMeterScale(0.5);diffuse,PlayerColor(pn);diffusealpha,0.5);
};
Def.Quad {
InitCommand=cmd(zoomto,2,8);
OnCommand=cmd(x,songMeterScale(0.75);diffuse,PlayerColor(pn);diffusealpha,0.5);
};
Def.SongMeterDisplay {
StreamWidth=260;
Stream=LoadActor( THEME:GetPathG( 'SongMeterDisplay', 'stream') )..{
InitCommand=cmd(diffuse,Color.White;diffusealpha,0.4;blend,Blend.Add);
};
Tip=LoadActor( THEME:GetPathG( 'SongMeterDisplay', 'tip')) .. {
InitCommand=cmd(visible,false);
};
};
};
for pn in ivalues(GAMESTATE:GetHumanPlayers()) do
t[#t+1] = LoadActor("_fcsplash", pn) .. {
};
end;
return t
@@ -1,4 +0,0 @@
return LoadActor("ready") .. {
InitCommand=cmd(Center;draworder,105);
StartTransitioningCommand=cmd(zoom,1.3;diffusealpha,0;bounceend,0.25;zoom,1;diffusealpha,1;linear,0.15;glow,BoostColor(Color("Orange"),1.75);decelerate,0.3;glow,1,1,1,0;sleep,1-0.45;linear,0.25;diffusealpha,0);
};
Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

@@ -1,68 +0,0 @@
--[[ Screen Filter ]]
local numPlayers = GAMESTATE:GetNumPlayersEnabled()
local center1P = PREFSMAN:GetPreference("Center1Player")
local padding = 8 -- 4px on each side
local arrowWidth = 96 -- until noteskin metrics are implemented...
local filterColor = color("#000000")
local filterAlphas = {
PlayerNumber_P1 = 1,
PlayerNumber_P2 = 1,
Default = 0,
}
local t = Def.ActorFrame{};
local style = GAMESTATE:GetCurrentStyle()
local cols = style:ColumnsPerPlayer()
local styleType = ToEnumShortString(style:GetStyleType())
local filterWidth = (arrowWidth * cols) + padding
local stepsType = style:GetStepsType()
if numPlayers == 1 then
local player = GAMESTATE:GetMasterPlayerNumber()
local pNum = (player == PLAYER_1) and 1 or 2
filterAlphas[player] = tonumber(getenv("ScreenFilterP"..pNum)) or 0;
local pos;
-- [ScreenGameplay] PlayerP#Player*Side(s)X
if center1P then
pos = SCREEN_CENTER_X
elseif stepsType == "StepsType_Dance_Solo" then
pos = SCREEN_CENTER_X
else
local metricName = string.format("PlayerP%i%sX",pNum,styleType)
pos = THEME:GetMetric("ScreenGameplay",metricName)
end
t[#t+1] = Def.Quad{
Name="SinglePlayerFilter";
InitCommand=cmd(x,pos;CenterY;zoomto,filterWidth,SCREEN_HEIGHT;diffusecolor,filterColor;diffusealpha,filterAlphas[player]);
};
else
-- two players... a bit more complex.
if styleType == "TwoPlayersSharedSides" then
-- routine, just use one in the center.
local player = GAMESTATE:GetMasterPlayerNumber()
local pNum = player == PLAYER_1 and 1 or 2
local metricName = "PlayerP".. pNum .."TwoPlayersSharedSidesX"
t[#t+1] = Def.Quad{
Name="RoutineFilter";
InitCommand=cmd(x,THEME:GetMetric("ScreenGameplay",metricName);CenterY;zoomto,filterWidth,SCREEN_HEIGHT;diffusecolor,filterColor;diffusealpha,filterAlphas[player]);
};
else
-- otherwise we need two separate ones. to the pairsmobile!
for i, player in ipairs(PlayerNumber) do
local pNum = (player == PLAYER_1) and 1 or 2
filterAlphas[player] = tonumber(getenv("ScreenFilterP"..pNum)) or 0;
local metricName = string.format("PlayerP%i%sX",pNum,styleType)
local pos = THEME:GetMetric("ScreenGameplay",metricName)
t[#t+1] = Def.Quad{
Name="Player"..pNum.."Filter";
InitCommand=cmd(x,pos;CenterY;zoomto,filterWidth,SCREEN_HEIGHT;diffusecolor,filterColor;diffusealpha,filterAlphas[player]);
};
end
end
end
return t;
@@ -1,3 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = LoadActor("ScreenFilter");
return t
@@ -1,5 +0,0 @@
return Def.ActorFrame {
LoadActor(THEME:GetPathG("common bg", "base")) .. {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT)
};
}
@@ -1,42 +0,0 @@
local t = LoadFallbackB();
local StepsType = ToEnumShortString( GAMEMAN:GetFirstStepsTypeForGame(GAMESTATE:GetCurrentGame()) );
local stString = THEME:GetString("StepsType",StepsType);
local NumColumns = THEME:GetMetric(Var "LoadingScreen", "NumColumns");
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y-220);
Def.Quad {
InitCommand=cmd(zoomto,SCREEN_WIDTH, 56);
OnCommand=function(self)
self:diffuse(ScreenColor(SCREENMAN:GetTopScreen():GetName())):diffusebottomedge(ColorDarkTone(ScreenColor(SCREENMAN:GetTopScreen():GetName()))):diffusealpha(0.9)
end
};
};
for i=1,NumColumns do
local st = THEME:GetMetric(Var "LoadingScreen","ColumnStepsType" .. i);
local dc = THEME:GetMetric(Var "LoadingScreen","ColumnDifficulty" .. i);
local s = GetCustomDifficulty( st, dc );
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X+32 + 84 * (i-1);y,SCREEN_CENTER_Y-220);
LoadActor(THEME:GetPathB("_frame","3x1"),"rounded light", 18) .. {
OnCommand=cmd(diffuse,CustomDifficultyToLightColor(s);diffusealpha,0.9);
};
LoadFont("StepsDisplayListRow description") .. {
InitCommand=cmd(uppercase,true;settext,CustomDifficultyToLocalizedString(s));
OnCommand=cmd(zoom,0.675;maxwidth,80/0.675;diffuse,CustomDifficultyToDarkColor(s));
};
};
end
t[#t+1] = LoadFont("Common Normal") .. {
InitCommand=cmd(settext,stString;x,SCREEN_CENTER_X-220;y,SCREEN_CENTER_Y-220);
OnCommand=cmd(diffusebottomedge,color("0.75,0.75,0.75");shadowlength,2);
};
t.OnCommand=cmd(draworder,105);
return t;
@@ -1,3 +0,0 @@
local t = LoadFallbackB();
t[#t+1] = LoadActor( THEME:GetPathB("_Arcade","decorations") );
return t
@@ -1 +0,0 @@
Fade in
@@ -1 +0,0 @@
ScreenWithMenuElements in
@@ -1 +0,0 @@
ScreenWithMenuElements out
@@ -1 +0,0 @@
ScreenDemonstration overlay
@@ -1 +0,0 @@
ScreenTitleMenu background
@@ -1,6 +0,0 @@
local t = LoadFallbackB();
t[#t+1] = StandardDecorationFromFileOptional("Logo","Logo");
t[#t+1] = LoadActor( THEME:GetPathB("_Arcade","decorations") );
return t;
@@ -1,16 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = LoadActor(THEME:GetPathG("common bg", "base")) .. {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT)
};
-- Overlay
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(Center);
Def.Quad {
InitCommand=cmd(scaletoclipped,SCREEN_WIDTH,SCREEN_HEIGHT);
OnCommand=cmd(diffuse,Color.Black;diffusealpha,0.8);
};
};
--
return t
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1,7 +0,0 @@
return Def.ActorFrame {
OnCommand= function(self) self:queuecommand("Recenter") end,
RecenterCommand= function(self) SCREENMAN:GetTopScreen():xy(0, 0) end,
Def.Quad{
InitCommand=cmd(scaletocover,-SCREEN_WIDTH*2,SCREEN_TOP,SCREEN_WIDTH*2,SCREEN_BOTTOM;diffuse,color("0,0,0,0.5"));
};
};
@@ -1 +0,0 @@
ScreenWithMenuElements in
@@ -1 +0,0 @@
ScreenWithMenuElements out
@@ -1,284 +0,0 @@
local menu_height= 400
local menu_width= 250
local menu_x= {
[PLAYER_1]= _screen.w * .25,
[PLAYER_2]= _screen.w * .75,
}
local menus= {}
for i, pn in ipairs(GAMESTATE:GetHumanPlayers()) do
menus[pn]= setmetatable({}, nesty_menu_stack_mt)
end
local explanations= {}
local ready_indicators= {}
local turn_chart_mods= {
nesty_options.bool_player_mod_val("Mirror"),
nesty_options.bool_player_mod_val("Backwards"),
nesty_options.bool_player_mod_val("Left"),
nesty_options.bool_player_mod_val("Right"),
nesty_options.bool_player_mod_val("Shuffle"),
nesty_options.bool_player_mod_val("SoftShuffle"),
nesty_options.bool_player_mod_val("SuperShuffle"),
}
local removal_chart_mods= {
nesty_options.bool_player_mod_val("NoHolds"),
nesty_options.bool_player_mod_val("NoRolls"),
nesty_options.bool_player_mod_val("NoMines"),
nesty_options.bool_player_mod_val("HoldRolls"),
nesty_options.bool_player_mod_val("NoJumps"),
nesty_options.bool_player_mod_val("NoHands"),
nesty_options.bool_player_mod_val("NoLifts"),
nesty_options.bool_player_mod_val("NoFakes"),
nesty_options.bool_player_mod_val("NoQuads"),
nesty_options.bool_player_mod_val("NoStretch"),
}
local insertion_chart_mods= {
nesty_options.bool_player_mod_val("Little"),
nesty_options.bool_player_mod_val("Wide"),
nesty_options.bool_player_mod_val("Big"),
nesty_options.bool_player_mod_val("Quick"),
nesty_options.bool_player_mod_val("BMRize"),
nesty_options.bool_player_mod_val("Skippy"),
nesty_options.bool_player_mod_val("Mines"),
nesty_options.bool_player_mod_val("Echo"),
nesty_options.bool_player_mod_val("Stomp"),
nesty_options.bool_player_mod_val("Planted"),
nesty_options.bool_player_mod_val("Floored"),
nesty_options.bool_player_mod_val("Twister"),
}
local chart_mods= {
nesty_options.submenu("turn_chart_mods", turn_chart_mods),
nesty_options.submenu("removal_chart_mods", removal_chart_mods),
nesty_options.submenu("insertion_chart_mods", insertion_chart_mods),
}
local gameplay_options= {
nesty_options.bool_config_val(player_config, "ComboUnderField"),
nesty_options.bool_config_val(player_config, "FlashyCombo"),
nesty_options.bool_config_val(player_config, "GameplayShowStepsDisplay"),
nesty_options.bool_config_val(player_config, "GameplayShowScore"),
nesty_options.bool_config_val(player_config, "JudgmentUnderField"),
nesty_options.bool_config_val(player_config, "Protiming"),
}
-- The time life bar doesn't work sensibly outside the survival courses, so
-- keep it out of the menu.
local life_type_enum= {"LifeType_Bar", "LifeType_Battery"}
local life_options= {
nesty_options.enum_player_mod_single_val("bar_type", "LifeType_Bar", "LifeSetting"),
nesty_options.enum_player_mod_single_val("battery_type", "LifeType_Battery", "LifeSetting"),
nesty_options.enum_player_mod_single_val("normal_drain", "DrainType_Normal", "DrainSetting"),
nesty_options.enum_player_mod_single_val("no_recover", "DrainType_NoRecover", "DrainSetting"),
nesty_options.enum_player_mod_single_val("sudden_death", "DrainType_SuddenDeath", "DrainSetting"),
nesty_options.enum_player_mod_single_val("fail_immediate", "FailType_Immediate", "FailSetting"),
nesty_options.enum_player_mod_single_val("fail_immediate_continue", "FailType_ImmediateContinue", "FailSetting"),
nesty_options.enum_player_mod_single_val("fail_end_of_song", "FailType_EndOfSong", "FailSetting"),
nesty_options.enum_player_mod_single_val("fail_off", "FailType_Off", "FailSetting"),
nesty_options.float_player_mod_val_new("BatteryLives", 1, 2, 1, 10, 4),
}
-- I suppose now would be a good time to mention that, since the float menu code ...thingy doesn't rely on powers of 10 anymore,
-- the values passed in will be different.
local base_options= {
notefield_prefs_speed_type_menu(),
notefield_prefs_speed_mod_menu(),
--Turns out the music rate can't handle values higher than 3!
nesty_options.float_song_mod_val_new("MusicRate", 0.1, 1, .1, 3, 1),
nesty_options.float_song_mod_toggle_val("Haste", 1, 0),
notefield_perspective_menu(),
nesty_options.float_config_toggle_val(notefield_prefs_config, "reverse", -1, 1),
nesty_options.float_config_val_new(notefield_prefs_config, "zoom", 0.1, 1),
nesty_options.submenu("chart_mods", chart_mods),
{name= "noteskin", translatable= true, menu= nesty_option_menus.noteskins},
{name= "shown_noteskins", translatable= true, menu= nesty_option_menus.shown_noteskins, args= {}},
nesty_options.bool_config_val(notefield_prefs_config, "hidden"),
nesty_options.bool_config_val(notefield_prefs_config, "sudden"),
advanced_notefield_prefs_menu(),
nesty_options.submenu("gameplay_options", gameplay_options),
nesty_options.submenu("life_options", life_options),
nesty_options.bool_song_mod_val("AssistClap"),
nesty_options.bool_song_mod_val("AssistMetronome"),
nesty_options.bool_song_mod_val("StaticBackground"),
nesty_options.bool_song_mod_val("RandomBGOnly"),
nesty_options.float_config_val_new(player_config, "ScreenFilter", 0.1, 0.5, 0, 1),
get_notefield_mods_toggle_menu(true, true),
{name= "reload_noteskins", translatable= true, type= "action",
execute= function() NOTESKIN:reload_skins() end},
}
local player_ready= {}
local function exit_if_both_ready()
for i, pn in ipairs(GAMESTATE:GetHumanPlayers()) do
if not player_ready[pn] then return end
end
SCREENMAN:GetTopScreen():StartTransitioningScreen("SM_GoToNextScreen")
end
local prev_explanation= {}
local function update_explanation(pn)
local cursor_item= menus[pn]:get_cursor_item()
if cursor_item then
local new_expl= cursor_item.name or cursor_item.text
local expl_com= "change_explanation"
if cursor_item.explanation then
new_expl= cursor_item.explanation
expl_com= "translated_explanation"
end
if new_expl ~= prev_explanation[pn] then
prev_explanation[pn]= new_expl
explanations[pn]:playcommand(expl_com, {text= new_expl})
end
end
end
local function input(event)
local pn= event.PlayerNumber
if not pn then return end
if not menus[pn] then return end
if menu_stack_generic_input(menus, event)
and event.type == "InputEventType_FirstPress" then
if event.GameButton == "Back" then
SCREENMAN:GetTopScreen():StartTransitioningScreen("SM_GoToPrevScreen")
else
player_ready[pn]= true
ready_indicators[pn]:playcommand("show_ready")
exit_if_both_ready()
end
else
if player_ready[pn] and not menus[pn]:can_exit_screen() then
player_ready[pn]= false
ready_indicators[pn]:playcommand("hide_ready")
end
end
update_explanation(pn)
end
local frame= Def.ActorFrame{
OnCommand= function(self)
SCREENMAN:GetTopScreen():AddInputCallback(input)
for pn, menu in pairs(menus) do
menu:push_menu_stack(nesty_option_menus.menu, base_options, "play_song")
menu:update_cursor_pos()
update_explanation(pn)
end
end,
}
local item_params= {
text_commands= {
Font= "Common Condensed", OnCommand= function(self)
self:diffuse(color("#3D1D23")):diffusealpha(0):decelerate(0.2):diffusealpha(1)
end,
OffCommand=function(self)
self:smooth(0.3):diffusealpha(0)
end,
},
text_width= .7,
value_text_commands= {
Font= "Common Condensed", OnCommand= function(self)
self:diffuse(color("#AC214A")):diffusealpha(0):decelerate(0.2):diffusealpha(1)
end,
OffCommand=function(self)
self:smooth(0.3):diffusealpha(0)
end,
},
value_image_commands= {
OnCommand= function(self)
self:diffusealpha(0):smooth(0.3):diffusealpha(1)
end,
OffCommand=function(self)
self:smooth(0.3):diffusealpha(0)
end,
},
value_width= .25,
type_images= {
bool= THEME:GetPathG("", "menu_icons/bool"),
choice= THEME:GetPathG("", "menu_icons/bool"),
menu= THEME:GetPathG("", "menu_icons/menu"),
},
}
for pn, menu in pairs(menus) do
frame[#frame+1]= LoadActor(
THEME:GetPathG("ScreenOptions", "halfpage")) .. {
InitCommand= function(self)
self:xy(menu_x[pn], 360)
end;
OnCommand=function(self)
self:diffusealpha(0):zoomx(0.8):decelerate(0.3):diffusealpha(1):zoomx(1)
end;
OffCommand=function(self)
self:decelerate(0.3):diffusealpha(0)
end;
}
frame[#frame+1]= menu:create_actors{
x= menu_x[pn], y= 120, width= menu_width, height= menu_height,
translation_section= "notefield_options",
num_displays= 1, pn= pn, el_height= 36,
menu_sounds= {
pop= THEME:GetPathS("Common", "Cancel"),
push= THEME:GetPathS("_common", "row"),
act= THEME:GetPathS("Common", "start"),
move= THEME:GetPathS("Common", "value"),
move_up= THEME:GetPathS("Common", "value"),
move_down= THEME:GetPathS("Common", "value"),
inc= THEME:GetPathS("_switch", "up"),
dec= THEME:GetPathS("_switch", "down"),
},
display_params= {
el_zoom= 0.8, item_params= item_params, item_mt= nesty_items.value, heading_height = 48,
on= function(self)
self:diffusealpha(0):decelerate(0.2):diffusealpha(1)
end,
off= function(self)
self:decelerate(0.2):diffusealpha(0)
end,
},
}
frame[#frame+1]= Def.BitmapText{
Font= "Common Normal", InitCommand= function(self)
explanations[pn]= self
self:xy(menu_x[pn] - (menu_width / 2), _screen.cy+154)
:diffuse(ColorDarkTone((PlayerColor(pn)))):horizalign(left):vertalign(top)
:wrapwidthpixels(menu_width / .8):zoom(.75)
:horizalign(left)
end,
change_explanationCommand= function(self, param)
local text= ""
if THEME:HasString("notefield_explanations", param.text) then
text= THEME:GetString("notefield_explanations", param.text)
end
self:playcommand("translated_explanation", {text= text})
end,
translated_explanationCommand= function(self, param)
self:stoptweening():settext(param.text):cropright(1):linear(.5):cropright(0)
end,
}
frame[#frame+1]= Def.BitmapText{
Font= "Common Condensed", Text= "READY!", InitCommand= function(self)
ready_indicators[pn]= self
self:xy(menu_x[pn], 146):zoom(1.5):diffuse(Color.Green):strokecolor(color("#2E540F")):diffusealpha(0)
end,
show_readyCommand= function(self)
self:stoptweening():decelerate(.5):diffusealpha(1)
end,
hide_readyCommand= function(self)
self:stoptweening():accelerate(.5):diffusealpha(0)
end,
}
local metrics_name = "PlayerNameplate" .. ToEnumShortString(pn)
frame[#frame+1] = LoadActor(
THEME:GetPathG("ScreenPlayerOptions", "PlayerNameplate"), pn) .. {
InitCommand=function(self)
self:name(metrics_name)
ActorUtil.LoadAllCommandsAndSetXY(self,"ScreenPlayerOptions")
self:x(menu_x[pn])
end
}
end
return frame
@@ -1 +0,0 @@
ScreenOptionsService In
@@ -1 +0,0 @@
ScreenOptionsService Out
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1,15 +0,0 @@
local num_players = GAMESTATE:GetHumanPlayers();
local t = LoadFallbackB();
for i=1,#num_players do
local metrics_name = "PlayerNameplate" .. ToEnumShortString(num_players[i])
t[#t+1] = LoadActor( THEME:GetPathG(Var "LoadingScreen", "PlayerNameplate"), num_players[i] ) .. {
InitCommand=function(self)
self:name(metrics_name);
ActorUtil.LoadAllCommandsAndSetXY(self,Var "LoadingScreen");
end
}
end
return t;
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

@@ -1,27 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = Def.ActorFrame {
Def.Sprite {
Name="animation",
Texture="LoadScreen diamond 5x2.png",
InitCommand=function(self)
self:SetAllStateDelays(0.1):diffusealpha(1):diffuse(color("#981F41")):Center()
end,
OnCommand=function(self)
self:zoom(0):decelerate(0.25):zoom(0.5)
end;
OffCommand=function(self)
self:decelerate(0.25):zoom(0)
end;
};
};
t[#t+1] = Def.Actor {
BeginCommand=function(self)
if SCREENMAN:GetTopScreen():HaveProfileToLoad() then self:sleep(1); end;
self:queuecommand("Load");
end;
LoadCommand=function() SCREENMAN:GetTopScreen():Continue(); end;
};
return t;
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

@@ -1,27 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = Def.ActorFrame {
Def.Sprite {
Name="animation",
Texture="LoadScreen diamond 5x2.png",
InitCommand=function(self)
self:SetAllStateDelays(0.1):diffusealpha(1):diffuse(color("#981F41")):Center()
end,
OnCommand=function(self)
self:zoom(0):decelerate(0.25):zoom(0.5)
end;
OffCommand=function(self)
self:decelerate(0.25):zoom(0)
end;
};
};
t[#t+1] = Def.Actor {
BeginCommand=function(self)
if SCREENMAN:GetTopScreen():HaveProfileToSave() then self:sleep(1); end;
self:queuecommand("Load");
end;
LoadCommand=function() SCREENMAN:GetTopScreen():Continue(); end;
};
return t;
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1,9 +0,0 @@
local t = Def.ActorFrame {};
t[#t+1] = Def.Quad{
InitCommand=cmd(scaletocover,-SCREEN_WIDTH*2,SCREEN_TOP,SCREEN_WIDTH*2,SCREEN_BOTTOM;diffuse,color("0,0,0,0.5"));
OnCommand=cmd(diffusealpha,0;smooth,0.2;diffusealpha,0.5;);
OffCommand=cmd(smooth,0.2;diffusealpha,0;);
};
return t
Binary file not shown.

Before

Width:  |  Height:  |  Size: 1012 B

@@ -1,495 +0,0 @@
local curStage = GAMESTATE:GetCurrentStage();
local curStageIndex = GAMESTATE:GetCurrentStageIndex();
local t = LoadFallbackB();
local function PercentScore(pn)
local t = LoadFont("_overpass Score")..{
InitCommand=cmd(zoom,1;diffuse,Color("Black");diffusealpha,0.75);
BeginCommand=cmd(playcommand,"Set");
SetCommand=function(self)
local SongOrCourse, StepsOrTrail;
if GAMESTATE:IsCourseMode() then
SongOrCourse = GAMESTATE:GetCurrentCourse();
StepsOrTrail = GAMESTATE:GetCurrentTrail(pn);
else
SongOrCourse = GAMESTATE:GetCurrentSong();
StepsOrTrail = GAMESTATE:GetCurrentSteps(pn);
end;
local profile, scorelist;
local text = "";
if SongOrCourse and StepsOrTrail then
local st = StepsOrTrail:GetStepsType();
local diff = StepsOrTrail:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
if PROFILEMAN:IsPersistentProfile(pn) then
-- player profile
profile = PROFILEMAN:GetProfile(pn);
else
-- machine profile
profile = PROFILEMAN:GetMachineProfile();
end;
scorelist = profile:GetHighScoreList(SongOrCourse,StepsOrTrail);
assert(scorelist)
local scores = scorelist:GetHighScores();
local topscore = scores[1];
if topscore then
text = string.format("%.2f%%", topscore:GetPercentDP()*100.0);
-- 100% hack
if text == "100.00%" then
text = "100%";
end;
else
text = string.format("%.2f%%", 0);
end;
else
text = "";
end;
self:settext(text);
end;
CurrentSongChangedMessageCommand=cmd(playcommand,"Set");
CurrentCourseChangedMessageCommand=cmd(playcommand,"Set");
};
if pn == PLAYER_1 then
t.CurrentStepsP1ChangedMessageCommand=cmd(playcommand,"Set");
t.CurrentTrailP1ChangedMessageCommand=cmd(playcommand,"Set");
else
t.CurrentStepsP2ChangedMessageCommand=cmd(playcommand,"Set");
t.CurrentTrailP2ChangedMessageCommand=cmd(playcommand,"Set");
end
return t;
end
-- Banner underlay
-- t[#t+1] = Def.ActorFrame {
-- InitCommand=cmd(x,SCREEN_CENTER_X-230;draworder,125);
-- OffCommand=cmd(smooth,0.2;diffusealpha,0);
-- Def.Quad {
-- InitCommand=cmd(zoomto,468,196;diffuse,color("#fce1a1");diffusealpha,0.4;vertalign,top;y,SCREEN_CENTER_Y-230);
-- };
-- };
-- Banner
t[#t+1] = LoadActor(THEME:GetPathG("ScreenSelectMusic", "banner overlay")) .. {
InitCommand=cmd(zoom,1;x,SCREEN_CENTER_X-228;y,SCREEN_CENTER_Y-165-20;draworder,47);
OnCommand=function(self)
self:diffuse(StageToColor(curStage));
self:zoomy(0):decelerate(0.3):zoomy(1);
end;
OffCommand=cmd(decelerate,0.15;zoomx,0);
};
-- Genre/Artist data
t[#t+1] = LoadActor(THEME:GetPathG("ScreenSelectMusic", "info pane")) .. {
InitCommand=cmd(horizalign,center;x,SCREEN_CENTER_X-228;y,SCREEN_CENTER_Y-75-6;zoom,1);
OnCommand=function(self)
self:diffuse(ColorMidTone(StageToColor(curStage)));
self:zoomx(0):diffusealpha(0):decelerate(0.3):zoomx(1):diffusealpha(1);
end;
OffCommand=function(self)
self:sleep(0.3):decelerate(0.15):zoomx(0):diffusealpha(0);
end;
};
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X-330+6-138;draworder,126);
OnCommand=cmd(diffusealpha,0;smooth,0.3;diffusealpha,1);
OffCommand=cmd(smooth,0.3;diffusealpha,0);
-- Length
StandardDecorationFromFileOptional("SongTime","SongTime") .. {
SetCommand=function(self)
local curSelection = nil;
local length = 0.0;
if GAMESTATE:IsCourseMode() then
curSelection = GAMESTATE:GetCurrentCourse();
self:queuecommand("Reset");
if curSelection then
local trail = GAMESTATE:GetCurrentTrail(GAMESTATE:GetMasterPlayerNumber());
if trail then
length = TrailUtil.GetTotalSeconds(trail);
else
length = 0.0;
end;
else
length = 0.0;
end;
else
curSelection = GAMESTATE:GetCurrentSong();
self:queuecommand("Reset");
if curSelection then
length = curSelection:MusicLengthSeconds();
if curSelection:IsLong() then
self:queuecommand("Long");
elseif curSelection:IsMarathon() then
self:queuecommand("Marathon");
else
self:queuecommand("Reset");
end
else
length = 0.0;
self:queuecommand("Reset");
end;
end;
self:settext( SecondsToMSS(length) );
end;
CurrentSongChangedMessageCommand=cmd(queuecommand,"Set");
CurrentCourseChangedMessageCommand=cmd(queuecommand,"Set");
CurrentTrailP1ChangedMessageCommand=cmd(queuecommand,"Set");
CurrentTrailP2ChangedMessageCommand=cmd(queuecommand,"Set");
};
};
-- Course count and type
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X-200;draworder,126);
OnCommand=cmd(diffusealpha,0;smooth,0.3;diffusealpha,1);
OffCommand=cmd(smooth,0.2;diffusealpha,0);
LoadFont("Common Condensed") .. {
InitCommand=cmd(horizalign,right;zoom,1.0;y,SCREEN_CENTER_Y-78+2-6;maxwidth,180;diffuse,color("#DFE2E9");visible,GAMESTATE:IsCourseMode());
CurrentCourseChangedMessageCommand=cmd(queuecommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local course = GAMESTATE:GetCurrentCourse();
if course then
self:settext(course:GetEstimatedNumStages() .. " songs");
self:queuecommand("Refresh");
else
self:settext("");
self:queuecommand("Refresh");
end
end;
};
};
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X+5;draworder,126);
OnCommand=cmd(diffusealpha,0;smooth,0.3;diffusealpha,1);
OffCommand=cmd(smooth,0.2;diffusealpha,0);
LoadFont("Common Condensed") .. {
InitCommand=cmd(horizalign,right;zoom,1.0;y,SCREEN_CENTER_Y-76-6;maxwidth,180;diffuse,color("#DFE2E9");visible,GAMESTATE:IsCourseMode());
CurrentCourseChangedMessageCommand=cmd(queuecommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local course = GAMESTATE:GetCurrentCourse();
if course then
self:settext(CourseTypeToLocalizedString(course:GetCourseType()));
self:queuecommand("Refresh");
else
self:settext("");
self:queuecommand("Refresh");
end
end;
};
};
t[#t+1] = StandardDecorationFromFileOptional("CourseContentsList","CourseContentsList");
if not GAMESTATE:IsCourseMode() then
-- P1 Difficulty Pane
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(visible,GAMESTATE:IsHumanPlayer(PLAYER_1);horizalign,center;x,SCREEN_CENTER_X-210-32;y,SCREEN_CENTER_Y+230+10);
OnCommand=cmd(zoomy,0.8;diffusealpha,0;smooth,0.4;diffusealpha,1;zoomy,1);
PlayerJoinedMessageCommand=function(self,param)
if param.Player == PLAYER_1 then
(cmd(visible,true;diffusealpha,0;linear,0.3;diffusealpha,1))(self);
end;
end;
OffCommand=cmd(decelerate,0.3;diffusealpha,0);
LoadActor(THEME:GetPathG("ScreenSelectMusic", "pane background")) .. {
CurrentStepsP1ChangedMessageCommand=cmd(queuecommand,"Set");
PlayerJoinedMessageCommand=cmd(queuecommand,"Set";diffusealpha,0;decelerate,0.3;diffusealpha,1);
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1 ~= nil then
local st = stepsP1:GetStepsType();
local diff = stepsP1:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
self:finishtweening():linear(0.2):diffuse(ColorLightTone(CustomDifficultyToColor(cd)));
else
self:diffuse(color("#666666"));
end
else
self:diffuse(color("#666666"));
end
end
};
LoadFont("StepsDisplay meter") .. {
InitCommand=cmd(zoom,1.25;diffuse,color("#000000");addx,-143;addy,13);
OnCommand=cmd(diffusealpha,0;smooth,0.2;diffusealpha,0.75);
OffCommand=cmd(linear,0.3;diffusealpha,0);
CurrentStepsP1ChangedMessageCommand=cmd(queuecommand,"Set");
PlayerJoinedMessageCommand=cmd(queuecommand,"Set";diffusealpha,0;linear,0.3;diffusealpha,0.75);
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1 ~= nil then
local st = stepsP1:GetStepsType();
local diff = stepsP1:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
self:settext(stepsP1:GetMeter())
else
self:settext("")
end
else
self:settext("")
end
end
};
LoadFont("Common Italic Condensed") .. {
InitCommand=cmd(uppercase,true;zoom,1;addy,-40;addx,-143;diffuse,color("#000000");maxwidth,115);
OnCommand=cmd(diffusealpha,0;smooth,0.2;diffusealpha,0.75);
OffCommand=cmd(linear,0.3;diffusealpha,0);
CurrentStepsP1ChangedMessageCommand=cmd(queuecommand,"Set");
PlayerJoinedMessageCommand=cmd(queuecommand,"Set";diffusealpha,0;linear,0.3;diffusealpha,0.75);
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1 ~= nil then
local st = stepsP1:GetStepsType();
local diff = stepsP1:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
self:settext(THEME:GetString("CustomDifficulty",ToEnumShortString(diff)));
else
self:settext("")
end
else
self:settext("")
end
end
};
LoadFont("Common Normal") .. {
InitCommand=cmd(uppercase,true;zoom,0.75;addy,-20;addx,-143;diffuse,color("#000000");maxwidth,130);
OnCommand=cmd(diffusealpha,0;smooth,0.2;diffusealpha,0.75);
OffCommand=cmd(linear,0.3;diffusealpha,0);
CurrentStepsP1ChangedMessageCommand=cmd(queuecommand,"Set");
PlayerJoinedMessageCommand=cmd(queuecommand,"Set";diffusealpha,0;linear,0.3;diffusealpha,0.75);
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1 ~= nil then
local st = stepsP1:GetStepsType();
local diff = stepsP1:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
self:settext(THEME:GetString("StepsType",ToEnumShortString(st)));
else
self:settext("")
end
else
self:settext("")
end
end
};
};
-- P2 Difficulty Pane
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(visible,GAMESTATE:IsHumanPlayer(PLAYER_2);horizalign,center;x,SCREEN_CENTER_X+210+32;y,SCREEN_CENTER_Y+230+10);
OnCommand=cmd(zoomy,0.8;diffusealpha,0;smooth,0.4;diffusealpha,1;zoomy,1);
PlayerJoinedMessageCommand=function(self,param)
if param.Player == PLAYER_2 then
(cmd(visible,true;diffusealpha,0;linear,0.3;diffusealpha,1))(self);
end;
end;
OffCommand=cmd(decelerate,0.3;diffusealpha,0);
LoadActor(THEME:GetPathG("ScreenSelectMusic", "pane background")) .. {
InitCommand=cmd(zoomx,-1);
CurrentStepsP2ChangedMessageCommand=cmd(queuecommand,"Set");
PlayerJoinedMessageCommand=cmd(queuecommand,"Set";diffusealpha,0;decelerate,0.3;diffusealpha,1);
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP2 ~= nil then
local st = stepsP2:GetStepsType();
local diff = stepsP2:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
self:finishtweening():linear(0.2):diffuse(ColorLightTone(CustomDifficultyToColor(cd)));
else
self:diffuse(color("#666666"));
end
else
self:diffuse(color("#666666"));
end
end
};
LoadFont("StepsDisplay meter") .. {
InitCommand=cmd(zoom,1.25;diffuse,color("#000000");addx,143;addy,13);
OnCommand=cmd(diffusealpha,0;smooth,0.2;diffusealpha,0.75);
OffCommand=cmd(linear,0.3;diffusealpha,0);
CurrentStepsP2ChangedMessageCommand=cmd(queuecommand,"Set");
PlayerJoinedMessageCommand=cmd(queuecommand,"Set";diffusealpha,0;linear,0.3;diffusealpha,0.75);
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP2 ~= nil then
local st = stepsP2:GetStepsType();
local diff = stepsP2:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
self:settext(stepsP2:GetMeter())
else
self:settext("")
end
else
self:settext("")
end
end
};
LoadFont("Common Italic Condensed") .. {
InitCommand=cmd(uppercase,true;zoom,1;addy,-40;addx,143;diffuse,color("#000000");maxwidth,115);
OnCommand=cmd(diffusealpha,0;smooth,0.2;diffusealpha,0.75);
OffCommand=cmd(linear,0.3;diffusealpha,0);
CurrentStepsP2ChangedMessageCommand=cmd(queuecommand,"Set");
PlayerJoinedMessageCommand=cmd(queuecommand,"Set";diffusealpha,0;linear,0.3;diffusealpha,0.75);
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP2 ~= nil then
local st = stepsP2:GetStepsType();
local diff = stepsP2:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
self:settext(THEME:GetString("CustomDifficulty",ToEnumShortString(diff)));
else
self:settext("")
end
else
self:settext("")
end
end
};
LoadFont("Common Normal") .. {
InitCommand=cmd(uppercase,true;zoom,0.75;addy,-20;addx,143;diffuse,color("#000000");maxwidth,130);
OnCommand=cmd(diffusealpha,0;smooth,0.2;diffusealpha,0.75);
OffCommand=cmd(linear,0.3;diffusealpha,0);
CurrentStepsP2ChangedMessageCommand=cmd(queuecommand,"Set");
PlayerJoinedMessageCommand=cmd(queuecommand,"Set";diffusealpha,0;linear,0.3;diffusealpha,0.75);
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP2 ~= nil then
local st = stepsP2:GetStepsType();
local diff = stepsP2:GetDifficulty();
local courseType = GAMESTATE:IsCourseMode() and SongOrCourse:GetCourseType() or nil;
local cd = GetCustomDifficulty(st, diff, courseType);
self:settext(THEME:GetString("StepsType",ToEnumShortString(st)));
else
self:settext("")
end
else
self:settext("")
end
end
};
};
t[#t+1] = StandardDecorationFromFileOptional("PaneDisplayTextP1","PaneDisplayTextP1");
t[#t+1] = StandardDecorationFromFileOptional("PaneDisplayTextP2","PaneDisplayTextP2");
t[#t+1] = StandardDecorationFromTable("PercentScore"..ToEnumShortString(PLAYER_1), PercentScore(PLAYER_1));
t[#t+1] = StandardDecorationFromTable("PercentScore"..ToEnumShortString(PLAYER_2), PercentScore(PLAYER_2));
end;
if not GAMESTATE:IsCourseMode() then
-- CD title
local function CDTitleUpdate(self)
local song = GAMESTATE:GetCurrentSong();
local cdtitle = self:GetChild("CDTitle");
local height = cdtitle:GetHeight();
if song then
if song:HasCDTitle() then
cdtitle:visible(true);
cdtitle:Load(song:GetCDTitlePath());
else
cdtitle:visible(false);
end;
else
cdtitle:visible(false);
end;
self:zoom(scale(height,32,240,1,32/240))
end;
t[#t+1] = Def.ActorFrame {
OnCommand=cmd(draworder,49;x,SCREEN_CENTER_X-420;y,SCREEN_CENTER_Y-147;diffusealpha,0;decelerate,0.25;diffusealpha,1;SetUpdateFunction,CDTitleUpdate);
OffCommand=cmd(decelerate,0.3;diffusealpha,0;);
Def.Sprite {
Name="CDTitle";
OnCommand=cmd(draworder,49;zoom,0.75;diffusealpha,1;zoom,0;bounceend,0.35;zoom,0.75);
BackCullCommand=cmd(diffuse,color("0.5,0.5,0.5,1"));
OffCommand=cmd(decelerate,0.3;diffusealpha,0;);
};
};
end;
-- BPMDisplay
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(draworder,126;visible,not GAMESTATE:IsCourseMode());
OnCommand=cmd(diffusealpha,0;smooth,0.3;diffusealpha,1);
OffCommand=cmd(linear,0.3;diffusealpha,0);
LoadFont("Common Condensed") .. {
InitCommand=cmd(horizalign,right;x,SCREEN_CENTER_X-198+69-66;y,SCREEN_CENTER_Y-76-6;diffuse,color("#512232");horizalign,right;visible,not GAMESTATE:IsCourseMode());
OnCommand=cmd(queuecommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
self:settext("BPM"):diffuse(ColorLightTone(StageToColor(curStage)));
end;
};
StandardDecorationFromFileOptional("BPMDisplay","BPMDisplay");
};
t[#t+1] = StandardDecorationFromFileOptional("DifficultyList","DifficultyList");
t[#t+1] = StandardDecorationFromFileOptional("SongOptions","SongOptionsText") .. {
ShowPressStartForOptionsCommand=THEME:GetMetric(Var "LoadingScreen","SongOptionsShowCommand");
ShowEnteringOptionsCommand=THEME:GetMetric(Var "LoadingScreen","SongOptionsEnterCommand");
HidePressStartForOptionsCommand=THEME:GetMetric(Var "LoadingScreen","SongOptionsHideCommand");
};
t[#t+1] = Def.ActorFrame{
Def.Quad{
InitCommand=cmd(draworder,160;FullScreen;diffuse,color("0,0,0,1");diffusealpha,0);
ShowPressStartForOptionsCommand=cmd(sleep,0.2;decelerate,0.5;diffusealpha,1);
};
};
t[#t+1] = StandardDecorationFromFileOptional("AlternateHelpDisplay","AlternateHelpDisplay");
t[#t+1] = Def.ActorFrame {
OffCommand=cmd(sleep,0.1;linear,0.2;diffusealpha,0);
InitCommand=cmd(x,SCREEN_CENTER_X-84;visible,not GAMESTATE:IsCourseMode());
StandardDecorationFromFileOptional("StageDisplay","StageDisplay") .. {
InitCommand=cmd(zoom,1);
};
};
return t;
@@ -1,6 +0,0 @@
local transition_params = {
color = color("#882D47"),
transition_type = "in"
}
return LoadActor(THEME:GetPathB("", "_transition"), transition_params)
@@ -1 +0,0 @@
_blank
@@ -1,45 +0,0 @@
local t = Def.ActorFrame {};
-- Sort order
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_RIGHT-290;y,SCREEN_TOP+49);
OffCommand=cmd(linear,0.3;diffusealpha,0);
LoadActor(THEME:GetPathG("", "_sortFrame")) .. {
InitCommand=cmd(diffusealpha,0.9;zoom,1.5);
OnCommand=function(self)
self:diffuse(ColorMidTone(ScreenColor(SCREENMAN:GetTopScreen():GetName())));
end
};
LoadFont("Common Condensed") .. {
InitCommand=cmd(zoom,1;diffuse,color("#FFFFFF");diffusealpha,0.85;horizalign,left;addx,-115);
OnCommand=cmd(queuecommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
self:settext("SORT:");
self:queuecommand("Refresh");
end;
};
LoadFont("Common Condensed") .. {
InitCommand=cmd(zoom,1;maxwidth,SCREEN_WIDTH;addx,115;diffuse,color("#FFFFFF");uppercase,true;horizalign,right;maxwidth,157);
OnCommand=cmd(queuecommand,"Set");
SortOrderChangedMessageCommand=cmd(queuecommand,"Set");
ChangedLanguageDisplayMessageCommand=cmd(queuecommand,"Set");
SetCommand=function(self)
local sortorder = GAMESTATE:GetSortOrder();
if sortorder then
self:finishtweening();
self:smooth(0.4);
self:diffusealpha(0);
self:settext(SortOrderToLocalizedString(sortorder));
self:queuecommand("Refresh"):stoptweening():diffusealpha(0):smooth(0.3):diffusealpha(1)
else
self:settext("");
self:queuecommand("Refresh");
end
end;
};
};
return t
@@ -1 +0,0 @@
_blank
@@ -1,6 +0,0 @@
local transition_params = {
color = color("#882D47"),
transition_type = "out"
}
return LoadActor(THEME:GetPathB("", "_transition"), transition_params)
@@ -1,6 +0,0 @@
local transition_params = {
color = color("#000000"),
transition_type = "out"
}
return LoadActor(THEME:GetPathB("", "_transition"), transition_params)
@@ -1,283 +0,0 @@
function GetLocalProfiles()
local t = {};
function GetSongsPlayedString(numSongs)
return numSongs == 1 and Screen.String("SingularSongPlayed") or Screen.String("SeveralSongsPlayed")
end
for p = 0,PROFILEMAN:GetNumLocalProfiles()-1 do
local profile=PROFILEMAN:GetLocalProfileFromIndex(p);
local ProfileCard = Def.ActorFrame {
--[[ Def.Quad {
InitCommand=cmd(zoomto,200,1;y,40/2);
OnCommand=cmd(diffuse,Color('Outline'));
}; --]]
LoadFont("Common Fallback") .. {
Text=profile:GetDisplayName();
InitCommand=cmd(shadowlength,1;y,-12;zoom,1;strokecolor,color("#000000");ztest,true);
};
LoadFont("Common Condensed") .. {
InitCommand=cmd(shadowlength,1;y,10;zoom,0.7;vertspacing,-8;ztest,true);
BeginCommand=function(self)
local numSongsPlayed = profile:GetNumTotalSongsPlayed();
self:settext( string.format( GetSongsPlayedString( numSongsPlayed ), numSongsPlayed ) )
end;
};
};
t[#t+1]=ProfileCard;
end;
return t;
end;
function LoadCard(cColor)
local t = Def.ActorFrame {
LoadActor( THEME:GetPathG("ScreenSelectProfile","CardBackground") ) .. {
InitCommand=cmd(diffuse,ColorMidTone(cColor));
};
};
return t
end
function LoadPlayerStuff(Player)
local t = {};
local pn = (Player == PLAYER_1) and 1 or 2;
--[[ local t = LoadActor(THEME:GetPathB('', '_frame 3x3'), 'metal', 200, 230) .. {
Name = 'BigFrame';
}; --]]
t[#t+1] = Def.ActorFrame {
Name = 'JoinFrame';
LoadCard(color('#882D47'));
--[[ Def.Quad {
InitCommand=cmd(zoomto,200+4,230+4);
OnCommand=cmd(shadowlength,1;diffuse,color("0,0,0,0.5"));
};
Def.Quad {
InitCommand=cmd(zoomto,200,230);
OnCommand=cmd(diffuse,Color('Orange');diffusealpha,0.5);
}; --]]
LoadFont("Common Italic Condensed") .. {
Text="Press &START; to join";
InitCommand=cmd(shadowlength,1;zoom,1.25);
OnCommand=cmd(diffuseshift;effectcolor1,Color('White');effectcolor2,color("0.5,0.5,0.5");strokecolor,color("#4A1110"));
};
};
t[#t+1] = Def.ActorFrame {
Name = 'BigFrame';
LoadCard(PlayerColor(Player));
};
t[#t+1] = Def.ActorFrame {
Name = 'SmallFrame';
InitCommand=cmd(y,-2);
Def.Quad {
InitCommand=cmd(zoomto,270,48);
OnCommand=cmd(diffuse,PlayerDarkColor(Player);fadeleft,0.1;faderight,0.1);
};
};
t[#t+1] = Def.ActorScroller{
Name = 'Scroller';
NumItemsToDraw=6;
--InitCommand=cmd(zoom,2);
OnCommand=cmd(y,1;SetFastCatchup,true;SetMask,200,58;SetSecondsPerItem,0.15);
OffCommand=cmd(decelerate,0.5;diffusealpha,0);
TransformFunction=function(self, offset, itemIndex, numItems)
local focus = scale(math.abs(offset),0,2,1,0);
self:visible(false);
self:y(math.floor( offset*48 ));
-- self:zoomy( focus );
-- self:z(-math.abs(offset));
-- self:zoom(focus);
end;
children = GetLocalProfiles();
};
t[#t+1] = Def.ActorFrame {
Name = "EffectFrame";
};
t[#t+1] = LoadFont("Common Fallback") .. {
Name = 'SelectedProfileText';
InitCommand=cmd(y,160;shadowlength,1;diffuse,color("#FFFFFF");strokecolor,ColorDarkTone(PlayerColor(Player));diffusebottomedge,color("#FFFFFF");zoom,1.25);
};
return t;
end;
function UpdateInternal3(self, Player)
local pn = (Player == PLAYER_1) and 1 or 2;
local frame = self:GetChild(string.format('P%uFrame', pn));
local scroller = frame:GetChild('Scroller');
local seltext = frame:GetChild('SelectedProfileText');
local joinframe = frame:GetChild('JoinFrame');
local smallframe = frame:GetChild('SmallFrame');
local bigframe = frame:GetChild('BigFrame');
if GAMESTATE:IsHumanPlayer(Player) then
frame:visible(true);
if MEMCARDMAN:GetCardState(Player) == 'MemoryCardState_none' then
--using profile if any
joinframe:visible(false);
smallframe:visible(true);
bigframe:visible(true);
seltext:visible(true);
scroller:visible(true);
local ind = SCREENMAN:GetTopScreen():GetProfileIndex(Player);
if ind > 0 then
scroller:SetDestinationItem(ind-1);
seltext:settext(PROFILEMAN:GetLocalProfileFromIndex(ind-1):GetDisplayName());
else
if SCREENMAN:GetTopScreen():SetProfileIndex(Player, 1) then
scroller:SetDestinationItem(0);
self:queuecommand('UpdateInternal2');
else
joinframe:visible(true);
smallframe:visible(false);
bigframe:visible(false);
scroller:visible(false);
seltext:settext('No profile');
end;
end;
else
--using card
smallframe:visible(false);
scroller:visible(false);
seltext:settext('CARD');
SCREENMAN:GetTopScreen():SetProfileIndex(Player, 0);
end;
else
joinframe:visible(true);
scroller:visible(false);
seltext:visible(false);
smallframe:visible(false);
bigframe:visible(false);
end;
end;
-- here's a (messy) fix for one player's selection ending the screen,
-- at least until this whole thing is rewritten to be... Not this
local ready = {}
local function AllPlayersReady()
for i, pn in ipairs(GAMESTATE:GetHumanPlayers()) do
if not ready[pn] then
return false
end
end
-- if it hasn't returned false by now, surely it must be true, right? RIGHT???
return true
end
local t = Def.ActorFrame {
StorageDevicesChangedMessageCommand=function(self, params)
self:queuecommand('UpdateInternal2');
end;
CodeMessageCommand = function(self, params)
if params.Name == 'Start' or params.Name == 'Center' then
MESSAGEMAN:Broadcast("StartButton");
if not GAMESTATE:IsHumanPlayer(params.PlayerNumber) then
SCREENMAN:GetTopScreen():SetProfileIndex(params.PlayerNumber, -1);
else
ready[params.PlayerNumber] = true
if AllPlayersReady() then
SCREENMAN:GetTopScreen():Finish();
end
end;
end;
if params.Name == 'Up' or params.Name == 'Up2' or params.Name == 'DownLeft' then
-- Added a line to make sure the player can't fiddle around in the menu
-- after they've already made a selection.
if GAMESTATE:IsHumanPlayer(params.PlayerNumber) and not ready[params.PlayerNumber] then
local ind = SCREENMAN:GetTopScreen():GetProfileIndex(params.PlayerNumber);
if ind > 1 then
if SCREENMAN:GetTopScreen():SetProfileIndex(params.PlayerNumber, ind - 1 ) then
MESSAGEMAN:Broadcast("DirectionButton");
self:queuecommand('UpdateInternal2');
end;
end;
end;
end;
if params.Name == 'Down' or params.Name == 'Down2' or params.Name == 'DownRight' then
if GAMESTATE:IsHumanPlayer(params.PlayerNumber) and not ready[params.PlayerNumber] then
local ind = SCREENMAN:GetTopScreen():GetProfileIndex(params.PlayerNumber);
if ind > 0 then
if SCREENMAN:GetTopScreen():SetProfileIndex(params.PlayerNumber, ind + 1 ) then
MESSAGEMAN:Broadcast("DirectionButton");
self:queuecommand('UpdateInternal2');
end;
end;
end;
end;
if params.Name == 'Back' then
if GAMESTATE:GetNumPlayersEnabled()==0 then
SCREENMAN:GetTopScreen():Cancel();
else
MESSAGEMAN:Broadcast("BackButton")
-- Allow... erm... un-readying a player.
if ready[params.PlayerNumber] then
ready[params.PlayerNumber] = false
else
SCREENMAN:GetTopScreen():SetProfileIndex(params.PlayerNumber, -2);
end
end;
end;
end;
PlayerJoinedMessageCommand=function(self, params)
self:queuecommand('UpdateInternal2');
end;
PlayerUnjoinedMessageCommand=function(self, params)
self:queuecommand('UpdateInternal2');
end;
OnCommand=function(self, params)
self:queuecommand('UpdateInternal2');
end;
UpdateInternal2Command=function(self)
UpdateInternal3(self, PLAYER_1);
UpdateInternal3(self, PLAYER_2);
end;
children = {
Def.ActorFrame {
Name = 'P1Frame';
InitCommand=cmd(x,SCREEN_CENTER_X-160;y,SCREEN_CENTER_Y);
--OnCommand=cmd(zoom,0;bounceend,0.35;zoom,1);
OffCommand=cmd(decelerate,0.3;diffusealpha,0);
-- PlayerJoinedMessageCommand=function(self,param)
-- if param.Player == PLAYER_1 then
-- (cmd(;zoom,1.15;bounceend,0.175;zoom,1.0))(self);
-- end;
-- end;
children = LoadPlayerStuff(PLAYER_1);
};
Def.ActorFrame {
Name = 'P2Frame';
InitCommand=cmd(x,SCREEN_CENTER_X+160;y,SCREEN_CENTER_Y);
--OnCommand=cmd(zoom,0;bounceend,0.35;zoom,1);
OffCommand=cmd(decelerate,0.3;diffusealpha,0);
-- PlayerJoinedMessageCommand=function(self,param)
-- if param.Player == PLAYER_2 then
-- (cmd(zoom,1.15;bounceend,0.175;zoom,1.0))(self);
-- end;
-- end;
children = LoadPlayerStuff(PLAYER_2);
};
-- sounds
LoadActor( THEME:GetPathS("Common","start") )..{
StartButtonMessageCommand=cmd(play);
};
LoadActor( THEME:GetPathS("Common","cancel") )..{
BackButtonMessageCommand=cmd(play);
};
LoadActor( THEME:GetPathS("Common","value") )..{
DirectionButtonMessageCommand=cmd(play);
};
};
};
return t;
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1 +0,0 @@
_blank
@@ -1,37 +0,0 @@
if not GAMESTATE:IsCourseMode() then return Def.ActorFrame{} end; -- short circuit
local slideTime = 1.1;
local slideWait = 1.25;
local bottomSlide = 0.76;
local course = GAMESTATE:GetCurrentCourse()
local t = Def.ActorFrame{
-- background
Def.Sprite{
InitCommand=cmd(Center);
BeginCommand=function(self)
if course:GetBackgroundPath() then
self:Load( course:GetBackgroundPath() )
else
-- default to the BG of the first song in the course
self:LoadFromCurrentSongBackground()
end
end;
OnCommand=function(self)
self:scale_or_crop_background()
self:addy(SCREEN_HEIGHT):sleep(slideWait):smooth(slideTime):addy(-SCREEN_HEIGHT);
end;
};
-- alternate background
Def.Sprite{
InitCommand=cmd(Center);
BeginCommand=cmd(LoadFromCurrentSongBackground;scale_or_crop_background;diffusealpha,0);
OnCommand=cmd(playcommand,"Show");
ShowCommand=function(self)
if course:HasBackground() then
self:addy(SCREEN_HEIGHT):sleep(slideWait):smooth(slideTime):addy(-SCREEN_HEIGHT);
end
end;
};
};
return t;
Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

@@ -1,196 +0,0 @@
local playMode = GAMESTATE:GetPlayMode()
local slideTime = 1.1;
local slideWait = 1.25;
local bottomSlide = 0.5;
local easeTime = 0.10;
local sStage = ""
sStage = GAMESTATE:GetCurrentStage()
if playMode ~= 'PlayMode_Regular' and playMode ~= 'PlayMode_Rave' and playMode ~= 'PlayMode_Battle' then
sStage = playMode;
end;
local t = Def.ActorFrame {};
t[#t+1] = Def.Quad {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;diffuse,Color("Black"));
};
if GAMESTATE:IsCourseMode() then
t[#t+1] = LoadActor("CourseDisplay");
else
t[#t+1] = Def.Sprite {
InitCommand=cmd(Center;diffusealpha,0.26);
BeginCommand=cmd(LoadFromCurrentSongBackground);
OnCommand=function(self)
self:scale_or_crop_background()
self:addy(SCREEN_HEIGHT):sleep(slideWait):smooth(slideTime):addy(-SCREEN_HEIGHT):diffusealpha(1);
end;
};
end
-- BG for credits
t[#t+1] = Def.ActorFrame {
OnCommand=cmd(addy,SCREEN_HEIGHT;sleep,slideWait;smooth,slideTime+easeTime;addy,-SCREEN_HEIGHT;sleep,2-easeTime;smooth,bottomSlide;addy,240);
-- Behind stage graphic
Def.Quad {
InitCommand=cmd(vertalign,bottom;x,SCREEN_CENTER_X;y,SCREEN_BOTTOM-110;zoomto,SCREEN_WIDTH,120);
OnCommand=function(self)
self:diffuse(color("#000000")):diffusealpha(0.8);
end
};
-- Behind song
Def.Quad {
InitCommand=cmd(vertalign,bottom;x,SCREEN_CENTER_X;y,SCREEN_BOTTOM;zoomto,SCREEN_WIDTH,110);
OnCommand=function(self)
self:diffuse(color("#000000")):diffusealpha(0.9);
end
};
};
local stage_num_actor= THEME:GetPathG("ScreenStageInformation", "Stage " .. ToEnumShortString(sStage), true)
if stage_num_actor ~= "" and FILEMAN:DoesFileExist(stage_num_actor) then
stage_num_actor= LoadActor(stage_num_actor)
else
-- Midiman: We need a "Stage Next" actor or something for stages after
-- the 6th. -Kyz
local curStage = GAMESTATE:GetCurrentStage();
stage_num_actor= Def.BitmapText{
Font= "Common Normal", Text= thified_curstage_index(false) .. " Stage",
InitCommand= function(self)
self:zoom(1.5)
self:strokecolor(Color.Black)
self:diffuse(StageToColor(curStage));
self:diffusetopedge(ColorLightTone(StageToColor(curStage)));
end
}
end
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y+190);
OnCommand=cmd(addy,SCREEN_HEIGHT;sleep,slideWait;smooth,slideTime+easeTime;addy,-SCREEN_HEIGHT;sleep,2-easeTime;smooth,bottomSlide;addy,240);
stage_num_actor .. {
OnCommand=cmd(zoom,1;diffusealpha,1);
};
};
-- Step author credits
if GAMESTATE:IsHumanPlayer(PLAYER_1) == true then
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(y,SCREEN_BOTTOM-80;x,SCREEN_LEFT+40);
OnCommand=cmd(addy,SCREEN_HEIGHT;sleep,slideWait;smooth,slideTime+easeTime;addy,-SCREEN_HEIGHT;sleep,2-easeTime;smooth,bottomSlide;addy,240);
LoadFont("Common Italic Condensed") .. {
OnCommand=cmd(playcommand,"Set";horizalign,left;diffuse,color("#FFFFFF"));
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1:GetAuthorCredit() ~= "" then
self:settext(string.upper(THEME:GetString("OptionTitles","Step Author")) .. ":");
else
self:settext("")
end
else
self:settext("")
end
end
};
LoadFont("Common Fallback Font") .. {
InitCommand=cmd(addy,22);
OnCommand=cmd(playcommand,"Set";horizalign,left;zoom,0.75;diffuse,color("#FFFFFF"));
SetCommand=function(self)
local stepsP1 = GAMESTATE:GetCurrentSteps(PLAYER_1)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP1 ~= nil then
self:settext(stepsP1:GetAuthorCredit())
else
self:settext("")
end
else
self:settext("")
end
end
};
};
end
if GAMESTATE:IsHumanPlayer(PLAYER_2) == true then
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(y,SCREEN_BOTTOM-80;x,SCREEN_RIGHT-40);
OnCommand=cmd(addy,SCREEN_HEIGHT;sleep,slideWait;smooth,slideTime+easeTime;addy,-SCREEN_HEIGHT;sleep,2-easeTime;smooth,bottomSlide;addy,240);
LoadFont("Common Italic Condensed") .. {
OnCommand=cmd(playcommand,"Set";horizalign,right;diffuse,color("#FFFFFF"));
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
local diff = stepsP2:GetDifficulty();
if stepsP2:GetAuthorCredit() ~= "" then
self:settext(string.upper(THEME:GetString("OptionTitles","Step Author")) .. ":");
else
self:settext("")
end
else
self:settext("")
end
end
};
LoadFont("Common Fallback Font") .. {
InitCommand=cmd(addy,22);
OnCommand=cmd(playcommand,"Set";horizalign,right;zoom,0.75;diffuse,color("#FFFFFF"));
SetCommand=function(self)
local stepsP2 = GAMESTATE:GetCurrentSteps(PLAYER_2)
local song = GAMESTATE:GetCurrentSong();
if song then
if stepsP2 ~= nil then
self:settext(stepsP2:GetAuthorCredit())
else
self:settext("")
end
else
self:settext("")
end
end
};
};
end
-- Song title and artist
t[#t+1] = Def.ActorFrame {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_BOTTOM-80);
OnCommand=cmd(addy,SCREEN_HEIGHT;sleep,slideWait;smooth,slideTime+easeTime;addy,-SCREEN_HEIGHT;sleep,2-easeTime;smooth,bottomSlide;addy,240);
LoadFont("Common Fallback Font") .. {
Text=GAMESTATE:IsCourseMode() and GAMESTATE:GetCurrentCourse():GetDisplayFullTitle() or GAMESTATE:GetCurrentSong():GetDisplayFullTitle();
InitCommand=cmd(diffuse,color("#FFFFFF");maxwidth,SCREEN_WIDTH*0.6);
OnCommand=cmd(zoom,1);
};
LoadFont("Common Fallback Font") .. {
Text=GAMESTATE:IsCourseMode() and ToEnumShortString( GAMESTATE:GetCurrentCourse():GetCourseType() ) or GAMESTATE:GetCurrentSong():GetDisplayArtist();
InitCommand=cmd(diffuse,color("#FFFFFF");maxwidth,SCREEN_WIDTH*0.6);
OnCommand=cmd(zoom,0.75;addy,24);
};
};
-- Stunt BG in case the BG accidentally overhangs
t[#t+1] = Def.Quad {
InitCommand=cmd(Center;zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;diffuse,Color("Black"));
OnCommand=cmd(sleep,slideWait;smooth,slideTime;addy,-SCREEN_HEIGHT;sleep,0.2;diffusealpha,0);
};
t[#t+1] = Def.ActorFrame {
LoadActor("_arrow") .. {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y;diffuse,color("#DAD6CC"));
OnCommand=cmd(diffusealpha,0;sleep,0.5;diffusealpha,0.6;decelerate,0.4;zoom,1.2;diffusealpha,0);
};
LoadActor("_arrow") .. {
InitCommand=cmd(x,SCREEN_CENTER_X;y,SCREEN_CENTER_Y;diffuse,color("#DAD6CC"));
OnCommand=cmd(zoom,0;bounceend,0.5;zoom,1;sleep,0.75;smooth,slideTime;addy,-SCREEN_HEIGHT);
};
};
return t
@@ -1,92 +0,0 @@
local function CreditsText( pn )
local text = LoadFont(Var "LoadingScreen","credits") .. {
InitCommand=function(self)
self:name("Credits" .. PlayerNumberToString(pn))
ActorUtil.LoadAllCommandsAndSetXY(self,Var "LoadingScreen");
end;
UpdateTextCommand=function(self)
local str = ScreenSystemLayerHelpers.GetCreditsMessage(pn);
self:settext(str);
end;
UpdateVisibleCommand=function(self)
local screen = SCREENMAN:GetTopScreen();
local bShow = true;
if screen then
local sClass = screen:GetName();
bShow = THEME:GetMetric( sClass, "ShowCreditDisplay" );
end
self:visible( bShow );
end
};
return text;
end;
--[[ local function PlayerPane( PlayerNumber )
local t = Def.ActorFrame {
InitCommand=function(self)
self:name("PlayerPane" .. PlayerNumberToString(PlayerNumber));
-- ActorUtil.LoadAllCommandsAndSetXY(self,Var "LoadingScreen");
end
};
t[#t+1] = Def.ActorFrame {
Name = "Background";
Def.Quad {
InitCommand=cmd(zoomto,160,28;queuecommand,"On");
OnCommand=cmd(diffuse,PlayerColor(PlayerNumber);fadebottom,1);
};
};
t[#t+1] = Def.BitmapText{
Font="Common Normal";
Name = "PlayerText";
InitCommand=cmd(x,-60;maxwidth,80/0.5;zoom,0.5;queuecommand,"On");
OnCommand=cmd(playcommand,"Set");
SetCommand=function(self)
local profile = PROFILEMAN:GetProfile( PlayerNumber) or PROFILEMAN:GetMachineProfile()
if profile then
self:settext( profile:GetDisplayName() );
else
self:settext( "NoProf" );
end
end;
};
return t
end --]]
--
local t = Def.ActorFrame {}
-- Aux
t[#t+1] = LoadActor(THEME:GetPathB("ScreenSystemLayer","aux"));
-- Credits
t[#t+1] = Def.ActorFrame {
--[[ PlayerPane( PLAYER_1 ) .. {
InitCommand=cmd(x,scale(0.125,0,1,SCREEN_LEFT,SCREEN_WIDTH);y,SCREEN_BOTTOM-16)
}; --]]
CreditsText( PLAYER_1 );
CreditsText( PLAYER_2 );
};
-- Text
t[#t+1] = Def.ActorFrame {
Def.Quad {
InitCommand=cmd(zoomtowidth,SCREEN_WIDTH;zoomtoheight,30;horizalign,left;vertalign,top;y,SCREEN_TOP;diffuse,color("0,0,0,0"));
OnCommand=cmd(finishtweening;diffusealpha,0.85);
OffCommand=cmd(sleep,3;linear,0.5;diffusealpha,0);
};
Def.BitmapText{
Font="_fira mono 24px";
Name="Text";
InitCommand=cmd(maxwidth,750;horizalign,left;vertalign,top;y,SCREEN_TOP+10;x,SCREEN_LEFT+10;shadowlength,1;diffusealpha,0);
OnCommand=cmd(finishtweening;diffusealpha,1;zoom,0.5);
OffCommand=cmd(sleep,3;linear,0.5;diffusealpha,0);
};
SystemMessageMessageCommand = function(self, params)
self:GetChild("Text"):settext( params.Message );
self:playcommand( "On" );
if params.NoAnimate then
self:finishtweening();
end
self:playcommand( "Off" );
end;
HideSystemMessageMessageCommand = cmd(finishtweening);
};
return t;
@@ -1,17 +0,0 @@
return Def.ActorFrame {
Def.Quad {
InitCommand=cmd(zoomto,SCREEN_WIDTH,SCREEN_HEIGHT;Center);
OnCommand=cmd(diffuse,Color.Black;diffusealpha,0;decelerate,0.3;diffusealpha,0.7);
OffCommand=cmd(stoptweening;decelerate,0.2;diffusealpha,0);
};
Def.DeviceList {
Font="Common Italic Condensed",
InitCommand=cmd(x,SCREEN_LEFT+20;y,SCREEN_TOP+130;zoom,0.8;halign,0;diffuse,color("#FFFFFF"));
OffCommand=cmd(stoptweening;decelerate,0.2;diffusealpha,0);
};
Def.InputList {
Font="Common Condensed",
InitCommand=cmd(x,SCREEN_CENTER_X-250;y,SCREEN_CENTER_Y;zoom,1;halign,0;vertspacing,8;strokecolor,color("#000000"));
};
};
@@ -1,7 +0,0 @@
return Def.ActorFrame {
Def.Quad{
InitCommand=cmd(scaletocover,-SCREEN_WIDTH*2,SCREEN_TOP,SCREEN_WIDTH*2,SCREEN_BOTTOM;diffuse,color("0,0,0,0.5"));
OnCommand=cmd(diffusealpha,0;smooth,0.2;diffusealpha,0.5);
OffCommand=cmd(smooth,0.2;diffusealpha,0);
};
};
Binary file not shown.

Before

Width:  |  Height:  |  Size: 174 KiB

Some files were not shown because too many files have changed in this diff Show More