Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local mStages = STATSMAN:GetStagesPlayed();
- local i = 0;
- local grades = {
- Grade_Tier01 = 0;
- Grade_Tier02 = 0;
- Grade_Tier03 = 1;
- Grade_Tier04 = 2;
- Grade_Tier05 = 3;
- Grade_Tier06 = 4;
- Grade_Tier07 = 5;
- Grade_Failed = 6;
- Grade_None = 7;
- };
- local t = Def.ActorFrame {};
- --[[ PLAYER LABELS--]]
- for pn in ivalues(PlayerNumber) do
- t[#t+1] = LoadActor( THEME:GetPathG("ScreenEvaluation", "PlayerLabel " .. PlayerNumberToString(pn)) ) .. {
- InitCommand=cmd(player,pn);
- BeginCommand=function(self)
- local pX = 0;
- if pn == PLAYER_1 then
- pX = -233;
- else
- pX = 233;
- end
- self:addx( pX );
- self:addy( -80 );
- end;
- OnCommand=cmd(zoomy,0;diffusealpha,0;sleep,1.969;linear,0.100;zoomy,1;diffusealpha,1);
- OffCommand=cmd(sleep,0.000;linear,0.133;zoomy,0;diffusealpha,0);
- };
- end
- for pn in ivalues(PlayerNumber) do
- for i = 1, mStages do
- local sStats = STATSMAN:GetPlayedStageStats( i );
- local pStageStats = sStats:GetPlayerStageStats( pn );
- local function GetColor()
- local pColor = "1,1,1,0";
- if pStageStats:FullComboOfScore('TapNoteScore_W1') then
- pColor = "#ffffff";
- elseif pStageStats:FullComboOfScore('TapNoteScore_W2') then
- pColor = "#ffff00";
- elseif pStageStats:FullCombo() then
- pColor = "#33cc33";
- else
- pColor = "1,1,1,0";
- end
- return pColor
- end;
- --[[ SCORE DISPLAYS --]]
- t[#t+1] = Def.ActorFrame {
- InitCommand=cmd(player,pn);
- LoadFont( "ScreenWithMenuElements StageDisplay" ) .. {
- InitCommand=cmd(zoom,0.5);
- BeginCommand=function(self)
- local pStage = sStats:GetStage();
- local pX = 0;
- if pn == PLAYER_1 then
- pX = -280;
- self:horizalign( left );
- else
- pX = 280;
- self:horizalign( right );
- end
- self:maxwidth( 200 );
- self:addx( pX );
- self:addy( ( (mStages - i) * 50) - 62 );
- self:diffuse( color( "ffffff" ) );
- self:settext( StageToLocalizedString(pStage) .. " STAGE" );
- end;
- OnCommand=cmd();
- };
- LoadFont( "ScreenEvaluation ScoreNumber" ) .. {
- InitCommand=cmd(zoom,1.033;diffuse,color('#d9b600');diffusealpha,0);
- BeginCommand=function(self)
- local pScore = pStageStats:GetScore();
- local score_length = string.len(tostring(pScore));
- local target_length = 7;
- local text = string.rep('0', clamp(target_length - score_length, 0, 7));
- local pX = 0;
- if pn == PLAYER_1 then
- pX = -230;
- else
- pX = 230;
- end
- self:addx( pX );
- self:addy( ( (mStages - i) * 50) - 42 );
- self:settext(comma_value(text .. pScore));
- end;
- OnCommand=function(self)
- local pX = 0;
- if pn == PLAYER_1 then
- pX = SCREEN_WIDTH/2;
- else
- pX = -(SCREEN_WIDTH/2);
- end
- self:sleep( 1.952 );
- self:diffusealpha( 1 );
- self:addx( (-1) * ( pX ) );
- self:linear( 0.2 );
- self:addx( pX );
- end;
- };
- --[[ GRADE RING --]]
- LoadActor("ring") .. {
- InitCommand=cmd();
- BeginCommand=function(self)
- if pn == PLAYER_1 then
- pX = -80;
- else
- pX = 140;
- end
- self:addx( pX );
- self:addy( ( (mStages - i) * 50) - 60 );
- self:diffuse( color(GetColor()) );
- if pStageStats:FullCombo() then
- self:visible( true );
- else
- self:visible( false );
- end
- end;
- OnCommand=cmd(zoom,0;diffusealpha,0;sleep,0.000;sleep,0.316;linear,0.266;diffusealpha,1;zoom,0.5;spin;effectmagnitude,0,0,170);
- OffCommand=cmd(zoom,0.5;sleep,0.0000;sleep,0.083;linear,0.133;zoom,0;diffusealpha,0;rotationz,180);
- };
- --[[ GRADE LINES --]]
- LoadActor("lines") .. {
- InitCommand=cmd();
- BeginCommand=function(self)
- if pn == PLAYER_1 then
- pX = -80;
- else
- pX = 140;
- end
- self:addx( pX );
- self:addy( ( (mStages - i) * 50) - 60 );
- self:diffuse( color(GetColor()) );
- if pStageStats:FullCombo() then
- self:visible( true );
- else
- self:visible( false );
- end
- end;
- OnCommand=cmd(zoom,0;diffusealpha,0;sleep,0.000;sleep,0.316;linear,0.266;diffusealpha,1;zoom,0.5;spin;effectmagnitude,0,0,-170);
- OffCommand=cmd(zoomy,0.5;sleep,0.0000;sleep,0.083;linear,0.133;zoom,0;diffusealpha,0;rotationz,-180);
- };
- --[[ INDIVIDUAL STAGE GRADES --]]
- LoadActor(THEME:GetPathG("","MusicWheelItem grades/grades")) .. {
- InitCommand=cmd(pause);
- BeginCommand=function(self)
- local pGrade = pStageStats:GetGrade();
- local state = grades[pGrade] or grades['Grade_None'];
- local pX = 0;
- if pn == PLAYER_1 then
- pX = -103;
- else
- pX = 102;
- end
- if state then
- self:visible( true );
- self:setstate(state);
- else
- self:visible( false );
- end
- self:addx( pX );
- self:addy( ( (mStages - i) * 50) - 50 );
- end;
- OnCommand=cmd(zoom,0.5);
- };
- LoadActor( "difficulty tab" ) .. {
- InitCommand=cmd();
- BeginCommand=function(self)
- local pSteps = pStageStats:GetPlayedSteps();
- --[[local pDifficulty = pSteps:GetDifficulty();--]]
- local pX = 0;
- if pn == PLAYER_1 then
- pX = -144;
- else
- pX = 144;
- end
- self:addx( pX );
- self:addy( ( (mStages - i) * 50) - 50 );
- --[[self:diffuse( CustomDifficultyToColor(pDifficulty) );--]]
- end;
- OnCommand=cmd();
- };
- LoadActor( "frame" ) .. {
- InitCommand=cmd();
- BeginCommand=function(self)
- self:addy( ( (mStages - i) * 50) - 54 );
- end;
- OnCommand=cmd();
- };
- Def.Sprite {
- InitCommand=cmd();
- BeginCommand=function(self)
- self:addy( ( (mStages - i) * 50) - 50 );
- self:LoadBanner( STATSMAN:GetPlayedSongs() );
- end;
- OnCommand=cmd();
- };
- };
- end
- end
- return t
Add Comment
Please, Sign In to add comment