require( "scripts/style" );

kButtonSpacing = 60;	-- Put our buttons 60 pixels apart
kButtonY = kCenter-60;	-- Three buttons means center 60 pixels above the center

SetState( kPause, true );

HeaderFont = {
  standardFont,
  70,
  BlueColor
};


MakeDialog
{
	-- Name the modal dialog
	name="endstage",
	Bitmap
	{
		image="backgrounds/dialog",
		x=kCenter,
		y=kCenter,

		SetStyle(ButtonStyle),
		
		Text
		{
			font = HeaderFont,
			name = "gameover",
			x=0,y=20,w=kMax,h=30,
			flags = kHAlignCenter + kVAlignTop,
			label = "gameover"
		};
		
		Button
		{
			x=kCenter,
			y=kButtonY + (kButtonSpacing * 2),
			label="quit",
			command=
				function()
					PopModal('endstage');
					--DoModal('scripts/gameover.lua');
					-- Our game processes this message--it's not
					-- handled by Playground
                    SendGameMessage( "quit" );
	                SetState( kPause, false );
				end
		},
	},
}