local gc = Var("GameCommand");

local iIndex = gc:GetIndex();
local sName = gc:GetName();
local sGameName = GAMESTATE:GetCurrentGame():GetName();

local t = Def.ActorFrame{
	Name="Item"..iIndex;
	InitCommand=cmd(fov,90;x,SCREEN_CENTER_X;y,THEME:GetMetric("ScreenSelectPlayMode","IconChoice".. sName .."Y"));

	OffFocusedCommand=cmd(linear,0.2;y,SCREEN_CENTER_Y);
	OffUnfocusedCommand=cmd(runcommandsonleaves,cmd(linear,0.2;diffusealpha,0));

	-- x was SCREEN_WIDTH*0.625
	LoadActor( THEME:GetPathB("","_frame 3x3"), "_rounded blackinset transparent normal", 400, 64)..{
		Name="BGFrame";
		GainFocusCommand=cmd(finishtweening;linear,0.2;diffuse,color("1,1,1,1"));
		LoseFocusCommand=cmd(linear,0.2;diffuse,color("0.5,0.5,0.5,1"););
	};

	LoadActor("_preview "..sName)..{
		InitCommand=cmd(x,-160);
		GainFocusCommand=cmd(finishtweening;linear,0.2;diffuse,color("1,1,1,1"););
		LoseFocusCommand=cmd(linear,0.2;diffuse,color("0.5,0.5,0.5,1"););
	};

	AutoText("frutiger")..{
		Name="ModeName"..iIndex;
		Text=THEME:GetString(Var 'LoadingScreen',sName);
		InitCommand=cmd(x,-100;y,-10;horizalign,left;shadowlength,0;strokecolor,color("0,0,0,0.25"));
		GainFocusCommand=cmd(finishtweening;linear,0.2;diffuse,color("1,1,1,1"););
		LoseFocusCommand=cmd(linear,0.2;diffuse,color("0.5,0.5,0.5,1"););
	};
	AutoText("frutiger")..{
		Name="ModeDesc"..iIndex;
		Text=THEME:GetString(Var 'LoadingScreen',sName.."Desc");
		InitCommand=cmd(x,-100;y,10;horizalign,left;shadowlength,0;zoom,0.8;strokecolor,color("0,0,0,0.25"));
		GainFocusCommand=cmd(finishtweening;linear,0.2;diffuse,color("1,1,1,1"););
		LoseFocusCommand=cmd(linear,0.2;diffuse,color("0.5,0.5,0.5,1"););
	};
};

return t;