ScreenSandbox is a scratchpad; wipe it

This commit is contained in:
Glenn Maynard
2004-01-11 03:06:47 +00:00
parent dc863c8f31
commit 1d7983cdaa
2 changed files with 4 additions and 89 deletions
+2 -62
View File
@@ -9,9 +9,7 @@
scratchpad. scratchpad.
Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved. Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved.
Chris Danford (there is no actual code here)
Glenn Maynard (OpenGL Code)
Lance Gilbert (OpenGL/Usability Modifications)
----------------------------------------------------------------------------- -----------------------------------------------------------------------------
*/ */
@@ -24,50 +22,15 @@
ScreenSandbox::ScreenSandbox( CString sClassName ) : Screen( sClassName ) ScreenSandbox::ScreenSandbox( CString sClassName ) : Screen( sClassName )
{ {
// m_quad1.StretchTo( RectI(SCREEN_LEFT, SCREEN_TOP, SCREEN_RIGHT, SCREEN_BOTTOM) );
// m_quad1.SetDiffuse( RageColor(0,0,1,1) );
// m_quad1.SetZ( 0 );
// m_quad1.SetUseZBuffer( true );
// this->AddChild( &m_quad1 );
// m_quad2.StretchTo( RectI(SCREEN_LEFT, SCREEN_TOP, SCREEN_RIGHT, SCREEN_BOTTOM) );
// m_quad2.SetDiffuse( RageColor(0,1,0,1) );
// m_quad2.SetZ( -1 );
// m_quad2.SetUseZBuffer( true );
// this->AddChild( &m_quad2 );
// m_sprite.Load( "C:\\stepmania\\stepmania\\RandomMovies\\cm301[1].avi" );
// m_sprite.SetXY( CENTER_X, CENTER_Y );
// this->AddChild( &m_sprite );
//m_model.LoadMilkshapeAscii( "C:\\stepmania\\stepmania\\Themes\\groove\\BGAnimations\\ScreenCaution background\\2 platforms and backbar.txt" );
m_model.LoadMilkshapeAscii( "Characters/DancePads-DDR.txt" );
m_model.SetXY(CENTER_X, CENTER_Y);
m_model.SetRotationX( 15 );
m_model.SetZoom(5);
this->AddChild(&m_model);
// this->AddChild( &m_In );
// this->AddChild( &m_Out );
} }
void ScreenSandbox::HandleScreenMessage( const ScreenMessage SM ) void ScreenSandbox::HandleScreenMessage( const ScreenMessage SM )
{ {
Screen::HandleScreenMessage( SM );
} }
void ScreenSandbox::Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI ) void ScreenSandbox::Input( const DeviceInput& DeviceI, const InputEventType type, const GameInput &GameI, const MenuInput &MenuI, const StyleInput &StyleI )
{ {
if( DeviceI.button == SDLK_LEFT )
m_model.SetRotationY( m_model.GetRotationY()+5 );
if( DeviceI.button == SDLK_DOWN )
m_model.SetRotationX( m_model.GetRotationX()+5 );
if( DeviceI.button == SDLK_UP )
m_model.SetRotationX( m_model.GetRotationX()-5 );
if( DeviceI.button == SDLK_RIGHT )
m_model.SetRotationY( m_model.GetRotationY()-5 );
Screen::Input( DeviceI, type, GameI, MenuI, StyleI ); Screen::Input( DeviceI, type, GameI, MenuI, StyleI );
} }
@@ -78,28 +41,5 @@ void ScreenSandbox::Update( float fDeltaTime )
void ScreenSandbox::DrawPrimitives() void ScreenSandbox::DrawPrimitives()
{ {
DISPLAY->SetLighting( true );
DISPLAY->SetLightDirectional(
0,
RageColor(0.5,0.5,0.5,1),
RageColor(1,1,1,1),
RageColor(0,0,0,1),
RageVector3(0, 0, 1) );
Screen::DrawPrimitives(); Screen::DrawPrimitives();
DISPLAY->SetLightOff( 0 );
DISPLAY->SetLighting( false );
}
void ScreenSandbox::MenuLeft( PlayerNumber pn )
{
// m_In.Load( THEME->GetPathToB("_menu in") );
// m_In.StartTransitioning();
}
void ScreenSandbox::MenuRight( PlayerNumber pn )
{
// m_Out.Load( THEME->GetPathToB("_menu out") );
// m_Out.StartTransitioning();
} }
+2 -27
View File
@@ -1,20 +1,7 @@
#ifndef SCREENSANDBOX_H #ifndef SCREEN_SANDBOX_H
#define SCREENSANDBOX_H #define SCREEN_SANDBOX_H
/*
-----------------------------------------------------------------------------
Class: ScreenSandbox
Desc: Area for testing.
Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved.
Chris Danford
-----------------------------------------------------------------------------
*/
#include "Screen.h" #include "Screen.h"
#include "Model.h"
#include "Quad.h"
#include "Transition.h"
class ScreenSandbox : public Screen class ScreenSandbox : public Screen
{ {
@@ -25,18 +12,6 @@ public:
virtual void HandleScreenMessage( const ScreenMessage SM ); virtual void HandleScreenMessage( const ScreenMessage SM );
virtual void Update(float f); virtual void Update(float f);
virtual void DrawPrimitives(); virtual void DrawPrimitives();
void MenuLeft( PlayerNumber pn );
void MenuRight( PlayerNumber pn );
Model m_model;
// Quad m_quad1;
// Quad m_quad2;
// Transition m_In;
// Transition m_Out;
// Sprite m_text;
}; };
#endif #endif