local cond_yu_result= GAMESTATE:IsPlayerEnabled(PLAYER_1)

local cond_zu_result= GAMESTATE:IsPlayerEnabled(PLAYER_2)

local cond_wu_result= not GAMESTATE:IsPlayerEnabled(PLAYER_1)

local cond_xu_result= not GAMESTATE:IsPlayerEnabled(PLAYER_2)

local function optional_actor(cond, actor)
	if cond then return actor end
	return Def.Actor{}
end

return Def.ActorFrame{
  Name= "actor_Au",
  Def.ActorFrame{
    Name= "actor_Bu",
    LoadActor('../../mawaru_finale_ch0.lua') .. {
      Name= "actor_Cu",
      File= "../../mawaru_finale_ch0.lua",
    },
    LoadActor('../../mawaru_finale_ch1.lua') .. {
      Name= "actor_Du",
      File= "../../mawaru_finale_ch1.lua",
    },
    LoadActor('../../mawaru_finale_ch2.lua') .. {
      Name= "actor_Eu",
      File= "../../mawaru_finale_ch2.lua",
    },
    LoadActor('../../mawaru_finale_ch3.lua') .. {
      Name= "actor_Fu",
      File= "../../mawaru_finale_ch3.lua",
    },
    LoadActor('../../mawaru_finale_ch4.lua') .. {
      Name= "actor_av",
      File= "../../mawaru_finale_ch4.lua",
    },
    LoadActor('../../mawaru_finale_ch5.lua') .. {
      Name= "actor_bv",
      File= "../../mawaru_finale_ch5.lua",
    },
    Def.Quad{
      Name= "actor_cv",
      InitCommand= function(self)
		
			--this is where variables go when the simfile starts up
			--function declarations, and things that will never change even
			--if this particular minigame is restarted after being played once before
		
			--for storing if a button is held down
			mawaru_finale_held = {0,0,0,0,0,0,0,0};
			
			mawaru_finale_rtime = 0.3;
			
			mawaru_finale_rawscore = {0,0}
			mawaru_finale_maxscore = {100,100}
			mawaru_finale_score = {0,0}
			mawaru_finale_invin = {0,0}
			mawaru_finale_flickertimer = 0;
			mawaru_finale_flickeralpha = 1;
			
			fspd = 0.8;
			
			mawaru_finale_cmd = {1,1}
			
			mawaru_finale_p1a = {{},{},{}}
			mawaru_finale_p1ptr = {1,1,1}
			mawaru_finale_p2a = {{},{},{}}
			mawaru_finale_p2ptr = {1,1,1}
			
			mawaru_finale_colpos = {0,250,320,0}
			
			mawaru_finale_leadin = 4
			
			mawaru_finale_room_speed = 1.5;
			
			function mawaru_finale_placenote(pn,beat,col,t)
				
				local group = pn
				local thing = 2
				if col == 2 then
					thing = 1;
				end
				if tostring(t) == 'M' then
					thing = 3;
				end
				local a = _G['mawaru_finale_p'..group..'a'][thing][ _G['mawaru_finale_p'..group..'ptr'][thing] ]
				
				col = col+1
				--local speed = _G['mawaru_finale_p'..group..'speed']*mawaru_finale_colspeeds[group][col];
				local speed = 2;
				if tostring(t) == 'M' then
					speed = 3
				end
				
				a.active = true;
				a.col = col;
				a.alpha = 0;
				a.glow = 1;
				a.targ = beat
				if thing ~= 3 then
					a.zoom = 0.75;
				else
					a.zoom = 1;
				end
				
				local b = a.actor
				
				if b then
					b:visible(true);
					b:x(9999);
					b:diffusealpha(1)
					b:glow(1,1,1,0);
					b:y(mawaru_finale_colpos[col]);
					b:zoom(1);
				end
				
				_G['mawaru_finale_p'..group..'ptr'][thing] = _G['mawaru_finale_p'..group..'ptr'][thing]+1
				if _G['mawaru_finale_p'..group..'ptr'][thing] > table.getn(_G['mawaru_finale_p'..group..'a'][thing]) then
					_G['mawaru_finale_p'..group..'ptr'][thing] = 1
				end
				
			end
			
			function mawaru_finale_update()
				local beat = GAMESTATE:GetSongBeat()
				for pf=1,2 do
					if GAMESTATE:IsPlayerEnabled(pf-1) then
						for q=1,3 do
							for i=1,table.getn(_G['mawaru_finale_p'..pf..'a'][q]) do
								local a = _G['mawaru_finale_p'..pf..'a'][q][i]
								if a.active and beat > mod_firstSeenBeat+1 then
									
									local speed = 1.75*mawaru_finale_room_speed
									if q == 3 then
										speed = 1.75*1.5*mawaru_finale_room_speed
									end
									
									local b = a.actor
									
									b:linear(0.02);
									
									b:x(((a.targ-beat)*64*speed)-160)
									b:diffusealpha(a.alpha)
									b:glow(1,1,1,a.glow);
									b:y(mawaru_finale_colpos[a.col]);
									b:zoom(a.zoom)
									
									if a.alpha < 1 then
										a.alpha = a.alpha+0.2;
									else
										a.alpha = 1
										if a.glow > 0 then
											a.glow = a.glow-0.2
										else
											a.glow = 0;
										end
									end
									
									if a.targ-beat <= -4 then
										b:visible(false);
										a.active = false;
									end
									
								end
							end
						end
					end
				end
			end
			
			mawaru_finale_cur = {1,1}
			mawaru_finale_cur2 = {1,1}
			
			mawaru_finale_jumpdelay = {0,0}
			mawaru_finale_jumper = {0,0}
			mawaru_finale_croucher = {0,0}
			
			mawaru_finale_ended = false;
			
		end,
      KillCommand= function(self)
			--any cleanup, if necessary
		end,
      StartCommand= function(self)
			
			--variables set up when a game is started
			--wait 2 seconds (for the curtain or whatever) before accepting any inputs
			mawaru_finale_lockinput = {.3,.3};
			
			for pn=1,2 do
				if GAMESTATE:IsPlayerEnabled(pn-1) then
					mawaru_finale_maxscore[pn] = table.getn(_G['mawaru_finale_ch'..mawaru_difficulty[pn] ])
				end
			end
			
			self:sleep(0.02);
			self:queuecommand('Update');

		end,
      UpdateCommand= function(self)
			
			local beat = GAMESTATE:GetSongBeat();
			
			mawaru_finale_update();
			
			if mawaru_finale_flickertimer <= 0 then
				mawaru_finale_flickertimer = 0.04;
				if mawaru_finale_flickeralpha == 1 then
					mawaru_finale_flickeralpha = 0;
				else
					mawaru_finale_flickeralpha = 1;
				end
			else
				mawaru_finale_flickertimer = mawaru_finale_flickertimer-0.02;
			end
			
			--game logic
			
			for pn=1,2 do
				
				if GAMESTATE:IsPlayerEnabled(pn-1) then
			
					local chart = _G['mawaru_finale_ch'..mawaru_difficulty[pn] ]
					while mawaru_finale_cur[pn] <= table.getn(chart) and beat > chart[ mawaru_finale_cur[pn] ][1]-4 do
						mawaru_finale_placenote(pn, chart[mawaru_finale_cur[pn] ][1],chart[mawaru_finale_cur[pn] ][2],chart[mawaru_finale_cur[pn] ][3])
						mawaru_finale_cur[pn] = mawaru_finale_cur[pn]+1;
					end
					
					if mawaru_finale_cur2[pn] <= table.getn(chart) and beat > chart[ mawaru_finale_cur2[pn] ][1]+.1 then
						if mawaru_finale_invin[pn] <= 0 and chart[ mawaru_finale_cur2[pn] ][2]+1 == 2 and mawaru_finale_croucher[pn] > 0.1*fspd then
							mawaru_finale_rawscore[pn] = mawaru_finale_rawscore[pn]+1;
						elseif mawaru_finale_invin[pn] <= 0 and chart[ mawaru_finale_cur2[pn] ][2]+1 == 3 and mawaru_finale_jumper[pn] > 0.1*fspd then
							mawaru_finale_rawscore[pn] = mawaru_finale_rawscore[pn]+1;
						elseif mawaru_finale_invin[pn] <= 0 then
							MESSAGEMAN:Broadcast('FinHurtP'..pn);
							--Trace(tostring(chart[ mawaru_finale_cur2[pn] ][2]))
							Sound('conk'..math.random(1,3));
							mawaru_finale_invin[pn] = 1;
							mawaru_finale_rawscore[pn] = mawaru_finale_rawscore[pn]-1;
						end
						mawaru_finale_score[pn] = mawaru_finale_rawscore[pn]/mawaru_finale_maxscore[pn]
						MESSAGEMAN:Broadcast('FinUpdateScoreP'..pn);
						mawaru_finale_cur2[pn] = mawaru_finale_cur2[pn]+1;
					end
				
					if beat > 716 and mawaru_finale_cmd[pn] == 1 then
						_G['mawaru_finale_wallp'..pn]:texcoordvelocity(0.5*mawaru_finale_room_speed,0);
						_G['mawaru_finale_floorp'..pn]:texcoordvelocity(0.5*1.133*mawaru_finale_room_speed,0);
						mawaru_finale_cmd[pn] = 2;
					end
					if beat > 748 and mawaru_finale_cmd[pn] == 2 then
						_G['mawaru_finale_wallp'..pn]:texcoordvelocity(0.5*(210/200)*mawaru_finale_room_speed,0);
						_G['mawaru_finale_floorp'..pn]:texcoordvelocity(0.5*1.133*(210/200)*mawaru_finale_room_speed,0);
						fspd = 0.78;
						mawaru_finale_cmd[pn] = 3;
					end
					if beat > 764 and mawaru_finale_cmd[pn] == 3 then
						_G['mawaru_finale_wallp'..pn]:texcoordvelocity(0.5*(220/200)*mawaru_finale_room_speed,0);
						_G['mawaru_finale_floorp'..pn]:texcoordvelocity(0.5*1.133*(220/200)*mawaru_finale_room_speed,0);
						fspd = 0.74;
						mawaru_finale_cmd[pn] = 4;
					end
					if beat > 776 and mawaru_finale_cmd[pn] == 4 then
						_G['mawaru_finale_wallp'..pn]:texcoordvelocity(0.5*(230/200)*mawaru_finale_room_speed,0);
						_G['mawaru_finale_floorp'..pn]:texcoordvelocity(0.5*1.133*(230/200)*mawaru_finale_room_speed,0);
						fspd = 0.7;
						mawaru_finale_cmd[pn] = 5;
					end
					
					if beat > 783.5 and mawaru_finale_cmd[pn] == 5 then
						_G['mawaru_finale_wallp'..pn]:texcoordvelocity(0,0);
						_G['mawaru_finale_floorp'..pn]:texcoordvelocity(0,0);
						mawaru_finale_cmd[pn] = 6;
						if not mawaru_finale_ended then
							mawaru_finale_ended = true;
							MESSAGEMAN:Broadcast('FinalEnd');
						end
					end
				
					if mawaru_finale_lockinput[pn]>0 then
						mawaru_finale_lockinput[pn] = mawaru_finale_lockinput[pn]-0.02
					end
					
					if mawaru_finale_jumpdelay[pn]>0 then
						mawaru_finale_jumpdelay[pn] = mawaru_finale_jumpdelay[pn]-0.02
					end
					
					if mawaru_finale_jumper[pn]>0 then
						mawaru_finale_jumper[pn] = mawaru_finale_jumper[pn]-0.02
					end
					if mawaru_finale_croucher[pn]>0 then
						mawaru_finale_croucher[pn] = mawaru_finale_croucher[pn]-0.02
					end
					
					if mawaru_finale_invin[pn] > 0 then
					--So, hidden isn't a thing anymore, and visible takes a bool. diffusealpha should work nicely. -Kid
						_G['mawaru_finale_p'..pn]:diffusealpha(1-mawaru_finale_flickeralpha)
						mawaru_finale_invin[pn] = mawaru_finale_invin[pn]-0.02
					else
						_G['mawaru_finale_p'..pn]:diffusealpha(1)
					end
					
					local bpn = pn-1;
					for i=1,4 do
						
						----------------------handle button presses-------------------
						if mawaru_finale_lockinput[pn] <= 0 then
							if i==2 and mawaru_keys[i+(bpn*4)] == 1 and mawaru_finale_held[i+(bpn*4)] == 0 then
								MESSAGEMAN:Broadcast('FinDuckP'..pn);
								mawaru_finale_lockinput[pn] = 0.1;
								mawaru_finale_jumpdelay[pn] = 0;
								mawaru_finale_jumper[pn] = 0;
								mawaru_finale_croucher[pn] = 0.36*fspd;
								mawaru_finale_held[i+(bpn*4)] = 1
							end
							if i==3 and mawaru_keys[i+(bpn*4)] == 1 and mawaru_finale_held[i+(bpn*4)] == 0 and mawaru_finale_jumpdelay[pn] <= 0 then
								MESSAGEMAN:Broadcast('FinJumpP'..pn);
								mawaru_finale_jumpdelay[pn] = 0.3;
								mawaru_finale_jumper[pn] = 0.36*fspd;
								mawaru_finale_lockinput[pn] = 0.1;
								mawaru_finale_croucher[pn] = 0;
								mawaru_finale_held[i+(bpn*4)] = 1
							end
							
						end
						
						----------------------don't touch this------------------------
						--release all buttons - used for detecting if a button is newly pressed, as opposed to held
						if mawaru_keys[i+(bpn*4)] == 0 then
							mawaru_finale_held[i+(bpn*4)] = 0
						end
						---------------------end don't touch this----------------------
						
					end
				
				end
			end
			
			self:sleep(0.02);
			if mawaru_curgame == 19 and mawaru_gamestate == 1 then
				self:queuecommand('Update');
			end
			
		end,
    },
    Def.Quad{
      Name= "actor_dv",
      InitCommand= function(self) mawaru_finale_controller = self end,
    },
    --For all P2 parts, Unconverted x & y pos. -Kid
    Def.ActorFrame{
      Name= "actor_ev",
      OnCommand= cmd(x,320),
      RotateLastGameMessageCommand= cmd(playcommand,"DoRotate"),
      Def.ActorFrame{
        Name= "actor_fv",
        DoRotateCommand= cmd(playcommand,"DR2";accelerate,mawaru_finale_rtime;addy,50;addx,-160;decelerate,mawaru_finale_rtime;addy,50;addx,-160),
        OnCommand= cmd(x,320),
        Def.Sprite{
          Name= "actor_gv",
          InitCommand= function(self) mawaru_finale_wallp2 = self end,
          OnCommand= cmd(x,160;y,150-40;zoomto,2560,400;customtexturerect,0,0,4,1),
          StopCommand= cmd(texcoordvelocity,0,0),
          Texture= "wall.png",
        },
        Def.ActorFrame{
          Name= "actor_hv",
          FOV= 80,
          VanishX= 320,
          VanishY= 480*.75,
          Def.Sprite{
            Name= "actor_iv",
            DR2Command= cmd(accelerate,mawaru_finale_rtime;rotationx,-30;addy,-19;decelerate,mawaru_finale_rtime;rotationx,-60;addy,-19),
            InitCommand= function(self) mawaru_finale_floorp2 = self end,
            OnCommand= cmd(x,160;y,360+40;rotationx,0;zoomto,2560,180;customtexturerect,0,0,4,1),
            StopCommand= cmd(texcoordvelocity,0,0),
            Texture= "floor.png",--This got expanded to floortexside by accident. -Kid
          },
        },
        Def.Sprite{
          Name= "actor_jv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_kv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_lv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_mv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_nv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_ov",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_pv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_qv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_rv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_sv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_tv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_uv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_vv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_wv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_xv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_yv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_zv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_Av",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_Bv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_Cv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_Dv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_Ev",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_Fv",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_aw",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p2a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.ActorFrame{
          Name= "actor_bw",
          InitCommand= function(self) mawaru_finale_p2 = self end,
          OnCommand= cmd(x,-160;y,350;basezoomx,-1;zoom,0.5),
          Def.ActorFrame{
            Name= "actor_cw",
            FinHurtP2MessageCommand= cmd(stoptweening;visible,false;sleep,0.4*fspd;queuecommand,"Unhide"),
            FinalEndMessageCommand= cmd(visible,false),
            FinaleStartMessageCommand= cmd(visible,true),
            OnCommand= cmd(visible,false),
            UnhideCommand= cmd(visible,true),
            Def.Sprite{
              Name= "actor_dw",
              Frames= {
                {Frame= 1, Delay= 0.4},
                {Frame= 0, Delay= 0.5},
                {Frame= 2, Delay= 0.5},
                {Frame= 0, Delay= 0.5},
                {Frame= 1, Delay= 0.1},
            },
              FinDuckP2MessageCommand= cmd(finishtweening;diffusealpha,0;sleep,0.3*fspd;diffusealpha,1),
              FinJumpP2MessageCommand= cmd(finishtweening;diffusealpha,0;sleep,0.3*fspd;diffusealpha,1),
              OnCommand= cmd(effectclock,"bgm";vertalign,bottom),
              Texture= "./_ashe 3x2.png",
            },
            Def.Sprite{
              Name= "actor_ew",
              FinDuckP2MessageCommand= cmd(finishtweening;diffusealpha,0),
              FinJumpP2MessageCommand= cmd(finishtweening;diffusealpha,1;y,-150;linear,0.1*fspd;y,-180;accelerate,0.2*fspd;y,-20;sleep,0;diffusealpha,0),
              OnCommand= cmd(diffusealpha,0;animate,0;setstate,1;vertalign,bottom),
              Texture= "_ashe 3x2.png",
            },
            Def.Sprite{
              Name= "actor_fw",
              FinDuckP2MessageCommand= cmd(finishtweening;diffusealpha,1;zoomy,1;decelerate,0.15*fspd;zoomy,0.8;accelerate,0.15*fspd;zoomy,1;sleep,0;diffusealpha,0),
              FinJumpP2MessageCommand= cmd(finishtweening;diffusealpha,0),
              OnCommand= cmd(diffusealpha,0;vertalign,bottom),
              Texture= "asheslide.png",
            },
          },
          Def.ActorFrame{
            Name= "actor_gw",
            FinHurtP2MessageCommand= cmd(stoptweening;playcommand,"H";visible,true;sleep,0.4*fspd;queuecommand,"Hide"),
            HideCommand= cmd(visible,false),
            OnCommand= cmd(visible,false),
            Def.Sprite{
              Name= "actor_hw",
              HCommand= cmd(finishtweening;rotationz,0;linear,0.4*fspd;rotationz,360;sleep,0;rotationz,0),
              OnCommand= cmd(animate,0;setstate,5;y,-112),
              Texture= "_ashe 3x2.png",
            },
          },
          Def.Sprite{
            Name= "actor_iw",
            FinalEndMessageCommand= cmd(visible,true),
            OnCommand= cmd(x,90;y,-220;visible,false),
            Texture= "ashesplat.png",
          },
          Def.Sprite{
            Name= "actor_jw",
            FinalEndMessageCommand= cmd(visible,true;setstate,4;x,96;addy,-120;sleep,2;linear,1.5;addy,60;sleep,0.5;queuecommand,"Flop"),
            FinaleStartMessageCommand= cmd(visible,false),
            FlopCommand= function(self) self:rotationz(90); self:addx(-20); self:addy(-60); Sound('bonk'); end,
            OnCommand= cmd(animate,0;setstate,3;vertalign,bottom),
            Texture= "_ashe 3x2.png",
          },
        },
        Def.Sprite{
          Name= "actor_kw",
          FinalEndMessageCommand= cmd(visible,true),
          OnCommand= cmd(visible,false;x,175-320+48;y,95+140;zoomto,76,145),
          Texture= "doorback.png",
        },
        Def.Sprite{
          Name= "actor_lw",
          FinalEndMessageCommand= cmd(visible,true;sleep,1;queuecommand,"Realize"),
          OnCommand= cmd(animate,0;setstate,0;visible,false;zoom,0.35;x,175-320+48;y,95+144),
          RealizeCommand= cmd(setstate,1;zoom,0.37;linear,0.2;zoom,0.35),
          Texture= "ayaze 2x1.png",
        },
        Def.ActorFrame{
          Name= "actor_mw",
          FOV= 80,
          VanishX= 320,
          VanishY= 480*.25,
          Def.ActorFrame{
            Name= "actor_nw",--Did a *(SCREEN_WIDTH/640). -Kid
            FinalEndMessageCommand= cmd(visible,true;rotationy,180;decelerate,1;rotationy,50*(SCREEN_WIDTH/640)),
            OnCommand= cmd(visible,false;x,175-320;y,95+140),
            Def.Model{
              Name= "actor_ow",
              Bones= "doormodel.txt",
              Materials= "doormodel.txt",
              Meshes= "doormodel.txt",--zoomy -> zoomz; zoomz -> zoomy
              OnCommand= cmd(x,38;zoomx,76/50;zoomz,145/50;zoomy,5/50;rotationx,-90),
            },
          },
        },
      },
      Def.Quad{
        Name= "actor_pw",
        DisplayFinalScoresMessageCommand= cmd(linear,1;diffusealpha,.7),
        OnCommand= cmd(x,0;y,360;cropleft,0.32;zoomto,640,240;diffuse,color('0,0,0,0')),
      },
      Def.BitmapText{
        Name= "actor_qw",
        DisplayFinalScoresMessageCommand= function(self)
			local pn = 2
			ret = ''
			ret = ret..'Steps: '..mawaru_sscore[pn]..'%\n'
			--ret = ret..'Games (total): +'..mawaru_score[pn]..'%\n\n'
			ret = ret..'Games (total): +'..string.format("%.2f", mawaru_score[pn])..'%\n\n'--Round it down to two decimal places, please. -Kid
			ret = ret..'Lives saved: '..mawaru_lives_saved[pn]..' (+'..mawaru_lives_bonus[pn]..'%)\n'
			self:settext(ret);
			self:diffusealpha(0);
			self:linear(1);
			self:diffusealpha(1);
		end,
        Font= "_eurostile outline",
        OnCommand= cmd(shadowlength,0;x,20;y,360;zoom,0.8;diffuse,color('.8,.8,1,1')),
        Text= "",
      },
      Def.BitmapText{
        Name= "actor_rw",
        DisplayFinalScoresMessageCommand= function(self)
			local pn = 2
			local nuenum = 0;
			if mawaru_difficulty[pn] ~= -1 then
				nuenum = mawaru_nue_numhidden[ mawaru_difficulty[pn]+1 ]
			end
			ret = ''
			ret = ret..'Misc: +'..mawaru_misc_score[pn]..'%\n'
			ret = ret..'Nue: '..mawaru_nue_score[pn]..'/'..nuenum..' (+'..mawaru_nue_scoreb[pn]..'%)\n'
			ret = ret..'BodyMagic: +'..mawaru_body_score[pn]..'%\n'
			ret = ret..'Blomby: +'..mawaru_blomby_score[pn]..'%\n'
			local volley = tostring(mawaru_mmm_lives[pn])
			if mawaru_mmm_lives[pn] == 1 then
				volley = '1 ball'
			else
				volley = mawaru_mmm_lives[pn]..' balls'
			end
			ret = ret..'Volley: '..volley..' (+'..mawaru_mmm_score[pn]..'%)\n'
			ret = ret..'LISA: '..mawaru_lisa_score[pn]..'m (+'..mawaru_lisa_scoreb[pn]..'%)\n'
			ret = ret..'Hadoukens: +'..mawaru_sf_scoreb[pn]..'%\n'
			local final = string.format('%.2f',(mawaru_finale_score[pn]*100))
			ret = ret..'Finale: '..final..'% '
			if mawaru_finale_score[pn] >= 0 then
				ret = ret..' (+'..string.format('%.2f',(mawaru_finale_score[pn]*20))..'%)'
			else
				ret = ret..' ('..string.format('%.2f',(mawaru_finale_score[pn]*20))..'%)'
			end
			self:settext(ret);
			self:diffusealpha(0);
			self:linear(1);
			self:diffusealpha(1);
		end,
        Font= "_eurostile outline",
        OnCommand= cmd(shadowlength,0;x,220;y,360;zoom,0.6;diffuse,color('.8,.8,1,1')),
        Text= "",
      },
    },
    --For all P1 parts, Unconverted x & y pos. -Kid
    Def.ActorFrame{
      Name= "actor_sw",
      OnCommand= cmd(ztest,1),
      RotateLastGameMessageCommand= cmd(playcommand,"DoRotate"),
      Def.ActorFrame{
        Name= "actor_tw",
        DoRotateCommand= cmd(accelerate,mawaru_finale_rtime;rotationz,45;decelerate,mawaru_finale_rtime;rotationz,90),
        OnCommand= cmd(x,320;y,240),
        Def.Quad{
          Name= "actor_uw",
          OnCommand= cmd(blend,"BlendMode_NoEffect";zwrite,1;horizalign,left;zoomto,960,960),
        },
      },
      Def.ActorFrame{
        Name= "actor_vw",
        DoRotateCommand= cmd(playcommand,"DR2";accelerate,mawaru_finale_rtime;addy,-70;decelerate,mawaru_finale_rtime;addy,-70),
        OnCommand= cmd(x,320),
        Def.Sprite{
          Name= "actor_ww",
          InitCommand= function(self) mawaru_finale_wallp1 = self end,
          OnCommand= cmd(x,160;y,150-40;zoomto,2560,400;customtexturerect,0,0,4,1),
          StopCommand= cmd(texcoordvelocity,0,0),
          Texture= "wall.png",
        },
        Def.ActorFrame{
          Name= "actor_xw",
          FOV= 80,
          VanishX= 320,
          VanishY= 480*.25,
          Def.Sprite{
            Name= "actor_yw",
            DR2Command= cmd(accelerate,mawaru_finale_rtime;rotationx,-30;addy,-19;decelerate,mawaru_finale_rtime;rotationx,-60;addy,-19),
            InitCommand= function(self) mawaru_finale_floorp1 = self end,
            OnCommand= cmd(x,160;y,360+40;rotationx,0;zoomto,2560,180;customtexturerect,0,0,4,1),
            StopCommand= cmd(texcoordvelocity,0,0),
            Texture= "floor.png",--This got expanded to floortexside by accident. -Kid
          },
        },
        Def.Sprite{
          Name= "actor_zw",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_Aw",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_Bw",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_Cw",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_Dw",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_Ew",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_Fw",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_ax",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[1],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "smallbox.png",
        },
        Def.Sprite{
          Name= "actor_bx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_cx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_dx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_ex",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_fx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_gx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_hx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_ix",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[2],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "airbox.png",
        },
        Def.Sprite{
          Name= "actor_jx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_kx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_lx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_mx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_nx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_ox",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_px",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.Sprite{
          Name= "actor_qx",
          OnCommand= cmd(visible,false;sleep,0.02;queuecommand,"SetMe"),
          SetMeCommand= function(self) table.insert(mawaru_finale_p1a[3],{actor=self,active=false,targ=0,col=0}); end,
          Texture= "jon 13x1.png",
        },
        Def.ActorFrame{
          Name= "actor_rx",
          InitCommand= function(self) mawaru_finale_p1 = self end,
          OnCommand= cmd(x,-160;y,350;basezoomx,-1;zoom,0.5),
          Def.ActorFrame{
            Name= "actor_sx",
            FinHurtP1MessageCommand= cmd(stoptweening;visible,false;sleep,0.4*fspd;queuecommand,"Unhide"),
            FinalEndMessageCommand= cmd(visible,false),
            FinaleStartMessageCommand= cmd(visible,true),
            OnCommand= cmd(visible,false),
            UnhideCommand= cmd(visible,true),
            Def.Sprite{
              Name= "actor_tx",
              Frames= {
                {Frame= 1, Delay= 0.4},
                {Frame= 0, Delay= 0.5},
                {Frame= 2, Delay= 0.5},
                {Frame= 0, Delay= 0.5},
                {Frame= 1, Delay= 0.1},
            },
              FinDuckP1MessageCommand= cmd(finishtweening;diffusealpha,0;sleep,0.3*fspd;diffusealpha,1),
              FinJumpP1MessageCommand= cmd(finishtweening;diffusealpha,0;sleep,0.3*fspd;diffusealpha,1),
              OnCommand= cmd(effectclock,"bgm";vertalign,bottom),
              Texture= "./_chan 3x2.png",
            },
            Def.Sprite{
              Name= "actor_ux",
              FinDuckP1MessageCommand= cmd(finishtweening;diffusealpha,0),
              FinJumpP1MessageCommand= cmd(finishtweening;diffusealpha,1;y,-150;linear,0.1*fspd;y,-180;accelerate,0.2*fspd;y,-20;sleep,0;diffusealpha,0),
              OnCommand= cmd(diffusealpha,0;animate,0;setstate,1;vertalign,bottom),
              Texture= "_chan 3x2.png",
            },
            Def.Sprite{
              Name= "actor_vx",
              FinDuckP1MessageCommand= cmd(finishtweening;diffusealpha,1;zoomy,1;decelerate,0.15*fspd;zoomy,0.8;accelerate,0.15*fspd;zoomy,1;sleep,0;diffusealpha,0),
              FinJumpP1MessageCommand= cmd(finishtweening;diffusealpha,0),
              OnCommand= cmd(diffusealpha,0;vertalign,bottom),
              Texture= "chanslide.png",
            },
          },
          Def.ActorFrame{
            Name= "actor_wx",
            FinHurtP1MessageCommand= cmd(stoptweening;playcommand,"H";visible,true;sleep,0.4*fspd;queuecommand,"Hide"),
            FinalEndMessageCommand= cmd(visible,false),
            HideCommand= cmd(visible,false),
            OnCommand= cmd(visible,false),
            Def.Sprite{
              Name= "actor_xx",
              HCommand= cmd(finishtweening;rotationz,0;linear,0.4*fspd;rotationz,360;sleep,0;rotationz,0),
              OnCommand= cmd(animate,0;setstate,5;y,-112),
              Texture= "_chan 3x2.png",
            },
          },
          Def.Sprite{
            Name= "actor_yx",
            FinalEndMessageCommand= cmd(visible,true),
            OnCommand= cmd(x,90;y,-220;visible,false),
            Texture= "chansplat.png",
          },
          Def.Sprite{
            Name= "actor_zx",
            FinalEndMessageCommand= cmd(visible,true;setstate,4;x,90;addy,-110;sleep,2;linear,1.5;addy,60;sleep,0.5;queuecommand,"Flop"),
            FinaleStartMessageCommand= cmd(visible,false),
            FlopCommand= function(self) self:rotationz(90); self:addx(-20); self:addy(-70); end,
            OnCommand= cmd(animate,0;setstate,3;vertalign,bottom),
            Texture= "_chan 3x2.png",
          },
        },
        Def.Sprite{
          Name= "actor_Ax",
          FinalEndMessageCommand= cmd(visible,true),
          OnCommand= cmd(visible,false;x,175-320+48;y,95+140;zoomto,76,145),
          Texture= "doorback.png",
        },
        Def.Sprite{
          Name= "actor_Bx",
          FinalEndMessageCommand= cmd(visible,true;sleep,1;queuecommand,"Realize"),
          OnCommand= cmd(animate,0;setstate,0;visible,false;zoom,0.35;x,175-320+48;y,95+144),
          RealizeCommand= cmd(setstate,1;zoom,0.37;linear,0.2;zoom,0.35),
          Texture= "ayaze 2x1.png",
        },
        Def.ActorFrame{
          Name= "actor_Cx",
          FOV= 80,
          VanishX= 320,
          VanishY= 480*.25,
          Def.ActorFrame{
            Name= "actor_Dx",--Did a *(SCREEN_WIDTH/640). -Kid
            FinalEndMessageCommand= cmd(visible,true;rotationy,180;decelerate,1;rotationy,50*(SCREEN_WIDTH/640)),
            OnCommand= cmd(visible,false;x,175-320;y,95+140),
            Def.Model{
              Name= "actor_Ex",
              Bones= "doormodel.txt",
              Materials= "doormodel.txt",
              Meshes= "doormodel.txt",--zoomy -> zoomz; zoomz -> zoomy
              OnCommand= cmd(x,38;zoomx,76/50;zoomz,145/50;zoomy,5/50;rotationx,-90),
            },
          },
        },
      },
      Def.Quad{
        Name= "actor_Fx",
        DisplayFinalScoresMessageCommand= cmd(linear,1;diffusealpha,.7),
        OnCommand= cmd(x,320;y,120;cropleft,0.32;zoomto,640,240;diffuse,color('0,0,0,0')),
      },
      Def.BitmapText{
        Name= "actor_ay",
        DisplayFinalScoresMessageCommand= function(self)
			local pn = 1
			ret = ''
			ret = ret..'Steps: '..mawaru_sscore[pn]..'%\n'
			--ret = ret..'Games (total): +'..mawaru_score[pn]..'%\n\n'
			ret = ret..'Games (total): +'..string.format("%.2f", mawaru_score[pn])..'%\n\n'--Round it down to two decimal places, please. -Kid
			ret = ret..'Lives saved: '..mawaru_lives_saved[pn]..' (+'..mawaru_lives_bonus[pn]..'%)\n'
			self:settext(ret);
			self:diffusealpha(0);
			self:linear(1);
			self:diffusealpha(1);
		end,
        Font= "_eurostile outline",
        OnCommand= cmd(shadowlength,0;x,340;y,120;zoom,0.8;diffuse,color('1,.8,.8,1')),
        Text= "",
      },
      Def.BitmapText{
        Name= "actor_by",
        DisplayFinalScoresMessageCommand= function(self)
			local pn = 1;
			local nuenum = 0;
			if mawaru_difficulty[pn] ~= -1 then
				nuenum = mawaru_nue_numhidden[ mawaru_difficulty[pn]+1 ]
			end
			ret = ''
			ret = ret..'Misc: +'..mawaru_misc_score[pn]..'%\n'
			ret = ret..'Nue: '..mawaru_nue_score[pn]..'/'..nuenum..' (+'..mawaru_nue_scoreb[pn]..'%)\n'
			ret = ret..'BodyMagic: +'..mawaru_body_score[pn]..'%\n'
			ret = ret..'Blomby: +'..mawaru_blomby_score[pn]..'%\n'
			local volley = tostring(mawaru_mmm_lives[pn])
			if mawaru_mmm_lives[pn] == 1 then
				volley = '1 ball'
			else
				volley = mawaru_mmm_lives[pn]..' balls'
			end
			ret = ret..'Volley: '..volley..' (+'..mawaru_mmm_score[pn]..'%)\n'
			ret = ret..'LISA: '..mawaru_lisa_score[pn]..'m (+'..mawaru_lisa_scoreb[pn]..'%)\n'
			ret = ret..'Hadoukens: +'..mawaru_sf_scoreb[pn]..'%\n'
			local final = string.format('%.2f',(mawaru_finale_score[pn]*100))
			ret = ret..'Finale: '..final..'% '
			if mawaru_finale_score[pn] >= 0 then
				ret = ret..' (+'..string.format('%.2f',(mawaru_finale_score[pn]*20))..'%)'
			else
				ret = ret..' ('..string.format('%.2f',(mawaru_finale_score[pn]*20))..'%)'
			end
			self:settext(ret);
			self:diffusealpha(0);
			self:linear(1);
			self:diffusealpha(1);
		end,
        Font= "_eurostile outline",
        OnCommand= cmd(shadowlength,0;x,540;y,120;zoom,0.6;diffuse,color('1,.8,.8,1')),
        Text= "",
      },
    },
    --For misc parts, Unconverted x & y pos. -Kid
    Def.ActorFrame{
      Name= "actor_cy",
      OnCommand= cmd(x,320;y,240),
      RotateLastGameMessageCommand= cmd(accelerate,mawaru_finale_rtime;rotationz,45;decelerate,mawaru_finale_rtime;rotationz,90),
      Def.Quad{
        Name= "actor_dy",
        OnCommand= cmd(zoomto,6,960;diffuse,color('0,0,0,1')),
      },
    },
    Def.ActorFrame{
      Name= "actor_ey",
      OnCommand= cmd(x,320;y,240),
      RotateLastGameMessageCommand= cmd(accelerate,mawaru_finale_rtime;rotationz,45;decelerate,mawaru_finale_rtime;rotationz,90),
      optional_actor(cond_wu_result,
      Def.Quad{
        Name= "actor_fy",
        OnCommand= cmd(zoomto,960,960;horizalign,right;diffuse,color('0,0,0,1')),
      }),
      optional_actor(cond_xu_result,
      Def.Quad{
        Name= "actor_gy",
        OnCommand= cmd(zoomto,960,960;horizalign,left;diffuse,color('0,0,0,1')),
      }),
    },
    optional_actor(cond_yu_result,
    Def.BitmapText{
      Name= "actor_hy",
      FinUpdateScoreP1MessageCommand= function (self) self:settext('score: '..string.format('%.2f',mawaru_finale_score[1]*100)..'%'); end,
      Font= "_eurostile outline",
      OnCommand= cmd(shadowlength,0;x,30;y,30;horizalign,left;vertalign,top),
      Text= "",
    }),
    optional_actor(cond_zu_result,
    Def.BitmapText{
      Name= "actor_iy",
      FinUpdateScoreP2MessageCommand= function (self) self:settext('score: '..string.format('%.2f',mawaru_finale_score[2]*100)..'%'); end,
      Font= "_eurostile outline",
      OnCommand= cmd(shadowlength,0;x,30;y,240+30;horizalign,left;vertalign,top),
      Text= "",
    }),
    Def.Sprite{
      Name= "actor_jy",
      FinalTextOffMessageCommand= cmd(linear,1;diffusealpha,0),--Reverse-converted x & y pos. -Kid
      OnCommand= cmd(diffusealpha,0;zoom,3;vibrate;effectmagnitude,1,1,1;x,320;y,240),
      StartCommand= cmd(finishtweening;diffusealpha,0;zoom,3;linear,0.3;zoom,1;diffusealpha,1;sleep,60*12/200;linear,0.3;zoom,0.6;diffusealpha,.6;sleep,2.5),
      Texture= "inst.png",
    },
  },
}
