2002-05-20 08:59:37 +00:00
|
|
|
#include "stdafx.h"
|
|
|
|
|
/*
|
|
|
|
|
-----------------------------------------------------------------------------
|
|
|
|
|
File: ScreenSandbox.h
|
|
|
|
|
|
|
|
|
|
Desc: Area for testing.
|
|
|
|
|
|
|
|
|
|
Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved.
|
|
|
|
|
-----------------------------------------------------------------------------
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#include "ScreenSandbox.h"
|
|
|
|
|
#include "ScreenManager.h"
|
|
|
|
|
#include "RageMusic.h"
|
|
|
|
|
#include "GameConstantsAndTypes.h"
|
2002-07-23 01:41:40 +00:00
|
|
|
#include "PrefsManager.h"
|
2002-05-20 08:59:37 +00:00
|
|
|
#include "Quad.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ScreenSandbox::ScreenSandbox()
|
|
|
|
|
{
|
2002-10-28 05:30:45 +00:00
|
|
|
m_text.LoadFromFont( THEME->GetPathTo("Fonts","normal") );
|
|
|
|
|
m_text.SetXY( CENTER_X, CENTER_Y );
|
|
|
|
|
m_text.SetText( "Press Left to Become Server\nRight to become Client." );
|
|
|
|
|
this->AddChild( &m_text );
|
2002-07-23 01:41:40 +00:00
|
|
|
|
2002-08-13 23:26:46 +00:00
|
|
|
// m_Menu.Load(
|
|
|
|
|
// THEME->GetPathTo(GRAPHIC_SELECT_STYLE_BACKGROUND),
|
|
|
|
|
// THEME->GetPathTo(GRAPHIC_SELECT_STYLE_TOP_EDGE),
|
|
|
|
|
// ssprintf("Use %c %c to select, then press START", char(1), char(2) ),
|
|
|
|
|
// false, true, 40
|
|
|
|
|
// );
|
2002-09-02 21:59:58 +00:00
|
|
|
// this->AddChild( &m_Menu );
|
2002-08-13 23:26:46 +00:00
|
|
|
// m_Menu.TweenOnScreenFromBlack( SM_None );
|
2002-05-20 08:59:37 +00:00
|
|
|
|
2002-09-02 21:59:58 +00:00
|
|
|
//this->AddChild( &m_spr );
|
2002-05-20 08:59:37 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void ScreenSandbox::Update( float fDeltaTime )
|
|
|
|
|
{
|
|
|
|
|
Screen::Update( fDeltaTime );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ScreenSandbox::DrawPrimitives()
|
|
|
|
|
{
|
|
|
|
|
Screen::DrawPrimitives();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ScreenSandbox::Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI )
|
|
|
|
|
{
|
2002-10-28 05:30:45 +00:00
|
|
|
if( type != IET_FIRST_PRESS )
|
|
|
|
|
return; // ignore
|
|
|
|
|
|
|
|
|
|
switch( DeviceI.device)
|
2002-05-20 08:59:37 +00:00
|
|
|
{
|
2002-10-28 05:30:45 +00:00
|
|
|
case DEVICE_KEYBOARD:
|
|
|
|
|
switch( DeviceI.button )
|
2002-05-20 08:59:37 +00:00
|
|
|
{
|
2002-10-28 05:30:45 +00:00
|
|
|
case DIK_LEFT:
|
|
|
|
|
m_text.SetText( "You are the server." );
|
2002-05-20 08:59:37 +00:00
|
|
|
break;
|
2002-10-28 05:30:45 +00:00
|
|
|
case DIK_RIGHT:
|
|
|
|
|
m_text.SetText( "You are the client." );
|
|
|
|
|
break;
|
|
|
|
|
case DIK_T:
|
2002-05-20 08:59:37 +00:00
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// m_sprBG.SetEffectCamelion( 5, D3DXCOLOR(1,0.8f,0.8f,1), D3DXCOLOR(1,0.2f,0.2f,1) );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void ScreenSandbox::HandleScreenMessage( const ScreenMessage SM )
|
|
|
|
|
{
|
|
|
|
|
switch( SM )
|
|
|
|
|
{
|
|
|
|
|
case SM_DoneClosingWipingLeft:
|
|
|
|
|
break;
|
|
|
|
|
case SM_DoneClosingWipingRight:
|
|
|
|
|
break;
|
|
|
|
|
case SM_DoneOpeningWipingLeft:
|
|
|
|
|
break;
|
|
|
|
|
case SM_DoneOpeningWipingRight:
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
}
|