diff --git a/stepmania/Characters/Instructions.txt b/stepmania/Characters/Instructions.txt new file mode 100644 index 0000000000..e69de29bb2 diff --git a/stepmania/Courses/AllChallenge.crs b/stepmania/Courses/Samples/AllChallenge.crs similarity index 100% rename from stepmania/Courses/AllChallenge.crs rename to stepmania/Courses/Samples/AllChallenge.crs diff --git a/stepmania/Courses/AllMusicRandom.crs b/stepmania/Courses/Samples/AllMusicRandom.crs similarity index 100% rename from stepmania/Courses/AllMusicRandom.crs rename to stepmania/Courses/Samples/AllMusicRandom.crs diff --git a/stepmania/Courses/Samples/EndOfTheRoad.crs b/stepmania/Courses/Samples/EndOfTheRoad.crs new file mode 100644 index 0000000000..562cb4a5a3 --- /dev/null +++ b/stepmania/Courses/Samples/EndOfTheRoad.crs @@ -0,0 +1,10 @@ +#COURSE:End of the Road; +#LIVES:4; +#SONG:*:7..7:1.5x,reverse; +#SONG:*:7..7:expand; +#SONG:*:8..8:0.25x; +#SONG:*:8..8:hidden,boost; +#SONG:*:9..9:3.0x,dark,reverse; +#SONG:*:9..9:land,big,supershuffle; +#SONG:*:10..10:1.2xmusic,dizzy,drunk; +#SONG:*:10..10:tornado,shuffle,dark; \ No newline at end of file diff --git a/stepmania/Courses/PlayersBest1-4.crs b/stepmania/Courses/Samples/PlayersBest1-4.crs similarity index 100% rename from stepmania/Courses/PlayersBest1-4.crs rename to stepmania/Courses/Samples/PlayersBest1-4.crs diff --git a/stepmania/Courses/PlayersBest13-16.crs b/stepmania/Courses/Samples/PlayersBest13-16.crs similarity index 100% rename from stepmania/Courses/PlayersBest13-16.crs rename to stepmania/Courses/Samples/PlayersBest13-16.crs diff --git a/stepmania/Courses/PlayersBest5-8.crs b/stepmania/Courses/Samples/PlayersBest5-8.crs similarity index 100% rename from stepmania/Courses/PlayersBest5-8.crs rename to stepmania/Courses/Samples/PlayersBest5-8.crs diff --git a/stepmania/Courses/PlayersBest9-12.crs b/stepmania/Courses/Samples/PlayersBest9-12.crs similarity index 100% rename from stepmania/Courses/PlayersBest9-12.crs rename to stepmania/Courses/Samples/PlayersBest9-12.crs diff --git a/stepmania/Courses/PlayersWorst.crs b/stepmania/Courses/Samples/PlayersWorst.crs similarity index 100% rename from stepmania/Courses/PlayersWorst.crs rename to stepmania/Courses/Samples/PlayersWorst.crs diff --git a/stepmania/Courses/StaminaTester.crs b/stepmania/Courses/Samples/StaminaTester.crs similarity index 100% rename from stepmania/Courses/StaminaTester.crs rename to stepmania/Courses/Samples/StaminaTester.crs diff --git a/stepmania/Courses/Tortoise and the Hare.crs b/stepmania/Courses/Samples/Tortoise and the Hare.crs similarity index 100% rename from stepmania/Courses/Tortoise and the Hare.crs rename to stepmania/Courses/Samples/Tortoise and the Hare.crs diff --git a/stepmania/Courses/TrickyRandom.crs b/stepmania/Courses/Samples/TrickyRandom.crs similarity index 100% rename from stepmania/Courses/TrickyRandom.crs rename to stepmania/Courses/Samples/TrickyRandom.crs diff --git a/stepmania/NEWS b/stepmania/NEWS index c1c4d82274..c230b8b623 100644 --- a/stepmania/NEWS +++ b/stepmania/NEWS @@ -37,6 +37,11 @@ NEW FEATURE: Convert a theme from the 3.0 naming convention to the 4.0 naming convention using "Analyze Theme" in smpackage.exe. NEW FEATURE: Check for redundant and possibly mis-named theme elements using "Analyze Theme" in smpackage.exe. +NEW FEATURE: PlayerOption: Perspective - Incoming +NEW FEATURE: Set default player and song options in stepmania.ini using + DefaultModifiers. +NEW FEATURE: Courses can be organized into group folders. See + README-FIRST.html for details. ----------------------- Version 3.01 --------------------------- CHANGE: Simplified NoteSkin tap graphic format. Old NoteSkins will need to diff --git a/stepmania/README-FIRST.html b/stepmania/README-FIRST.html index 4fd682f5a8..75559535f1 100644 --- a/stepmania/README-FIRST.html +++ b/stepmania/README-FIRST.html @@ -11,8 +11,7 @@ http://www.stepmania.com


-Table of Contents -
+Table of Contents

About StepMania
@@ -45,9 +44,7 @@ See the file NEWS for version history.

-About StepMania
-
-
+About StepMania (top)

StepMania is capable of playing many game types. Currently, it supports games @@ -64,8 +61,7 @@ hand sensors.

-Minimum Requirements -
+Minimum Requirements (top)

* Windows 98, Windows ME, Windows 2000, or Windows XP
@@ -81,8 +77,7 @@ minimum (400 MHz recommended)

-DirectX -
+DirectX (top)

DirectX 8.0 is required before installing StepMania. If DirectX 8.0 is not @@ -92,8 +87,7 @@ abort the installation.

-Installation -
+Installation (top)

To install StepMania, download the file stepmania300.exe to a known location on @@ -104,8 +98,7 @@ present. The default installation directory is 'C:\Program Files\StepMania'.

-Controls -
+Controls (top)

Use the "Config Key/Joy" option from the Title Menu to configure your keyboard, @@ -165,8 +158,7 @@ In the music select screen:

-How StepMania Loads Songs -
+How StepMania Loads Songs (top)

All files for a specific song (data file, music file, banner, background) must @@ -205,8 +197,7 @@ background change to that movie at beat 0.

-Connecting Dance Pads -
+Connecting Dance Pads (top)

There are several devices that allow you to connect PlayStation dance pads to @@ -247,8 +238,7 @@ StepMania now natively supports USB Pump It Up pads.

-Compatibility Issues -
+Compatibility Issues (top)

Some video card/driver combinations have visual errors when running StepMania. @@ -278,8 +268,7 @@ bugs. Please upgrade to the latest drivers, which will hopefully fix the errors.

-FAQ / Troubleshooting -
+FAQ / Troubleshooting (top)

* The error "Cannot find Dinput8.dll" appears when launching the game.
@@ -311,8 +300,7 @@ make anyone angry if it takes longer than expected (it usually does).

-StepMania Packages - .smzip -
+StepMania Packages - .smzip (top)

The StepMania package format was created to make the distribution of songs and @@ -339,8 +327,7 @@ the list.

Questions, Bugs, Suggestions, -and Help -
+and Help (top)


If you have a question about or problem with StepMania, please first ask your @@ -371,8 +358,7 @@ or to Chris.

-The StepMania editor -
+The StepMania editor (top)

The StepMania editor allows you to edit, record, synchronize, and play back note @@ -396,8 +382,7 @@ the editor:

-The .SM file format -
+The .SM file format (top)

The .SM song file format was created to be one file format that supports all @@ -553,8 +538,7 @@ Example:

-Backgrounds -
+Backgrounds (top)

StepMania supports three different modes of backgrounds. The default background @@ -584,8 +568,7 @@ Sample animations, visualizations, and random movies can be found at

-BGAnimations Format -
+BGAnimations Format (top)

The BGAnimations folder in the StepMania program directory may contain several @@ -676,8 +659,7 @@ TilePulse,

-The .CRS File Format -
+The .CRS File Format (top)

CRS files define the courses used in the Nonstop, Oni, and Endless modes.  All CRS @@ -750,8 +732,7 @@ dark

-Extra Stages -
+Extra Stages (top)

You can manually specify extra stages for each song group by creating .CRS files @@ -767,8 +748,7 @@ Don't forget: extra stage CRS files belong in the song group folder (e.g.

-Creating an Announcer -
+Creating an Announcer (top)

Announcers folders must reside in the "Announcers" folder inside the StepMania @@ -789,8 +769,7 @@ that are available at www.stepmania.com.<

-Creating a Note Skin -
+Creating a Note Skin (top)

Note skins allow you to customize the way notes appear. Note skins must reside @@ -829,8 +808,7 @@ For more information on about textures with multiple frames, see the section

-Creating a Theme -
+Creating a Theme (top)

All themes must reside in the Themes folder below the StepMania program @@ -946,8 +924,7 @@ Graphics folder "Themes\MySuperTheme\Graphics".

-How StepMania Loads Textures -
+How StepMania Loads Textures (top)

* What are textures?
@@ -1026,9 +1003,8 @@ looks blurry.

-Building StepMania from CVS source - -
+Building StepMania from CVS source +(top)

CVS is the repository that manages the StepMania source code. Our CVS server is @@ -1156,11 +1132,9 @@ and put "ssh.bat" into the editbox.

-Thanks -
+Thanks (top)

-Thanks to:
redcrusher for help on ez2 graphics
Dj Slash & Tony Thai for the caution graphic
Kyle "KeeL" Ward for his awesome menu music (www.ampcast.com/keel)
@@ -1173,4 +1147,4 @@ Kyle "KeeL" Ward for his awesome menu music (www.ampcast.com/keel)
- + \ No newline at end of file diff --git a/stepmania/Themes/default/Fonts/_misc 16px.ini b/stepmania/Themes/default/Fonts/_misc 16px.ini index efce23f8f7..c38dfe0ec8 100644 --- a/stepmania/Themes/default/Fonts/_misc 16px.ini +++ b/stepmania/Themes/default/Fonts/_misc 16px.ini @@ -9,6 +9,7 @@ 9=4 10=20 11=4 +12=20 AddToAllWidths=2 @@ -26,3 +27,4 @@ map ←=8 map ↑=9 map →=10 map ↓=11 +map ☺=12 diff --git a/stepmania/Themes/default/Graphics/ScreenSelectPlayer header.png b/stepmania/Themes/default/Graphics/ScreenSelectPlayer header.png index 7523ad30fe..e647db51d1 100644 Binary files a/stepmania/Themes/default/Graphics/ScreenSelectPlayer header.png and b/stepmania/Themes/default/Graphics/ScreenSelectPlayer header.png differ diff --git a/stepmania/Themes/default/Graphics/_shared menu header.png b/stepmania/Themes/default/Graphics/_shared menu header.png index 21026e1838..40518d34d7 100644 Binary files a/stepmania/Themes/default/Graphics/_shared menu header.png and b/stepmania/Themes/default/Graphics/_shared menu header.png differ diff --git a/stepmania/Themes/default/metrics.ini b/stepmania/Themes/default/metrics.ini index 07a039cf7e..7693a2c562 100644 --- a/stepmania/Themes/default/metrics.ini +++ b/stepmania/Themes/default/metrics.ini @@ -157,45 +157,85 @@ NextScreen8=ScreenInstructions LockInputSeconds=0.8 SleepAfterChoiceSeconds=0.3 SleepAfterTweenOffSeconds=0.8 -MorePage1OnCommand=diffusealpha,0;x,580;y,90;linear,0.5;diffusealpha,1 +MorePage1X=580 +MorePage1Y=90 +MorePage1OnCommand=diffusealpha,0;linear,0.5;diffusealpha,1 MorePage1OffCommand=linear,0.5;diffusealpha,0 -MorePage2OnCommand=x,700;y,90 +MorePage2X=700 +MorePage2Y=90 +MorePage2OnCommand= MorePage2OffCommand=linear,0.5;diffusealpha,0 -ExplanationPage1OnCommand=x,170;y,70;addx,-400;bounceend,0.5;addx,400; +ExplanationPage1X=170 +ExplanationPage1Y=70 +ExplanationPage1OnCommand=addx,-400;bounceend,0.5;addx,400; ExplanationPage1OffCommand=bouncebegin,0.5;addx,-400 -ExplanationPage2OnCommand=x,1100;y,70 +ExplanationPage2X=1100 +ExplanationPage2Y=70 +ExplanationPage2OnCommand= ExplanationPage2OffCommand=bouncebegin,0.5;addx,400 -InfoPage1Choice1OnCommand=vertalign,bottom;x,98;y,180;addx,-800;sleep,0.0;decelerate,0.4;addx,800 +InfoPage1Choice1X=98 +InfoPage1Choice1Y=180 +InfoPage1Choice1OnCommand=vertalign,bottom;addx,-800;sleep,0.0;decelerate,0.4;addx,800 InfoPage1Choice1OffCommand=sleep,0.3;accelerate,0.4;addx,-800 -InfoPage1Choice2OnCommand=vertalign,bottom;x,246;y,220;addx,-800;sleep,0.2;decelerate,0.4;addx,800 +InfoPage1Choice2X=246 +InfoPage1Choice2Y=220 +InfoPage1Choice2OnCommand=vertalign,bottom;addx,-800;sleep,0.2;decelerate,0.4;addx,800 InfoPage1Choice2OffCommand=sleep,0.5;accelerate,0.4;addx,-800 -InfoPage1Choice3OnCommand=vertalign,bottom;x,394;y,180;addx,-800;sleep,0.4;decelerate,0.4;addx,800 +InfoPage1Choice3X=394 +InfoPage1Choice3Y=180 +InfoPage1Choice3OnCommand=vertalign,bottom;addx,-800;sleep,0.4;decelerate,0.4;addx,800 InfoPage1Choice3OffCommand=sleep,0.7;accelerate,0.4;addx,-800 -InfoPage1Choice4OnCommand=vertalign,bottom;x,542;y,220;addx,-800;sleep,0.6;decelerate,0.4;addx,800 +InfoPage1Choice4X=542 +InfoPage1Choice4Y=220 +InfoPage1Choice4OnCommand=vertalign,bottom;addx,-800;sleep,0.6;decelerate,0.4;addx,800 InfoPage1Choice4OffCommand=sleep,0.9;accelerate,0.4;addx,-800 -InfoPage2Choice1OnCommand=vertalign,bottom;x,738;y,220 +InfoPage2Choice1X=738 +InfoPage2Choice1Y=220 +InfoPage2Choice1OnCommand=vertalign,bottom InfoPage2Choice1OffCommand=sleep,0.3;accelerate,0.4;addx,-800 -InfoPage2Choice2OnCommand=vertalign,bottom;x,886;y,180 +InfoPage2Choice2X=886 +InfoPage2Choice2Y=180 +InfoPage2Choice2OnCommand=vertalign,bottom InfoPage2Choice2OffCommand=sleep,0.5;accelerate,0.4;addx,-800 -InfoPage2Choice3OnCommand=vertalign,bottom;x,1034;y,220 +InfoPage2Choice3X=1034 +InfoPage2Choice3Y=220 +InfoPage2Choice3OnCommand=vertalign,bottom InfoPage2Choice3OffCommand=sleep,0.7;accelerate,0.4;addx,-800 -InfoPage2Choice4OnCommand=vertalign,bottom;x,1182;y,180 +InfoPage2Choice4X=1182 +InfoPage2Choice4Y=180 +InfoPage2Choice4OnCommand=vertalign,bottom InfoPage2Choice4OffCommand=sleep,0.9;accelerate,0.4;addx,-800 -PicturePage1Choice1OnCommand=vertalign,top;x,98;y,180;zoomy,0.0;sleep,0.4;bounceend,0.3;zoomy,1 +PicturePage1Choice1X=98 +PicturePage1Choice1Y=180 +PicturePage1Choice1OnCommand=vertalign,top;zoomy,0.0;sleep,0.4;bounceend,0.3;zoomy,1 PicturePage1Choice1OffCommand=sleep,0.0;bouncebegin,0.3;zoomy,0 -PicturePage1Choice2OnCommand=vertalign,top;x,246;y,220;zoomy,0.0;sleep,0.6;bounceend,0.3;zoomy,1 +PicturePage1Choice2X=246 +PicturePage1Choice2Y=220 +PicturePage1Choice2OnCommand=vertalign,top;zoomy,0.0;sleep,0.6;bounceend,0.3;zoomy,1 PicturePage1Choice2OffCommand=sleep,0.2;bouncebegin,0.3;zoomy,0 -PicturePage1Choice3OnCommand=vertalign,top;x,394;y,180;zoomy,0.0;sleep,0.8;bounceend,0.3;zoomy,1 +PicturePage1Choice3X=394 +PicturePage1Choice3Y=180 +PicturePage1Choice3OnCommand=vertalign,top;zoomy,0.0;sleep,0.8;bounceend,0.3;zoomy,1 PicturePage1Choice3OffCommand=sleep,0.4;bouncebegin,0.3;zoomy,0 -PicturePage1Choice4OnCommand=vertalign,top;x,542;y,220;zoomy,0.0;sleep,1.0;bounceend,0.3;zoomy,1 +PicturePage1Choice4X=542 +PicturePage1Choice4Y=220 +PicturePage1Choice4OnCommand=vertalign,top;zoomy,0.0;sleep,1.0;bounceend,0.3;zoomy,1 PicturePage1Choice4OffCommand=sleep,0.6;bouncebegin,0.3;zoomy,0 -PicturePage2Choice1OnCommand=vertalign,top;x,738;y,220; +PicturePage2Choice1X=738 +PicturePage2Choice1Y=220 +PicturePage2Choice1OnCommand=vertalign,top; PicturePage2Choice1OffCommand=sleep,0.0;bouncebegin,0.3;zoomy,0 -PicturePage2Choice2OnCommand=vertalign,top;x,886;y,180 +PicturePage2Choice2X=886 +PicturePage2Choice2Y=180 +PicturePage2Choice2OnCommand=vertalign,top PicturePage2Choice2OffCommand=sleep,0.2;bouncebegin,0.3;zoomy,0 -PicturePage2Choice3OnCommand=vertalign,top;x,1034;y,220 +PicturePage2Choice3X=1034 +PicturePage2Choice3Y=220 +PicturePage2Choice3OnCommand=vertalign,top PicturePage2Choice3OffCommand=sleep,0.4;bouncebegin,0.3;zoomy,0 -PicturePage2Choice4OnCommand=vertalign,top;x,1182;y,180 +PicturePage2Choice4X=1182 +PicturePage2Choice4Y=180 +PicturePage2Choice4OnCommand=vertalign,top PicturePage2Choice4OffCommand=sleep,0.6;bouncebegin,0.3;zoomy,0 CursorOnCommand=diffusealpha,0;rotationz,340;zoom,4;linear,0.3;diffusealpha,1;rotationz,0;zoom,1;glowshift;effectperiod,0.5 CursorChooseCommand=sleep,0.2;linear,0.2;addx,10;addy,10 @@ -254,21 +294,35 @@ TimerSeconds=60 [ScreenSelectGroup] -FrameOnCommand=x,180;y,160;addx,-400;bounceend,0.5;addx,400 +FrameX=180 +FrameY=160 +FrameOnCommand=addx,-400;bounceend,0.5;addx,400 FrameOffCommand=sleep,0.6;bouncebegin,0.5;addx,-400 -BannerOnCommand=x,182;y,158;addx,-400;bounceend,0.5;addx,400 +BannerX=182 +BannerY=158 +BannerOnCommand=addx,-400;bounceend,0.5;addx,400 BannerOffCommand=sleep,0.6;bouncebegin,0.5;addx,-400 BannerWidth=288 BannerHeight=92 -NumberOnCommand=x,116;y,224;horizalign,right;shadowlength,0;addx,-400;bounceend,0.5;addx,400 +NumberX=116 +NumberY=224 +NumberOnCommand=horizalign,right;shadowlength,0;addx,-400;bounceend,0.5;addx,400 NumberOffCommand=sleep,0.6;bouncebegin,0.5;addx,-400 -ExplanationOnCommand=x,110;y,66;addx,-400;bounceend,0.5;addx,400 +ExplanationX=110 +ExplanationY=66 +ExplanationOnCommand=addx,-400;bounceend,0.5;addx,400 ExplanationOffCommand=bouncebegin,0.5;addx,-400 -ContentsOnCommand=x,320;y,260;diffusealpha,0;linear,0.5;diffusealpha,1 +ContentsX=320 +ContentsY=260 +ContentsOnCommand=diffusealpha,0;linear,0.5;diffusealpha,1 ContentsOffCommand=linear,0.5;diffusealpha,0 -GroupListOnCommand=x,504;y,200 +GroupListX=504 +GroupListY=200 +GroupListOnCommand= GroupListOffCommand= -MusicListOnCommand=x,20;y,276 +MusicListX=20 +MusicListY=276 +MusicListOnCommand= MusicListOffCommand= SleepAfterTweenOffSeconds=0.8 HelpText=Use &LEFT; &RIGHT; to select, then press START diff --git a/stepmania/src/Actor.h b/stepmania/src/Actor.h index 7b67163355..86995fb91c 100644 --- a/stepmania/src/Actor.h +++ b/stepmania/src/Actor.h @@ -59,16 +59,32 @@ public: virtual void Update( float fDeltaTime ); virtual void UpdateTweening( float fDeltaTime ); + + + CString m_sName; + + CString GetName() { return m_sName; }; + void SetName( CString n ) { m_sName = n; }; + + + /* Do subclasses really need to override tweening? Tween data should * probably be private ... - glenn */ + /* Things like a "FocusingSprite" might, but probably not. -Chris */ + /* Return the current coordinates, not the destination coordinates; * that's what the old behavior was, at least, and it's what ScreenMusicScroll * expects. I could see uses for knowing the destination coords, though, * especially now that setting parameters when tweening and when not tweening * is somewhat abstracted. Hmmm. -glenn */ + /* Things like the cursor on ScreenSelectDifficutly need to know the dest coordinates. + * -Chris */ virtual float GetX() const { return m_current.pos.x; }; virtual float GetY() const { return m_current.pos.y; }; virtual float GetZ() const { return m_current.pos.z; }; + virtual float GetDestX() { return DestTweenState().pos.x; }; + virtual float GetDestY() { return DestTweenState().pos.y; }; + virtual float GetDestZ() { return DestTweenState().pos.z; }; virtual void SetX( float x ) { DestTweenState().pos.x = x; }; virtual void SetY( float y ) { DestTweenState().pos.y = y; }; virtual void SetZ( float z ) { DestTweenState().pos.z = z; }; @@ -114,31 +130,6 @@ public: virtual RageColor GetGlow() { return DestTweenState().glow; }; - // TODO: Get rid of these once we're sure everything is working - virtual void SetTweenX( float x ) { SetX(x); } - virtual void SetTweenY( float y ) { SetY(y); } - virtual void SetTweenZ( float z ) { SetZ(z); } - virtual void SetTweenXY( float x, float y ) { SetXY(x,y); } - virtual void SetTweenZoom( float zoom ) { SetZoom(zoom); } - virtual void SetTweenZoomX( float zoom ) { SetZoomX(zoom); } - virtual void SetTweenZoomY( float zoom ) { SetZoomY(zoom); } - virtual void SetTweenZoomToWidth( float zoom ) { ZoomToWidth(zoom); } - virtual void SetTweenZoomToHeight( float zoom ) { ZoomToHeight(zoom); } - virtual void SetTweenRotationX( float r ) { SetRotationX(r); } - virtual void SetTweenRotationY( float r ) { SetRotationY(r); } - virtual void SetTweenRotationZ( float r ) { SetRotationZ(r); } - virtual void SetTweenDiffuse( RageColor c ) { SetDiffuse(c); } - virtual void SetTweenDiffuseUpperLeft( RageColor c ) { SetDiffuseUpperLeft(c); } - virtual void SetTweenDiffuseUpperRight( RageColor c ) { SetDiffuseUpperRight(c); } - virtual void SetTweenDiffuseLowerLeft( RageColor c ) { SetDiffuseLowerLeft(c); } - virtual void SetTweenDiffuseLowerRight( RageColor c ) { SetDiffuseLowerRight(c); } - virtual void SetTweenDiffuseTopEdge( RageColor c ) { SetDiffuseTopEdge(c); } - virtual void SetTweenDiffuseRightEdge( RageColor c ) { SetDiffuseRightEdge(c); } - virtual void SetTweenDiffuseBottomEdge( RageColor c ) { SetDiffuseBottomEdge(c); } - virtual void SetTweenDiffuseLeftEdge( RageColor c ) { SetDiffuseLeftEdge(c); } - virtual void SetTweenGlow( RageColor c ) { SetGlow(c); } - - virtual void BeginTweening( float time, TweenType tt = TWEEN_LINEAR ); virtual void StopTweening(); virtual float GetTweenTimeLeft() const; // Amount of time until all tweens have stopped diff --git a/stepmania/src/BGAnimationLayer.cpp b/stepmania/src/BGAnimationLayer.cpp index 339c9334fa..567eb2cb2c 100644 --- a/stepmania/src/BGAnimationLayer.cpp +++ b/stepmania/src/BGAnimationLayer.cpp @@ -756,7 +756,7 @@ void BGAnimationLayer::Update( float fDeltaTime ) m_TweenStartTime -= fDeltaTime; if(m_TweenStartTime <= 0) // if we've gone past the magic point... show the beast.... { - // m_Sprites[0].SetTweenXY( m_TweenX, m_TweenY); + // m_Sprites[0].SetXY( m_TweenX, m_TweenY); // WHAT WOULD BE NICE HERE: // Set the Sprite Tweening To m_TweenX and m_TweenY diff --git a/stepmania/src/BPMDisplay.cpp b/stepmania/src/BPMDisplay.cpp index 6e560a82e5..75623063fc 100644 --- a/stepmania/src/BPMDisplay.cpp +++ b/stepmania/src/BPMDisplay.cpp @@ -128,18 +128,18 @@ void BPMDisplay::SetBPMRange( float fLowBPM, float fHighBPM ) if( GAMESTATE->IsExtraStage() || GAMESTATE->IsExtraStage2() ) { - m_textBPM.SetTweenDiffuse( EXTRA_COLOR ); - m_sprLabel.SetTweenDiffuse( EXTRA_COLOR ); + m_textBPM.SetDiffuse( EXTRA_COLOR ); + m_sprLabel.SetDiffuse( EXTRA_COLOR ); } else if( m_fLowBPM != m_fHighBPM ) { - m_textBPM.SetTweenDiffuse( CHANGE_COLOR ); - m_sprLabel.SetTweenDiffuse( CHANGE_COLOR ); + m_textBPM.SetDiffuse( CHANGE_COLOR ); + m_sprLabel.SetDiffuse( CHANGE_COLOR ); } else { - m_textBPM.SetTweenDiffuse( NORMAL_COLOR ); - m_sprLabel.SetTweenDiffuse( NORMAL_COLOR ); + m_textBPM.SetDiffuse( NORMAL_COLOR ); + m_sprLabel.SetDiffuse( NORMAL_COLOR ); } } @@ -149,8 +149,8 @@ void BPMDisplay::CycleRandomly() m_CountingState = cycle_randomly; m_fTimeLeftInState = 0; - m_textBPM.SetTweenDiffuse( NORMAL_COLOR ); - m_sprLabel.SetTweenDiffuse( NORMAL_COLOR ); + m_textBPM.SetDiffuse( NORMAL_COLOR ); + m_sprLabel.SetDiffuse( NORMAL_COLOR ); } void BPMDisplay::NoBPM() @@ -158,6 +158,6 @@ void BPMDisplay::NoBPM() m_CountingState = no_bpm; m_textBPM.SetText( "..." ); - m_textBPM.SetTweenDiffuse( NORMAL_COLOR ); - m_sprLabel.SetTweenDiffuse( NORMAL_COLOR ); + m_textBPM.SetDiffuse( NORMAL_COLOR ); + m_sprLabel.SetDiffuse( NORMAL_COLOR ); } diff --git a/stepmania/src/Background.cpp b/stepmania/src/Background.cpp index 311f44f723..7f16b445d3 100644 --- a/stepmania/src/Background.cpp +++ b/stepmania/src/Background.cpp @@ -418,13 +418,13 @@ bool Background::IsDangerVisible() void Background::FadeIn() { m_quadBGBrightness.BeginTweening( 0.5f ); - m_quadBGBrightness.SetTweenDiffuse( RageColor(0,0,0,1-PREFSMAN->m_fBGBrightness) ); + m_quadBGBrightness.SetDiffuse( RageColor(0,0,0,1-PREFSMAN->m_fBGBrightness) ); } void Background::FadeOut() { m_quadBGBrightness.BeginTweening( 0.5f ); - m_quadBGBrightness.SetTweenDiffuse( RageColor(0,0,0,1-0.5f) ); + m_quadBGBrightness.SetDiffuse( RageColor(0,0,0,1-0.5f) ); } diff --git a/stepmania/src/Combo.cpp b/stepmania/src/Combo.cpp index a71601e138..ff86dbf7c4 100644 --- a/stepmania/src/Combo.cpp +++ b/stepmania/src/Combo.cpp @@ -81,11 +81,11 @@ void Combo::SetCombo( int iCombo ) CLAMP( fNumberZoom, (float)NUMBER_MIN_ZOOM, (float)NUMBER_MAX_ZOOM ); m_textComboNumber.SetZoom( fNumberZoom * (float)PULSE_ZOOM ); m_textComboNumber.BeginTweening( C_TWEEN_SECONDS ); - m_textComboNumber.SetTweenZoom( fNumberZoom ); + m_textComboNumber.SetZoom( fNumberZoom ); m_sprCombo.SetZoom( PULSE_ZOOM ); m_sprCombo.BeginTweening( C_TWEEN_SECONDS ); - m_sprCombo.SetTweenZoom( 1 ); + m_sprCombo.SetZoom( 1 ); } else { diff --git a/stepmania/src/CourseContentsList.cpp b/stepmania/src/CourseContentsList.cpp index b21340ca6d..6345640e38 100644 --- a/stepmania/src/CourseContentsList.cpp +++ b/stepmania/src/CourseContentsList.cpp @@ -143,6 +143,6 @@ void CourseContentsList::TweenInAfterChangedCourse() display.StopTweening(); display.SetXY( 0, -((MAX_VISIBLE_CONTENTS-1)/2) * float(ContentsBarHeight) ); display.BeginTweening( i*0.1f ); - display.SetTweenY( (-(MAX_VISIBLE_CONTENTS-1)/2 + i) * float(ContentsBarHeight) ); + display.SetY( (-(MAX_VISIBLE_CONTENTS-1)/2 + i) * float(ContentsBarHeight) ); } } diff --git a/stepmania/src/FadingBanner.cpp b/stepmania/src/FadingBanner.cpp index c0ec3608a8..c3687b9ccb 100644 --- a/stepmania/src/FadingBanner.cpp +++ b/stepmania/src/FadingBanner.cpp @@ -54,6 +54,6 @@ void FadingBanner::BeforeChange() m_FrontBanner.SetDiffuse( RageColor(1,1,1,1) ); m_FrontBanner.StopTweening(); m_FrontBanner.BeginTweening( 0.25f ); // fade out - m_FrontBanner.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_FrontBanner.SetDiffuse( RageColor(1,1,1,0) ); } diff --git a/stepmania/src/FocusingSprite.cpp b/stepmania/src/FocusingSprite.cpp deleted file mode 100644 index 0bdaaf23c9..0000000000 --- a/stepmania/src/FocusingSprite.cpp +++ /dev/null @@ -1,89 +0,0 @@ -#include "global.h" -/* ------------------------------------------------------------------------------ - File: FocusingSprite.h - - Desc: A graphic that appears to blur and come into focus. - - Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved. ------------------------------------------------------------------------------ -*/ - -#include "FocusingSprite.h" -#include "RageUtil.h" - - - -#define BLUR_DISTANCE 50 - -#define BLUR_TWEEN_TIME 0.5f - - - -FocusingSprite::FocusingSprite() -{ - for( int i=0; i<3; i++ ) - { - this->AddChild( &m_sprites[i] ); - } - - m_fPercentBlurred = 1.0f; - m_BlurState = invisible; -} - -void FocusingSprite::Update( float fDeltaTime ) -{ - ActorFrame::Update( fDeltaTime ); - - - switch( m_BlurState ) - { - case focused: - break; - case focusing: - m_fPercentBlurred -= fDeltaTime / BLUR_TWEEN_TIME; - if( m_fPercentBlurred <= 0.0f ) { - m_fPercentBlurred = 0.0f; - m_BlurState = focused; - } - break; - case invisible: - break; - case blurring: - m_fPercentBlurred += fDeltaTime / BLUR_TWEEN_TIME; - if( m_fPercentBlurred >= 1.0f ) { - m_fPercentBlurred = 1.0f; - m_BlurState = invisible; - } - break; - } - -} - -void FocusingSprite::DrawPrimitives() -{ - if( m_BlurState != invisible ) - { - SetDiffuse( RageColor(1,1,1,0.5f-m_fPercentBlurred/2) ); - - m_sprites[0].SetXY( m_fPercentBlurred*BLUR_DISTANCE*2, m_fPercentBlurred*BLUR_DISTANCE ); - m_sprites[1].SetXY( -m_fPercentBlurred*BLUR_DISTANCE*2, -m_fPercentBlurred*BLUR_DISTANCE ); - m_sprites[2].SetXY( 0, 0 ); - - ActorFrame::DrawPrimitives(); - } - -} - - -void FocusingSprite::StartFocusing() -{ - m_fPercentBlurred = 1; - m_BlurState = focusing; -} - -void FocusingSprite::StartBlurring() -{ - m_fPercentBlurred = 0; - m_BlurState = blurring; -} diff --git a/stepmania/src/FocusingSprite.h b/stepmania/src/FocusingSprite.h deleted file mode 100644 index 7d91ff3cfe..0000000000 --- a/stepmania/src/FocusingSprite.h +++ /dev/null @@ -1,48 +0,0 @@ -/* ------------------------------------------------------------------------------ - File: FocusingSprite.h - - Desc: A graphic that appears to blur and come into focus. - - Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved. ------------------------------------------------------------------------------ -*/ - -#ifndef _FocusingSprite_H_ -#define _FocusingSprite_H_ - - -#include "Sprite.h" -#include "ActorFrame.h" - - -class FocusingSprite : public ActorFrame -{ -public: - - FocusingSprite(); - - virtual bool Load( const CString &sFilePath ) - { - for( int i=0; i<3; i++ ) - m_sprites[i].Load( sFilePath ); - return true; - }; - - virtual void Update( float fDeltaTime ); - virtual void DrawPrimitives(); - - void StartFocusing(); - void StartBlurring(); - -protected: - Sprite m_sprites[3]; - float m_fPercentBlurred; - enum BlurState { focused, focusing, invisible, blurring }; - BlurState m_BlurState; -}; - - - - -#endif diff --git a/stepmania/src/GhostArrow.cpp b/stepmania/src/GhostArrow.cpp index a9688d28e0..3f2710a464 100644 --- a/stepmania/src/GhostArrow.cpp +++ b/stepmania/src/GhostArrow.cpp @@ -73,8 +73,8 @@ void GhostArrow::Step( TapNoteScore score ) SetZoom( GA_ZOOM_START ); BeginTweening( (float)GA_SHOW_SECONDS/2.0f ); - SetTweenZoom( ((float)GA_ZOOM_START+(float)GA_ZOOM_END)/2.0f ); + SetZoom( ((float)GA_ZOOM_START+(float)GA_ZOOM_END)/2.0f ); BeginTweening( (float)GA_SHOW_SECONDS/2.0f ); - SetTweenZoom( GA_ZOOM_END ); - SetTweenDiffuse( colorEnd ); + SetZoom( GA_ZOOM_END ); + SetDiffuse( colorEnd ); } diff --git a/stepmania/src/GhostArrowBright.cpp b/stepmania/src/GhostArrowBright.cpp index 380f1e72a1..f7c9525da6 100644 --- a/stepmania/src/GhostArrowBright.cpp +++ b/stepmania/src/GhostArrowBright.cpp @@ -73,8 +73,8 @@ void GhostArrowBright::Step( TapNoteScore score ) SetZoom( GAB_ZOOM_START ); BeginTweening( (float)GAB_SHOW_SECONDS/2 ); - SetTweenZoom( ((float)GAB_ZOOM_START+(float)GAB_ZOOM_END)/2 ); + SetZoom( ((float)GAB_ZOOM_START+(float)GAB_ZOOM_END)/2 ); BeginTweening( (float)GAB_SHOW_SECONDS/2 ); - SetTweenZoom( GAB_ZOOM_END ); - SetTweenDiffuse( colorEnd ); + SetZoom( GAB_ZOOM_END ); + SetDiffuse( colorEnd ); } diff --git a/stepmania/src/GrayArrow.cpp b/stepmania/src/GrayArrow.cpp index 71c7bbd4c0..9315e14de8 100644 --- a/stepmania/src/GrayArrow.cpp +++ b/stepmania/src/GrayArrow.cpp @@ -73,5 +73,5 @@ void GrayArrow::Step() SetZoom( GR_STEP_ZOOM ); StopTweening(); BeginTweening( GR_STEP_SECONDS ); - SetTweenZoom( 1 ); + SetZoom( 1 ); } diff --git a/stepmania/src/GrooveRadar.cpp b/stepmania/src/GrooveRadar.cpp index ee8c7710f7..4aee32042d 100644 --- a/stepmania/src/GrooveRadar.cpp +++ b/stepmania/src/GrooveRadar.cpp @@ -56,13 +56,13 @@ void GrooveRadar::TweenOnScreen() m_sprRadarLabels[c].BeginTweening( 0.6f+0.2f*c ); // sleep m_sprRadarLabels[c].BeginTweening( 0.1f ); // begin fading on screen - m_sprRadarLabels[c].SetTweenGlow( RageColor(1,1,1,1) ); + m_sprRadarLabels[c].SetGlow( RageColor(1,1,1,1) ); m_sprRadarLabels[c].BeginTweening( 0.3f, Actor::TWEEN_ACCELERATE ); // fly to the right - m_sprRadarLabels[c].SetTweenX( fOriginalX ); - m_sprRadarLabels[c].SetTweenZoom( 1 ); - m_sprRadarLabels[c].SetTweenGlow( RageColor(1,1,1,0) ); - m_sprRadarLabels[c].SetTweenDiffuse( RageColor(1,1,1,1) ); + m_sprRadarLabels[c].SetX( fOriginalX ); + m_sprRadarLabels[c].SetZoom( 1 ); + m_sprRadarLabels[c].SetGlow( RageColor(1,1,1,0) ); + m_sprRadarLabels[c].SetDiffuse( RageColor(1,1,1,1) ); } m_GrooveRadarValueMap.TweenOnScreen(); } @@ -76,8 +76,8 @@ void GrooveRadar::TweenOffScreen() /* Make sure we undo glow. We do this at the end of TweenIn, * but we might tween off before we complete tweening in, and * the glow can remain. */ - m_sprRadarLabels[c].SetTweenGlow( RageColor(1,1,1,0) ); - m_sprRadarLabels[c].SetTweenDiffuse( RageColor(1,1,1,0) ); + m_sprRadarLabels[c].SetGlow( RageColor(1,1,1,0) ); + m_sprRadarLabels[c].SetDiffuse( RageColor(1,1,1,0) ); } m_GrooveRadarValueMap.TweenOffScreen(); } @@ -206,13 +206,13 @@ void GrooveRadar::GrooveRadarValueMap::TweenOnScreen() SetZoom( 0.5f ); SetRotationZ( 720 ); BeginTweening( 0.6f ); - SetTweenZoom( 1 ); - SetTweenRotationZ( 0 ); + SetZoom( 1 ); + SetRotationZ( 0 ); } void GrooveRadar::GrooveRadarValueMap::TweenOffScreen() { BeginTweening( 0.6f ); - SetTweenRotationZ( 180*4 ); - SetTweenZoom( 0 ); + SetRotationZ( 180*4 ); + SetZoom( 0 ); } diff --git a/stepmania/src/GroupList.cpp b/stepmania/src/GroupList.cpp index e802faca47..d00fb2d6fa 100644 --- a/stepmania/src/GroupList.cpp +++ b/stepmania/src/GroupList.cpp @@ -132,12 +132,12 @@ void GroupList::TweenOnScreen() m_sprButton[i].SetX( 400 ); m_sprButton[i].BeginTweening( 0.1f*i, TWEEN_BOUNCE_END ); m_sprButton[i].BeginTweening( 0.2f, TWEEN_BOUNCE_END ); - m_sprButton[i].SetTweenX( 0 ); + m_sprButton[i].SetX( 0 ); m_screenLabels[i].SetX( 400 ); m_screenLabels[i].BeginTweening( 0.1f*i, TWEEN_BOUNCE_END ); m_screenLabels[i].BeginTweening( 0.2f, TWEEN_BOUNCE_END ); - m_screenLabels[i].SetTweenX( 0 ); + m_screenLabels[i].SetX( 0 ); } } @@ -150,14 +150,14 @@ void GroupList::TweenOffScreen() else m_sprButton[i].BeginTweening( 0.1f*i, TWEEN_BOUNCE_BEGIN ); m_sprButton[i].BeginTweening( 0.2f, TWEEN_BOUNCE_BEGIN ); - m_sprButton[i].SetTweenX( 400 ); + m_sprButton[i].SetX( 400 ); if( i == m_iSelection ) m_screenLabels[i].BeginTweening( 1.0f, TWEEN_BOUNCE_BEGIN ); else m_screenLabels[i].BeginTweening( 0.1f*i, TWEEN_BOUNCE_BEGIN ); m_screenLabels[i].BeginTweening( 0.2f, TWEEN_BOUNCE_BEGIN ); - m_screenLabels[i].SetTweenX( 400 ); + m_screenLabels[i].SetX( 400 ); } } diff --git a/stepmania/src/Inventory.cpp b/stepmania/src/Inventory.cpp index ff47d58d22..7692646299 100644 --- a/stepmania/src/Inventory.cpp +++ b/stepmania/src/Inventory.cpp @@ -113,7 +113,7 @@ void Inventory::Update( float fDelta ) if( GAMESTATE->m_PlayerController[m_PlayerNumber] != HUMAN ) { // every one second, consider using an item - int iLastSecond = (int)RageTimer::GetTimeSinceStart() - fDelta; + int iLastSecond = (int)(RageTimer::GetTimeSinceStart() - fDelta); int iThisSecond = (int)RageTimer::GetTimeSinceStart(); if( iLastSecond != iThisSecond ) { diff --git a/stepmania/src/LifeMeterBattery.cpp b/stepmania/src/LifeMeterBattery.cpp index a58f06eed5..4db97ce3c5 100644 --- a/stepmania/src/LifeMeterBattery.cpp +++ b/stepmania/src/LifeMeterBattery.cpp @@ -125,7 +125,7 @@ void LifeMeterBattery::ChangeLife( TapNoteScore score ) m_textNumLives.SetZoom( 1.5f ); m_textNumLives.BeginTweening( 0.15f ); - m_textNumLives.SetTweenZoom( 1.0f ); + m_textNumLives.SetZoom( 1.0f ); Refresh(); m_fBatteryBlinkTime = BATTERY_BLINK_TIME; diff --git a/stepmania/src/MenuElements.cpp b/stepmania/src/MenuElements.cpp index 7c4e74b7fd..8398f6c206 100644 --- a/stepmania/src/MenuElements.cpp +++ b/stepmania/src/MenuElements.cpp @@ -46,12 +46,12 @@ void MenuElements::Load( CString sClassName, bool bEnableTimer, bool bLoadStyleI ASSERT( this->m_SubActors.empty() ); // don't call Load twice! - m_sClassName = sClassName; + m_sName = sClassName; - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations",m_sClassName+" background") ); + m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations",m_sName+" background") ); this->AddChild( &m_Background ); - m_sprHeader.Load( THEME->GetPathTo("Graphics",m_sClassName+" header") ); + m_sprHeader.Load( THEME->GetPathTo("Graphics",m_sName+" header") ); m_sprHeader.Command( HEADER_ON_COMMAND ); this->AddChild( &m_sprHeader ); @@ -66,26 +66,26 @@ void MenuElements::Load( CString sClassName, bool bEnableTimer, bool bLoadStyleI m_MenuTimer.Command( TIMER_ON_COMMAND ); if( bEnableTimer && PREFSMAN->m_bMenuTimer && !GAMESTATE->m_bEditing ) - m_MenuTimer.SetSeconds( THEME->GetMetricI(m_sClassName,"TimerSeconds") ); + m_MenuTimer.SetSeconds( THEME->GetMetricI(m_sName,"TimerSeconds") ); else m_MenuTimer.Disable(); this->AddChild( &m_MenuTimer ); - m_sprFooter.Load( THEME->GetPathTo("Graphics",m_sClassName+" footer") ); + m_sprFooter.Load( THEME->GetPathTo("Graphics",m_sName+" footer") ); m_sprFooter.Command( FOOTER_ON_COMMAND ); this->AddChild( &m_sprFooter ); m_textHelp.Command( HELP_ON_COMMAND ); CStringArray asHelpTips; - split( THEME->GetMetric(m_sClassName,"HelpText"), "\n", asHelpTips ); + split( THEME->GetMetric(m_sName,"HelpText"), "\n", asHelpTips ); m_textHelp.SetTips( asHelpTips ); this->AddChild( &m_textHelp ); - m_In.Load( THEME->GetPathTo("BGAnimations",m_sClassName+" in") ); + m_In.Load( THEME->GetPathTo("BGAnimations",m_sName+" in") ); this->AddChild( &m_In ); - m_Out.Load( THEME->GetPathTo("BGAnimations",m_sClassName+" out") ); + m_Out.Load( THEME->GetPathTo("BGAnimations",m_sName+" out") ); this->AddChild( &m_Out ); m_Back.Load( THEME->GetPathTo("BGAnimations","Common back") ); diff --git a/stepmania/src/MenuElements.h b/stepmania/src/MenuElements.h index df96aa0559..b21e49fc96 100644 --- a/stepmania/src/MenuElements.h +++ b/stepmania/src/MenuElements.h @@ -43,7 +43,7 @@ public: public: // let owner tinker with these objects - CString m_sClassName; + CString m_sName; BGAnimation m_Background; diff --git a/stepmania/src/MenuTimer.cpp b/stepmania/src/MenuTimer.cpp index 6d18a7c719..289561c402 100644 --- a/stepmania/src/MenuTimer.cpp +++ b/stepmania/src/MenuTimer.cpp @@ -97,11 +97,11 @@ void MenuTimer::Update( float fDeltaTime ) m_textDigit1.StopTweening(); m_textDigit1.BeginTweening( 0.8f ); // sleep m_textDigit1.BeginTweening( 0.2f ); - m_textDigit1.SetTweenZoomX( 0 ); + m_textDigit1.SetZoomX( 0 ); m_textDigit2.StopTweening(); m_textDigit2.BeginTweening( 0.8f ); // sleep m_textDigit2.BeginTweening( 0.2f ); - m_textDigit2.SetTweenZoomX( 0 ); + m_textDigit2.SetZoomX( 0 ); break; case 5: // transition to below 5 m_textDigit1.SetEffectGlowShift( 0.15f, RageColor(1,0,0,0), RageColor(1,0,0,1) ); @@ -113,16 +113,16 @@ void MenuTimer::Update( float fDeltaTime ) case 1: m_textDigit1.StopTweening(); m_textDigit1.BeginTweening( 0.2f ); - m_textDigit1.SetTweenZoomX( 1 ); + m_textDigit1.SetZoomX( 1 ); m_textDigit1.BeginTweening( 0.6f ); // sleep m_textDigit1.BeginTweening( 0.2f ); - m_textDigit1.SetTweenZoomX( 0 ); + m_textDigit1.SetZoomX( 0 ); m_textDigit2.StopTweening(); m_textDigit2.BeginTweening( 0.2f ); - m_textDigit2.SetTweenZoomX( 1 ); + m_textDigit2.SetZoomX( 1 ); m_textDigit2.BeginTweening( 0.6f ); // sleep m_textDigit2.BeginTweening( 0.2f ); - m_textDigit2.SetTweenZoomX( 0 ); + m_textDigit2.SetZoomX( 0 ); m_soundBeep.Play(); break; diff --git a/stepmania/src/MotionBlurSprite.cpp b/stepmania/src/MotionBlurSprite.cpp deleted file mode 100644 index ae4832ed38..0000000000 --- a/stepmania/src/MotionBlurSprite.cpp +++ /dev/null @@ -1,17 +0,0 @@ -#include "global.h" -/* ------------------------------------------------------------------------------ - Class: MotionBlurSprite - - Desc: See header. - - Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved. - Chris Danford ------------------------------------------------------------------------------ -*/ - -#include "MotionBlurSprite.h" -#include "RageUtil.h" - - - diff --git a/stepmania/src/MotionBlurSprite.h b/stepmania/src/MotionBlurSprite.h deleted file mode 100644 index 06e76dbfa9..0000000000 --- a/stepmania/src/MotionBlurSprite.h +++ /dev/null @@ -1,112 +0,0 @@ -#ifndef MOTIONBLURSPRITE_H -#define MOTIONBLURSPRITE_H -/* ------------------------------------------------------------------------------ - Class: MotionBlurSprite - - Desc: A sprite that leaves a ghost trail. - - Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved. - Chris Danford ------------------------------------------------------------------------------ -*/ - -#include "Sprite.h" -#include "ActorFrame.h" - - -const int NUM_BLUR_GHOSTS = 2; - -class MotionBlurSprite : public Actor -{ -public: - - virtual bool Load( const CString &sFilePath ) { for( int i=0; im_bMarvelousTiming ) score = TNS_PERFECT; - if( score >= TNS_GOOD ) + if( score < TNS_GOOD ) m_GrayArrowRow.Step( col ); LOG->Trace("Note offset: %f (fSecondsFromPerfect = %f), Score: %i", fNoteOffset, fSecondsFromPerfect, score); diff --git a/stepmania/src/Screen.cpp b/stepmania/src/Screen.cpp index 00b1fefbc7..2c4ea3d46e 100644 --- a/stepmania/src/Screen.cpp +++ b/stepmania/src/Screen.cpp @@ -18,8 +18,9 @@ #include "ThemeManager.h" #include "ScreenManager.h" -Screen::Screen() +Screen::Screen( CString sName ) { + SetName( sName ); m_bIsTransparent = false; } @@ -279,63 +280,63 @@ Screen* Screen::Create( CString sClassName ) { Screen *ret = NULL; - if( 0==stricmp(sClassName, "ScreenAppearanceOptions") ) ret = new ScreenAppearanceOptions; - else if( 0==stricmp(sClassName, "ScreenCaution") ) ret = new ScreenCaution; - else if( 0==stricmp(sClassName, "ScreenEdit") ) ret = new ScreenEdit; - else if( 0==stricmp(sClassName, "ScreenEditMenu") ) ret = new ScreenEditMenu; - else if( 0==stricmp(sClassName, "ScreenEvaluationStage") ) ret = new ScreenEvaluationStage; - else if( 0==stricmp(sClassName, "ScreenEvaluationSummary") ) ret = new ScreenEvaluationSummary; - else if( 0==stricmp(sClassName, "ScreenEvaluationNonstop") ) ret = new ScreenEvaluationNonstop; - else if( 0==stricmp(sClassName, "ScreenEvaluationOni") ) ret = new ScreenEvaluationOni; - else if( 0==stricmp(sClassName, "ScreenEvaluationEndless") ) ret = new ScreenEvaluationEndless; - else if( 0==stricmp(sClassName, "ScreenEz2SelectPlayer") ) ret = new ScreenEz2SelectPlayer; - else if( 0==stricmp(sClassName, "ScreenSelectMode") ) ret = new ScreenSelectMode; - else if( 0==stricmp(sClassName, "ScreenGameOver") ) ret = new ScreenGameOver; - else if( 0==stricmp(sClassName, "ScreenGameplay") ) ret = new ScreenGameplay; - else if( 0==stricmp(sClassName, "ScreenGraphicOptions") ) ret = new ScreenGraphicOptions; - else if( 0==stricmp(sClassName, "ScreenHowToPlay") ) ret = new ScreenHowToPlay; - else if( 0==stricmp(sClassName, "ScreenInputOptions") ) ret = new ScreenInputOptions; - else if( 0==stricmp(sClassName, "ScreenMachineOptions") ) ret = new ScreenMachineOptions; - else if( 0==stricmp(sClassName, "ScreenMapControllers") ) ret = new ScreenMapControllers; - else if( 0==stricmp(sClassName, "ScreenInputOptions") ) ret = new ScreenInputOptions; - else if( 0==stricmp(sClassName, "ScreenMusicScroll") ) ret = new ScreenMusicScroll; - else if( 0==stricmp(sClassName, "ScreenPlayerOptions") ) ret = new ScreenPlayerOptions; - else if( 0==stricmp(sClassName, "ScreenSandbox") ) ret = new ScreenSandbox; - else if( 0==stricmp(sClassName, "ScreenSelectCourse") ) ret = new ScreenSelectCourse; - else if( 0==stricmp(sClassName, "ScreenSelectDifficulty") ) ret = new ScreenSelectDifficulty; - else if( 0==stricmp(sClassName, "ScreenSelectDifficultyEX") ) ret = new ScreenSelectDifficultyEX; - else if( 0==stricmp(sClassName, "ScreenSelectGame") ) ret = new ScreenSelectGame; - else if( 0==stricmp(sClassName, "ScreenSelectGroup") ) ret = new ScreenSelectGroup; - else if( 0==stricmp(sClassName, "ScreenSelectMusic") ) ret = new ScreenSelectMusic; - else if( 0==stricmp(sClassName, "ScreenSelectStyle5th") ) ret = new ScreenSelectStyle5th; - else if( 0==stricmp(sClassName, "ScreenSelectStyle") ) ret = new ScreenSelectStyle; - else if( 0==stricmp(sClassName, "ScreenSongOptions") ) ret = new ScreenSongOptions; - else if( 0==stricmp(sClassName, "ScreenStage") ) ret = new ScreenStage; - else if( 0==stricmp(sClassName, "ScreenTest") ) ret = new ScreenTest; - else if( 0==stricmp(sClassName, "ScreenTestFonts") ) ret = new ScreenTestFonts; - else if( 0==stricmp(sClassName, "ScreenTestSound") ) ret = new ScreenTestSound; - else if( 0==stricmp(sClassName, "ScreenTitleMenu") ) ret = new ScreenTitleMenu; - else if( 0==stricmp(sClassName, "ScreenEz2SelectMusic") ) ret = new ScreenEz2SelectMusic; - else if( 0==stricmp(sClassName, "ScreenWarning") ) ret = new ScreenWarning; - else if( 0==stricmp(sClassName, "ScreenRanking") ) ret = new ScreenRanking; - else if( 0==stricmp(sClassName, "ScreenMemoryCard") ) ret = new ScreenMemoryCard; - else if( 0==stricmp(sClassName, "ScreenCompany") ) ret = new ScreenCompany; - else if( 0==stricmp(sClassName, "ScreenIntroMovie") ) ret = new ScreenIntroMovie; - else if( 0==stricmp(sClassName, "ScreenAlbums") ) ret = new ScreenAlbums; - else if( 0==stricmp(sClassName, "ScreenLogo") ) ret = new ScreenLogo; - else if( 0==stricmp(sClassName, "ScreenUnlock") ) ret = new ScreenUnlock; - else if( 0==stricmp(sClassName, "ScreenDemonstration") ) ret = (ScreenGameplay*)new ScreenDemonstration; - else if( 0==stricmp(sClassName, "ScreenInstructions") ) ret = new ScreenInstructions; - else if( 0==stricmp(sClassName, "ScreenNameEntry") ) ret = new ScreenNameEntry; - else if( 0==stricmp(sClassName, "ScreenJukebox") ) ret = new ScreenJukebox; - else if( 0==stricmp(sClassName, "ScreenJukeboxMenu") ) ret = new ScreenJukeboxMenu; - else if( 0==stricmp(sClassName, "ScreenOptionsMenu") ) ret = new ScreenOptionsMenu; - else if( 0==stricmp(sClassName, "ScreenSoundOptions") ) ret = new ScreenSoundOptions; - else if( 0==stricmp(sClassName, "ScreenGameplayOptions") ) ret = new ScreenGameplayOptions; - else if( 0==stricmp(sClassName, "ScreenStyleSplash") ) ret = new ScreenStyleSplash; - else if( 0==stricmp(sClassName, "ScreenAutogenOptions") ) ret = new ScreenAutogenOptions; - else if( 0==stricmp(sClassName, "ScreenCredits") ) ret = new ScreenCredits; - else if( 0==stricmp(sClassName, "ScreenSelectCharacter") ) ret = new ScreenSelectCharacter; + if( sClassName=="ScreenAppearanceOptions" ) ret = new ScreenAppearanceOptions; + else if( sClassName=="ScreenCaution" ) ret = new ScreenCaution; + else if( sClassName=="ScreenEdit" ) ret = new ScreenEdit; + else if( sClassName=="ScreenEditMenu" ) ret = new ScreenEditMenu; + else if( sClassName=="ScreenEvaluationStage" ) ret = new ScreenEvaluationStage; + else if( sClassName=="ScreenEvaluationSummary" ) ret = new ScreenEvaluationSummary; + else if( sClassName=="ScreenEvaluationNonstop" ) ret = new ScreenEvaluationNonstop; + else if( sClassName=="ScreenEvaluationOni" ) ret = new ScreenEvaluationOni; + else if( sClassName=="ScreenEvaluationEndless" ) ret = new ScreenEvaluationEndless; + else if( sClassName=="ScreenEz2SelectPlayer" ) ret = new ScreenEz2SelectPlayer; + else if( sClassName=="ScreenSelectMode" ) ret = new ScreenSelectMode; + else if( sClassName=="ScreenGameOver" ) ret = new ScreenGameOver; + else if( sClassName=="ScreenGameplay" ) ret = new ScreenGameplay; + else if( sClassName=="ScreenGraphicOptions" ) ret = new ScreenGraphicOptions; + else if( sClassName=="ScreenHowToPlay" ) ret = new ScreenHowToPlay; + else if( sClassName=="ScreenInputOptions" ) ret = new ScreenInputOptions; + else if( sClassName=="ScreenMachineOptions" ) ret = new ScreenMachineOptions; + else if( sClassName=="ScreenMapControllers" ) ret = new ScreenMapControllers; + else if( sClassName=="ScreenInputOptions" ) ret = new ScreenInputOptions; + else if( sClassName=="ScreenMusicScroll" ) ret = new ScreenMusicScroll; + else if( sClassName=="ScreenPlayerOptions" ) ret = new ScreenPlayerOptions; + else if( sClassName=="ScreenSandbox" ) ret = new ScreenSandbox; + else if( sClassName=="ScreenSelectCourse" ) ret = new ScreenSelectCourse; + else if( sClassName=="ScreenSelectDifficulty" ) ret = new ScreenSelectDifficulty; + else if( sClassName=="ScreenSelectDifficultyEX" ) ret = new ScreenSelectDifficultyEX; + else if( sClassName=="ScreenSelectGame" ) ret = new ScreenSelectGame; + else if( sClassName=="ScreenSelectGroup" ) ret = new ScreenSelectGroup; + else if( sClassName=="ScreenSelectMusic" ) ret = new ScreenSelectMusic; + else if( sClassName=="ScreenSelectStyle5th" ) ret = new ScreenSelectStyle5th; + else if( sClassName=="ScreenSelectStyle" ) ret = new ScreenSelectStyle; + else if( sClassName=="ScreenSongOptions" ) ret = new ScreenSongOptions; + else if( sClassName=="ScreenStage" ) ret = new ScreenStage; + else if( sClassName=="ScreenTest" ) ret = new ScreenTest; + else if( sClassName=="ScreenTestFonts" ) ret = new ScreenTestFonts; + else if( sClassName=="ScreenTestSound" ) ret = new ScreenTestSound; + else if( sClassName=="ScreenTitleMenu" ) ret = new ScreenTitleMenu; + else if( sClassName=="ScreenEz2SelectMusic" ) ret = new ScreenEz2SelectMusic; + else if( sClassName=="ScreenWarning" ) ret = new ScreenWarning; + else if( sClassName=="ScreenRanking" ) ret = new ScreenRanking; + else if( sClassName=="ScreenMemoryCard" ) ret = new ScreenMemoryCard; + else if( sClassName=="ScreenCompany" ) ret = new ScreenCompany; + else if( sClassName=="ScreenIntroMovie" ) ret = new ScreenIntroMovie; + else if( sClassName=="ScreenAlbums" ) ret = new ScreenAlbums; + else if( sClassName=="ScreenLogo" ) ret = new ScreenLogo; + else if( sClassName=="ScreenUnlock" ) ret = new ScreenUnlock; + else if( sClassName=="ScreenDemonstration" ) ret = (ScreenGameplay*)new ScreenDemonstration; + else if( sClassName=="ScreenInstructions" ) ret = new ScreenInstructions; + else if( sClassName=="ScreenNameEntry" ) ret = new ScreenNameEntry; + else if( sClassName=="ScreenJukebox" ) ret = new ScreenJukebox; + else if( sClassName=="ScreenJukeboxMenu" ) ret = new ScreenJukeboxMenu; + else if( sClassName=="ScreenOptionsMenu" ) ret = new ScreenOptionsMenu; + else if( sClassName=="ScreenSoundOptions" ) ret = new ScreenSoundOptions; + else if( sClassName=="ScreenGameplayOptions" ) ret = new ScreenGameplayOptions; + else if( sClassName=="ScreenStyleSplash" ) ret = new ScreenStyleSplash; + else if( sClassName=="ScreenAutogenOptions" ) ret = new ScreenAutogenOptions; + else if( sClassName=="ScreenCredits" ) ret = new ScreenCredits; + else if( sClassName=="ScreenSelectCharacter" ) ret = new ScreenSelectCharacter; else RageException::Throw( "Invalid Screen class name '%s'", sClassName.GetString() ); return ret; diff --git a/stepmania/src/Screen.h b/stepmania/src/Screen.h index ffa8a23a6d..36020f5722 100644 --- a/stepmania/src/Screen.h +++ b/stepmania/src/Screen.h @@ -22,7 +22,7 @@ class Screen : public ActorFrame { public: - Screen(); + Screen( CString sName ); // enforce that all screens have m_sName filled in virtual ~Screen(); virtual void AddChild( Actor* pActor ); diff --git a/stepmania/src/ScreenAttract.cpp b/stepmania/src/ScreenAttract.cpp index 7ae0444986..9718a88646 100644 --- a/stepmania/src/ScreenAttract.cpp +++ b/stepmania/src/ScreenAttract.cpp @@ -26,20 +26,18 @@ #include "SDL_utils.h" #include "RageSoundManager.h" -#define NEXT_SCREEN THEME->GetMetric(m_sClassName,"NextScreen") +#define NEXT_SCREEN THEME->GetMetric(m_sName,"NextScreen") -ScreenAttract::ScreenAttract( CString sClassName ) +ScreenAttract::ScreenAttract( CString sClassName ) : Screen( sClassName ) { LOG->Trace( "ScreenAttract::ScreenAttract(%s)", sClassName.c_str() ); GAMESTATE->Reset(); - m_sClassName = sClassName; - // We have to do initialization in the first update because this->GetElementName() won't // work until the object has been fully constructed. - m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations",m_sClassName+" background") ); + m_Background.LoadFromAniDir( THEME->GetPathTo("BGAnimations",m_sName+" background") ); this->AddChild( &m_Background ); m_In.Load( THEME->GetPathTo("BGAnimations","ScreenAttract in") ); @@ -49,11 +47,11 @@ ScreenAttract::ScreenAttract( CString sClassName ) m_Out.Load( THEME->GetPathTo("BGAnimations","ScreenAttract out") ); this->AddChild( &m_Out ); - SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo(m_sClassName) ); + SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo(m_sName) ); m_soundStart.Load( THEME->GetPathTo("Sounds","Common start") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds",m_sClassName + " music") ); // DO loop. -Chris + SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds",m_sName + " music") ); // DO loop. -Chris GAMESTATE->m_bPlayersCanJoin = true; diff --git a/stepmania/src/ScreenAttract.h b/stepmania/src/ScreenAttract.h index 974945575b..1e44f289d6 100644 --- a/stepmania/src/ScreenAttract.h +++ b/stepmania/src/ScreenAttract.h @@ -35,8 +35,6 @@ public: protected: - CString m_sClassName; // used to loop up theme metrics - BGAnimation m_Background; TransitionBGAnimation m_In; TransitionBGAnimation m_Out; diff --git a/stepmania/src/ScreenCaution.cpp b/stepmania/src/ScreenCaution.cpp index ddf668c3f9..86ff953250 100644 --- a/stepmania/src/ScreenCaution.cpp +++ b/stepmania/src/ScreenCaution.cpp @@ -27,7 +27,7 @@ const ScreenMessage SM_DoneOpening = ScreenMessage(SM_User-7); const ScreenMessage SM_StartClosing = ScreenMessage(SM_User-8); -ScreenCaution::ScreenCaution() +ScreenCaution::ScreenCaution() : Screen( "ScreenCaution" ) { GAMESTATE->m_bPlayersCanJoin = true; diff --git a/stepmania/src/ScreenCredits.cpp b/stepmania/src/ScreenCredits.cpp index 304e850223..a735d8c679 100644 --- a/stepmania/src/ScreenCredits.cpp +++ b/stepmania/src/ScreenCredits.cpp @@ -159,7 +159,7 @@ const CreditLine CREDIT_LINES[] = const unsigned NUM_CREDIT_LINES = sizeof(CREDIT_LINES) / sizeof(CreditLine); -ScreenCredits::ScreenCredits() +ScreenCredits::ScreenCredits() : Screen("ScreenCredits") { LOG->Trace( "ScreenCredits::ScreenCredits()" ); diff --git a/stepmania/src/ScreenEdit.cpp b/stepmania/src/ScreenEdit.cpp index 7db9d799a7..433c67a763 100644 --- a/stepmania/src/ScreenEdit.cpp +++ b/stepmania/src/ScreenEdit.cpp @@ -204,7 +204,7 @@ Menu g_BGChange ); -ScreenEdit::ScreenEdit() +ScreenEdit::ScreenEdit() : Screen("ScreenEdit") { LOG->Trace( "ScreenEdit::ScreenEdit()" ); @@ -1036,7 +1036,7 @@ void ScreenEdit::TransitionToEdit() m_soundMusic.StopPlaying(); m_rectRecordBack.StopTweening(); m_rectRecordBack.BeginTweening( 0.5f ); - m_rectRecordBack.SetTweenDiffuse( RageColor(0,0,0,0) ); + m_rectRecordBack.SetDiffuse( RageColor(0,0,0,0) ); /* Make sure we're snapped. */ GAMESTATE->m_fSongBeat = froundf( GAMESTATE->m_fSongBeat, NoteTypeToBeat(m_SnapDisplay.GetNoteType()) ); @@ -1409,7 +1409,7 @@ void ScreenEdit::HandleAreaMenuChoice( AreaMenuChoice c, int* iAnswers ) m_rectRecordBack.StopTweening(); m_rectRecordBack.BeginTweening( 0.5f ); - m_rectRecordBack.SetTweenDiffuse( RageColor(0,0,0,0.8f) ); + m_rectRecordBack.SetDiffuse( RageColor(0,0,0,0.8f) ); GAMESTATE->m_fSongBeat = m_NoteFieldEdit.m_fBeginMarker - 4; // give a 1 measure lead-in float fStartSeconds = m_pSong->GetElapsedTimeFromBeat(GAMESTATE->m_fSongBeat) ; @@ -1433,7 +1433,7 @@ void ScreenEdit::HandleAreaMenuChoice( AreaMenuChoice c, int* iAnswers ) m_rectRecordBack.StopTweening(); m_rectRecordBack.BeginTweening( 0.5f ); - m_rectRecordBack.SetTweenDiffuse( RageColor(0,0,0,0.8f) ); + m_rectRecordBack.SetDiffuse( RageColor(0,0,0,0.8f) ); GAMESTATE->m_fSongBeat = m_NoteFieldEdit.m_fBeginMarker - 4; // give a 1 measure lead-in float fStartSeconds = m_pSong->GetElapsedTimeFromBeat(GAMESTATE->m_fSongBeat); diff --git a/stepmania/src/ScreenEdit.h b/stepmania/src/ScreenEdit.h index f05d5b40a4..832b562145 100644 --- a/stepmania/src/ScreenEdit.h +++ b/stepmania/src/ScreenEdit.h @@ -17,7 +17,6 @@ #include "RandomSample.h" #include "RageSoundManager.h" #include "RageSound.h" -#include "MotionBlurSprite.h" #include "BGAnimation.h" #include "SnapDisplay.h" diff --git a/stepmania/src/ScreenEditMenu.cpp b/stepmania/src/ScreenEditMenu.cpp index f8267575ad..06f6d3fcf0 100644 --- a/stepmania/src/ScreenEditMenu.cpp +++ b/stepmania/src/ScreenEditMenu.cpp @@ -34,7 +34,7 @@ const ScreenMessage SM_RefreshSelector = (ScreenMessage)(SM_User+1); -ScreenEditMenu::ScreenEditMenu() +ScreenEditMenu::ScreenEditMenu() : Screen("ScreenEditMenu") { LOG->Trace( "ScreenEditMenu::ScreenEditMenu()" ); diff --git a/stepmania/src/ScreenEvaluation.cpp b/stepmania/src/ScreenEvaluation.cpp index 3b7eacaaa5..04430400cf 100644 --- a/stepmania/src/ScreenEvaluation.cpp +++ b/stepmania/src/ScreenEvaluation.cpp @@ -83,16 +83,16 @@ const char* JUDGE_STRING[NUM_JUDGE_LINES] = { "Marvelous", "Perfect", "Great", " #define SPIN_GRADES THEME->GetMetricB("ScreenEvaluation","SpinGrades") // metrics that are specific to classes derived from ScreenEvaluation -#define NEXT_SCREEN THEME->GetMetric (m_sClassName,"NextScreen") -#define END_SCREEN THEME->GetMetric (m_sClassName,"EndScreen") -#define SHOW_BANNER_AREA THEME->GetMetricB(m_sClassName,"ShowBannerArea") -#define SHOW_GRADE_AREA THEME->GetMetricB(m_sClassName,"ShowGradeArea") -#define SHOW_POINTS_AREA THEME->GetMetricB(m_sClassName,"ShowPointsArea") -#define SHOW_BONUS_AREA THEME->GetMetricB(m_sClassName,"ShowBonusArea") -#define SHOW_SURVIVED_AREA THEME->GetMetricB(m_sClassName,"ShowSurvivedArea") -#define SHOW_JUDGMENT( l ) THEME->GetMetricB(m_sClassName,ssprintf("Show%s",JUDGE_STRING[l])) -#define SHOW_SCORE_AREA THEME->GetMetricB(m_sClassName,"ShowScoreArea") -#define SHOW_TIME_AREA THEME->GetMetricB(m_sClassName,"ShowTimeArea") +#define NEXT_SCREEN THEME->GetMetric (m_sName,"NextScreen") +#define END_SCREEN THEME->GetMetric (m_sName,"EndScreen") +#define SHOW_BANNER_AREA THEME->GetMetricB(m_sName,"ShowBannerArea") +#define SHOW_GRADE_AREA THEME->GetMetricB(m_sName,"ShowGradeArea") +#define SHOW_POINTS_AREA THEME->GetMetricB(m_sName,"ShowPointsArea") +#define SHOW_BONUS_AREA THEME->GetMetricB(m_sName,"ShowBonusArea") +#define SHOW_SURVIVED_AREA THEME->GetMetricB(m_sName,"ShowSurvivedArea") +#define SHOW_JUDGMENT( l ) THEME->GetMetricB(m_sName,ssprintf("Show%s",JUDGE_STRING[l])) +#define SHOW_SCORE_AREA THEME->GetMetricB(m_sName,"ShowScoreArea") +#define SHOW_TIME_AREA THEME->GetMetricB(m_sName,"ShowTimeArea") const ScreenMessage SM_GoToSelectCourse = ScreenMessage(SM_User+3); @@ -101,7 +101,7 @@ const ScreenMessage SM_GoToEndScreen = ScreenMessage(SM_User+5); const ScreenMessage SM_PlayCheer = ScreenMessage(SM_User+6); -ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) +ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) : Screen(sClassName) { // // debugging @@ -122,7 +122,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) LOG->Trace( "ScreenEvaluation::ScreenEvaluation()" ); - m_sClassName = sClassName; + m_sName = sClassName; m_Type = type; @@ -241,7 +241,7 @@ ScreenEvaluation::ScreenEvaluation( CString sClassName, Type type ) - m_Menu.Load( m_sClassName ); + m_Menu.Load( m_sName ); this->AddChild( &m_Menu ); diff --git a/stepmania/src/ScreenEvaluation.h b/stepmania/src/ScreenEvaluation.h index 4a85c6573e..e9dc1273b1 100644 --- a/stepmania/src/ScreenEvaluation.h +++ b/stepmania/src/ScreenEvaluation.h @@ -44,7 +44,7 @@ public: virtual void MenuStart( PlayerNumber pn ); protected: - CString m_sClassName; + CString m_sName; Type m_Type; MenuElements m_Menu; diff --git a/stepmania/src/ScreenEz2SelectMusic.cpp b/stepmania/src/ScreenEz2SelectMusic.cpp index e227885ad6..b2202ab5c8 100644 --- a/stepmania/src/ScreenEz2SelectMusic.cpp +++ b/stepmania/src/ScreenEz2SelectMusic.cpp @@ -55,7 +55,7 @@ const float TWEEN_TIME = 0.5f; const ScreenMessage SM_NoSongs = ScreenMessage(SM_User+3); -ScreenEz2SelectMusic::ScreenEz2SelectMusic() +ScreenEz2SelectMusic::ScreenEz2SelectMusic() : Screen("ScreenEz2SelectMusic") { i_ErrorDetected=0; CodeDetector::RefreshCacheItems(); @@ -347,12 +347,12 @@ void ScreenEz2SelectMusic::MenuStart( PlayerNumber pn ) // show "hold START for options" m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,0) ); m_sprOptionsMessage.BeginTweening( 0.25f ); // fade in - m_sprOptionsMessage.SetTweenZoomY( 1 ); - m_sprOptionsMessage.SetTweenDiffuse( RageColor(1,1,1,1) ); + m_sprOptionsMessage.SetZoomY( 1 ); + m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,1) ); m_sprOptionsMessage.BeginTweening( 2.0f ); // sleep m_sprOptionsMessage.BeginTweening( 0.25f ); // fade out - m_sprOptionsMessage.SetTweenDiffuse( RageColor(1,1,1,0) ); - m_sprOptionsMessage.SetTweenZoomY( 0 ); + m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,0) ); + m_sprOptionsMessage.SetZoomY( 0 ); m_Menu.StartTransitioning( SM_GoToNextScreen ); } diff --git a/stepmania/src/ScreenEz2SelectPlayer.cpp b/stepmania/src/ScreenEz2SelectPlayer.cpp index de8837e89a..67d1bfd214 100644 --- a/stepmania/src/ScreenEz2SelectPlayer.cpp +++ b/stepmania/src/ScreenEz2SelectPlayer.cpp @@ -45,7 +45,7 @@ ScreenEz2SelectPlayer (Constructor) Desc: Sets up the screen display ************************************/ -ScreenEz2SelectPlayer::ScreenEz2SelectPlayer() +ScreenEz2SelectPlayer::ScreenEz2SelectPlayer() : Screen("ScreenEz2SelectPlayer") { // Unjoin the players, then let them join back in on this screen GAMESTATE->m_bPlayersCanJoin = true; @@ -219,9 +219,9 @@ void ScreenEz2SelectPlayer::MenuStart( PlayerNumber pn ) if( FOLD_ON_JOIN ) { m_sprJoinMessage[pn].BeginTweening( 0.25f ); - m_sprJoinMessage[pn].SetTweenZoomY( 0 ); + m_sprJoinMessage[pn].SetZoomY( 0 ); m_sprJoinFrame[pn].BeginTweening( 0.25f ); - m_sprJoinFrame[pn].SetTweenZoomY( 0 ); + m_sprJoinFrame[pn].SetZoomY( 0 ); } bool bBothSidesJoined = true; @@ -254,12 +254,12 @@ void ScreenEz2SelectPlayer::TweenOnScreen() fOriginalX = m_sprJoinMessage[p].GetX(); m_sprJoinMessage[p].SetX( m_sprJoinMessage[p].GetX()+fOffScreenOffset ); m_sprJoinMessage[p].BeginTweening( 0.5f, Actor::TWEEN_BOUNCE_END ); - m_sprJoinMessage[p].SetTweenX( fOriginalX ); + m_sprJoinMessage[p].SetX( fOriginalX ); fOriginalX = m_sprJoinFrame[p].GetX(); m_sprJoinFrame[p].SetX( m_sprJoinMessage[p].GetX()+fOffScreenOffset ); m_sprJoinFrame[p].BeginTweening( 0.5f, Actor::TWEEN_BOUNCE_END ); - m_sprJoinFrame[p].SetTweenX( fOriginalX ); + m_sprJoinFrame[p].SetX( fOriginalX ); } } @@ -270,8 +270,8 @@ void ScreenEz2SelectPlayer::TweenOffScreen() float fOffScreenOffset = float( (p==PLAYER_1) ? -SCREEN_WIDTH : +SCREEN_WIDTH ); m_sprJoinMessage[p].BeginTweening( 0.5f, Actor::TWEEN_DECELERATE ); - m_sprJoinMessage[p].SetTweenX( m_sprJoinMessage[p].GetX()+fOffScreenOffset ); + m_sprJoinMessage[p].SetX( m_sprJoinMessage[p].GetX()+fOffScreenOffset ); m_sprJoinFrame[p].BeginTweening( 0.5f, Actor::TWEEN_DECELERATE ); - m_sprJoinFrame[p].SetTweenX( m_sprJoinMessage[p].GetX()+fOffScreenOffset ); + m_sprJoinFrame[p].SetX( m_sprJoinMessage[p].GetX()+fOffScreenOffset ); } } diff --git a/stepmania/src/ScreenGameOver.cpp b/stepmania/src/ScreenGameOver.cpp index d907821af5..fe0ba5d184 100644 --- a/stepmania/src/ScreenGameOver.cpp +++ b/stepmania/src/ScreenGameOver.cpp @@ -25,7 +25,7 @@ const ScreenMessage SM_PlayAnnouncer = ScreenMessage(SM_User + 3); #define NEXT_SCREEN THEME->GetMetric("ScreenGameOver","NextScreen") -ScreenGameOver::ScreenGameOver() +ScreenGameOver::ScreenGameOver() : Screen("ScreenGameOver") { GAMESTATE->Reset(); diff --git a/stepmania/src/ScreenGameplay.cpp b/stepmania/src/ScreenGameplay.cpp index 464f0b17d3..322885f852 100644 --- a/stepmania/src/ScreenGameplay.cpp +++ b/stepmania/src/ScreenGameplay.cpp @@ -105,7 +105,7 @@ const ScreenMessage SM_StartHereWeGo = ScreenMessage(SM_User+40); const ScreenMessage SM_StopHereWeGo = ScreenMessage(SM_User+41); -ScreenGameplay::ScreenGameplay( bool bDemonstration ) +ScreenGameplay::ScreenGameplay( bool bDemonstration ) : Screen("ScreenGameplay") { LOG->Trace( "ScreenGameplay::ScreenGameplay()" ); @@ -626,7 +626,7 @@ void ScreenGameplay::LoadNextSong() m_Background.LoadFromSong( GAMESTATE->m_pCurSong ); m_Background.SetDiffuse( RageColor(0.5f,0.5f,0.5f,1) ); m_Background.BeginTweening( 2 ); - m_Background.SetTweenDiffuse( RageColor(1,1,1,1) ); + m_Background.SetDiffuse( RageColor(1,1,1,1) ); m_textSongTitle.SetText( GAMESTATE->m_pCurSong->m_sMainTitle ); @@ -970,7 +970,7 @@ void ScreenGameplay::Input( const DeviceInput& DeviceI, const InputEventType typ m_textDebug.StopTweening(); m_textDebug.SetDiffuse( RageColor(1,1,1,0) ); m_textDebug.BeginTweening( 1/8.f ); - m_textDebug.SetTweenDiffuse( RageColor(1,1,1,1) ); + m_textDebug.SetDiffuse( RageColor(1,1,1,1) ); return; } @@ -978,7 +978,7 @@ void ScreenGameplay::Input( const DeviceInput& DeviceI, const InputEventType typ { m_textDebug.StopTweening(); m_textDebug.BeginTweening( 1/8.f ); - m_textDebug.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textDebug.SetDiffuse( RageColor(1,1,1,0) ); return; } @@ -1028,7 +1028,7 @@ void ScreenGameplay::Input( const DeviceInput& DeviceI, const InputEventType typ m_textDebug.StopTweening(); m_textDebug.BeginTweening( 3 ); // sleep m_textDebug.BeginTweening( 0.5f ); // fade out - m_textDebug.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textDebug.SetDiffuse( RageColor(1,1,1,0) ); break; case SDLK_F8: { @@ -1062,7 +1062,7 @@ void ScreenGameplay::Input( const DeviceInput& DeviceI, const InputEventType typ m_textDebug.StopTweening(); m_textDebug.BeginTweening( 3 ); // sleep m_textDebug.BeginTweening( 0.5f ); // fade out - m_textDebug.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textDebug.SetDiffuse( RageColor(1,1,1,0) ); } break; case SDLK_F11: @@ -1087,7 +1087,7 @@ void ScreenGameplay::Input( const DeviceInput& DeviceI, const InputEventType typ m_textDebug.StopTweening(); m_textDebug.BeginTweening( 3 ); // sleep m_textDebug.BeginTweening( 0.5f ); // fade out - m_textDebug.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textDebug.SetDiffuse( RageColor(1,1,1,0) ); } break; } @@ -1406,10 +1406,10 @@ void ScreenGameplay::HandleScreenMessage( const ScreenMessage SM ) /* // received while STATE_OUTRO case SM_ShowCleared: m_sprCleared.BeginTweening(1.0f); - m_sprCleared.SetTweenDiffuse( RageColor(1,1,1,1) ); + m_sprCleared.SetDiffuse( RageColor(1,1,1,1) ); m_sprCleared.BeginTweening(1.5f); // sleep m_sprCleared.BeginTweening(0.7f); - m_sprCleared.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_sprCleared.SetDiffuse( RageColor(1,1,1,0) ); SCREENMAN->PostMessageToTopScreen( SM_GoToStateAfterCleared, 4 ); break; */ @@ -1419,27 +1419,27 @@ void ScreenGameplay::HandleScreenMessage( const ScreenMessage SM ) // make the background invisible so we don't waste mem bandwidth drawing it m_Background.BeginTweening( 1 ); - m_Background.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_Background.SetDiffuse( RageColor(1,1,1,0) ); RageColor colorStage = GAMESTATE->GetStageColor(); colorStage.a *= 0.7f; m_sprTryExtraStage.SetZoom( 4 ); m_sprTryExtraStage.BeginBlurredTweening( 0.8f, TWEEN_DECELERATE ); - m_sprTryExtraStage.SetTweenZoom( 0.4f ); // zoom out - m_sprTryExtraStage.SetTweenDiffuse( colorStage ); // and fade in + m_sprTryExtraStage.SetZoom( 0.4f ); // zoom out + m_sprTryExtraStage.SetDiffuse( colorStage ); // and fade in m_sprTryExtraStage.BeginTweening( 0.2f ); - m_sprTryExtraStage.SetTweenZoom( 0.8f ); // bounce - m_sprTryExtraStage.SetTweenDiffuse( colorStage ); // and fade in + m_sprTryExtraStage.SetZoom( 0.8f ); // bounce + m_sprTryExtraStage.SetDiffuse( colorStage ); // and fade in m_sprTryExtraStage.BeginTweening( 0.2f ); - m_sprTryExtraStage.SetTweenZoom( 1.0f ); // come to rest - m_sprTryExtraStage.SetTweenDiffuse( colorStage ); // and fade in + m_sprTryExtraStage.SetZoom( 1.0f ); // come to rest + m_sprTryExtraStage.SetDiffuse( colorStage ); // and fade in colorStage.a = 0; m_sprTryExtraStage.BeginTweening( 2 ); // sleep m_sprTryExtraStage.BeginTweening( 1 ); // fade out - m_sprTryExtraStage.SetTweenDiffuse( colorStage ); + m_sprTryExtraStage.SetDiffuse( colorStage ); SCREENMAN->PostMessageToTopScreen( SM_GoToStateAfterCleared, 5 ); } break; @@ -1514,7 +1514,7 @@ void ScreenGameplay::HandleScreenMessage( const ScreenMessage SM ) // make the background invisible so we don't waste power drawing it m_Background.BeginTweening( 1 ); - m_Background.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_Background.SetDiffuse( RageColor(1,1,1,0) ); // show the survive time if extra stage // TODO: Move this animation to a metric? @@ -1528,10 +1528,10 @@ void ScreenGameplay::HandleScreenMessage( const ScreenMessage SM ) m_textSurviveTime.SetText( "TIME: " + SecondsToTime(fMaxSurviveSeconds) ); m_textSurviveTime.BeginTweening( 0.3f ); // sleep m_textSurviveTime.BeginTweening( 0.3f ); // fade in - m_textSurviveTime.SetTweenDiffuse( RageColor(1,1,1,1) ); + m_textSurviveTime.SetDiffuse( RageColor(1,1,1,1) ); m_textSurviveTime.BeginTweening( 3.5f ); // sleep m_textSurviveTime.BeginTweening( 0.5f ); // fade out - m_textSurviveTime.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textSurviveTime.SetDiffuse( RageColor(1,1,1,0) ); } SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo("gameplay failed") ); @@ -1594,7 +1594,7 @@ void ScreenGameplay::TweenOnScreen() apActorsInLifeFrame[i]->SetY( fOriginalY-100 ); apActorsInLifeFrame[i]->BeginTweening( 0.5f ); // sleep apActorsInLifeFrame[i]->BeginTweening( 1 ); - apActorsInLifeFrame[i]->SetTweenY( fOriginalY ); + apActorsInLifeFrame[i]->SetY( fOriginalY ); } @@ -1614,7 +1614,7 @@ void ScreenGameplay::TweenOnScreen() apActorsInScoreFrame[i]->SetY( fOriginalY+100 ); apActorsInScoreFrame[i]->BeginTweening( 0.5f ); // sleep apActorsInScoreFrame[i]->BeginTweening( 1 ); - apActorsInScoreFrame[i]->SetTweenY( fOriginalY ); + apActorsInScoreFrame[i]->SetY( fOriginalY ); } for( p=0; pGetMetric("ScreenInstructions","NextScreenRave") -ScreenInstructions::ScreenInstructions() +ScreenInstructions::ScreenInstructions() : Screen("ScreenInstructions") { LOG->Trace( "ScreenInstructions::ScreenInstructions()" ); @@ -74,7 +74,7 @@ ScreenInstructions::ScreenInstructions() m_sprHowToPlay.SetX( SCREEN_LEFT-SCREEN_WIDTH ); m_sprHowToPlay.BeginTweening( 0.4f ); // sleep m_sprHowToPlay.BeginTweening( 0.6f, Actor::TWEEN_DECELERATE ); - m_sprHowToPlay.SetTweenX( CENTER_X ); + m_sprHowToPlay.SetX( CENTER_X ); SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds","ScreenInstructions music") ); } @@ -152,5 +152,5 @@ void ScreenInstructions::MenuStart( PlayerNumber pn ) m_sprHowToPlay.StopTweening(); m_sprHowToPlay.BeginTweening( 0.3f, Actor::TWEEN_ACCELERATE ); - m_sprHowToPlay.SetTweenX( SCREEN_RIGHT+m_sprHowToPlay.GetUnzoomedWidth()/2 ); + m_sprHowToPlay.SetX( SCREEN_RIGHT+m_sprHowToPlay.GetUnzoomedWidth()/2 ); } diff --git a/stepmania/src/ScreenJukeboxMenu.cpp b/stepmania/src/ScreenJukeboxMenu.cpp index 142a850e46..5f4b277f27 100644 --- a/stepmania/src/ScreenJukeboxMenu.cpp +++ b/stepmania/src/ScreenJukeboxMenu.cpp @@ -33,7 +33,7 @@ #define HELP_TEXT THEME->GetMetric("ScreenJukeboxMenu","HelpText") -ScreenJukeboxMenu::ScreenJukeboxMenu() +ScreenJukeboxMenu::ScreenJukeboxMenu() : Screen("ScreenJukeboxMenu") { LOG->Trace( "ScreenJukeboxMenu::ScreenJukeboxMenu()" ); diff --git a/stepmania/src/ScreenManager.cpp b/stepmania/src/ScreenManager.cpp index f7699d423a..4d49d9de14 100644 --- a/stepmania/src/ScreenManager.cpp +++ b/stepmania/src/ScreenManager.cpp @@ -63,7 +63,7 @@ public: void Update( float fDeltaTime ); }; -ScreenSystemLayer::ScreenSystemLayer() +ScreenSystemLayer::ScreenSystemLayer() : Screen("ScreenSystemLayer") { m_textSystemMessage.LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); m_textSystemMessage.SetHorizAlign( Actor::align_left ); diff --git a/stepmania/src/ScreenMapControllers.cpp b/stepmania/src/ScreenMapControllers.cpp index 04a5bca44a..c64e6d8269 100644 --- a/stepmania/src/ScreenMapControllers.cpp +++ b/stepmania/src/ScreenMapControllers.cpp @@ -41,8 +41,7 @@ const float BUTTON_COLUMN_X[NUM_GAME_TO_DEVICE_SLOTS*MAX_GAME_CONTROLLERS] = }; - -ScreenMapControllers::ScreenMapControllers() +ScreenMapControllers::ScreenMapControllers() : Screen("ScreenMapControllers") { LOG->Trace( "ScreenMapControllers::ScreenMapControllers()" ); @@ -149,7 +148,7 @@ void ScreenMapControllers::Input( const DeviceInput& DeviceI, const InputEventTy m_textError.SetDiffuse( RageColor(0,1,0,1) ); m_textError.BeginTweening( 3 ); m_textError.BeginTweening( 1 ); - m_textError.SetTweenDiffuse( RageColor(0,1,0,0) ); + m_textError.SetDiffuse( RageColor(0,1,0,0) ); return; } @@ -171,7 +170,7 @@ void ScreenMapControllers::Input( const DeviceInput& DeviceI, const InputEventTy m_textError.SetDiffuse( RageColor(0,1,0,1) ); m_textError.BeginTweening( 3 ); m_textError.BeginTweening( 1 ); - m_textError.SetTweenDiffuse( RageColor(0,1,0,0) ); + m_textError.SetDiffuse( RageColor(0,1,0,0) ); return; // ignore this press } diff --git a/stepmania/src/ScreenMiniMenu.cpp b/stepmania/src/ScreenMiniMenu.cpp index aea334030d..29e9ec0f95 100644 --- a/stepmania/src/ScreenMiniMenu.cpp +++ b/stepmania/src/ScreenMiniMenu.cpp @@ -38,7 +38,8 @@ int ScreenMiniMenu::s_iLastLine; int ScreenMiniMenu::s_iLastAnswers[MAX_MENU_ROWS]; -ScreenMiniMenu::ScreenMiniMenu( Menu* pDef, ScreenMessage SM_SendOnOK, ScreenMessage SM_SendOnCancel ) +ScreenMiniMenu::ScreenMiniMenu( Menu* pDef, ScreenMessage SM_SendOnOK, ScreenMessage SM_SendOnCancel ) : + Screen("ScreenMiniMenu") { m_bIsTransparent = true; // draw screens below us diff --git a/stepmania/src/ScreenMusicScroll.cpp b/stepmania/src/ScreenMusicScroll.cpp index 96a8b58bdb..53a3545c79 100644 --- a/stepmania/src/ScreenMusicScroll.cpp +++ b/stepmania/src/ScreenMusicScroll.cpp @@ -36,7 +36,7 @@ const CString CREDIT_LINES[] = const unsigned NUM_CREDIT_LINES = sizeof(CREDIT_LINES) / sizeof(CString); -ScreenMusicScroll::ScreenMusicScroll() +ScreenMusicScroll::ScreenMusicScroll() : Screen("ScreenMusicScroll") { LOG->Trace( "ScreenMusicScroll::ScreenMusicScroll()" ); @@ -79,7 +79,7 @@ ScreenMusicScroll::ScreenMusicScroll() m_textLines[i].SetXY( CENTER_X, SCREEN_BOTTOM + 40 ); m_textLines[i].BeginTweening( SCROLL_DELAY * i ); m_textLines[i].BeginTweening( 2.0f*SCROLL_SPEED ); - m_textLines[i].SetTweenXY( CENTER_X, SCREEN_TOP - 40 ); + m_textLines[i].SetXY( CENTER_X, SCREEN_TOP - 40 ); } this->PostScreenMessage( SM_BeginFadingOut, 0.2f * i + 3.0f ); diff --git a/stepmania/src/ScreenNameEntry.cpp b/stepmania/src/ScreenNameEntry.cpp index d2cdf43eea..da31c28727 100644 --- a/stepmania/src/ScreenNameEntry.cpp +++ b/stepmania/src/ScreenNameEntry.cpp @@ -87,7 +87,7 @@ float GetClosestCharYPos( float fFakeBeat ) } -ScreenNameEntry::ScreenNameEntry() +ScreenNameEntry::ScreenNameEntry() : Screen("ScreenNameEntry") { LOG->Trace( "ScreenNameEntry::ScreenNameEntry()" ); diff --git a/stepmania/src/ScreenOptions.cpp b/stepmania/src/ScreenOptions.cpp index 35ac33f53a..bc1b33bfdd 100644 --- a/stepmania/src/ScreenOptions.cpp +++ b/stepmania/src/ScreenOptions.cpp @@ -42,11 +42,11 @@ const float ITEM_X[NUM_PLAYERS] = { 260, 420 }; #define COLOR_NOT_SELECTED THEME->GetMetricC("ScreenOptions","ColorNotSelected") -ScreenOptions::ScreenOptions( CString sClassName, bool bEnableTimer ) +ScreenOptions::ScreenOptions( CString sClassName, bool bEnableTimer ) : Screen("ScreenOptions") { LOG->Trace( "ScreenOptions::ScreenOptions()" ); - m_sClassName = sClassName; + m_sName = sClassName; m_SoundChangeCol.Load( THEME->GetPathTo("Sounds","ScreenOptions change") ); m_SoundNextRow.Load( THEME->GetPathTo("Sounds","ScreenOptions next") ); @@ -73,7 +73,7 @@ ScreenOptions::ScreenOptions( CString sClassName, bool bEnableTimer ) m_framePage.SetX( SCREEN_LEFT-SCREEN_WIDTH ); m_framePage.BeginTweening( 0.3f, Actor::TWEEN_DECELERATE ); - m_framePage.SetTweenX( 0 ); + m_framePage.SetX( 0 ); memset(&m_OptionDim, 0, sizeof(m_OptionDim)); memset(&m_bRowIsLong, 0, sizeof(m_bRowIsLong)); } @@ -263,9 +263,9 @@ void ScreenOptions::DimOption(int line, int option, bool dim) m_textItems[line][option].StopTweening(); m_textItems[line][option].BeginTweening(.250); if(m_OptionDim[line][option]) - m_textItems[line][option].SetTweenDiffuse( RageColor(.5,.5,.5,1) ); + m_textItems[line][option].SetDiffuse( RageColor(.5,.5,.5,1) ); else - m_textItems[line][option].SetTweenDiffuse( RageColor(1,1,1,1) ); + m_textItems[line][option].SetDiffuse( RageColor(1,1,1,1) ); } bool ScreenOptions::RowCompletelyDimmed(int line) const @@ -361,7 +361,7 @@ void ScreenOptions::TweenCursor( PlayerNumber player_no ) highlight.StopTweening(); highlight.BeginTweening( 0.2f ); highlight.TweenBarWidth( iWidth ); - highlight.SetTweenXY( (float)iX, (float)iY ); + highlight.SetXY( (float)iX, (float)iY ); } void ScreenOptions::UpdateText( PlayerNumber player_no ) @@ -460,7 +460,7 @@ void ScreenOptions::HandleScreenMessage( const ScreenMessage SM ) m_SoundStart.Play(); m_framePage.BeginTweening( 0.3f, Actor::TWEEN_ACCELERATE ); - m_framePage.SetTweenX( SCREEN_RIGHT ); + m_framePage.SetX( SCREEN_RIGHT ); break; } } @@ -483,7 +483,7 @@ void ScreenOptions::OnChange() sLineName = m_OptionRow[iCurRow].choices[0]; sLineName.Replace("\n",""); sLineName.Replace(" ",""); - m_textExplanation.SetText( THEME->GetMetric(m_sClassName,sLineName) ); + m_textExplanation.SetText( THEME->GetMetric(m_sName,sLineName) ); } else m_textExplanation.SetText( "" ); diff --git a/stepmania/src/ScreenOptions.h b/stepmania/src/ScreenOptions.h index cebc445162..d6907f98d8 100644 --- a/stepmania/src/ScreenOptions.h +++ b/stepmania/src/ScreenOptions.h @@ -84,7 +84,7 @@ protected: void MenuUp( PlayerNumber pn ); void MenuDown( PlayerNumber pn ); - CString m_sClassName; + CString m_sName; InputMode m_InputMode; bool m_bUseIcons; bool m_bLoadExplanations; diff --git a/stepmania/src/ScreenPrompt.cpp b/stepmania/src/ScreenPrompt.cpp index 5c54adb4f4..2894dbded6 100644 --- a/stepmania/src/ScreenPrompt.cpp +++ b/stepmania/src/ScreenPrompt.cpp @@ -26,7 +26,8 @@ const float PROMPT_X = CENTER_X; const float PROMPT_Y = CENTER_Y + 120; -ScreenPrompt::ScreenPrompt( ScreenMessage SM_SendWhenDone, CString sText, bool bYesNoPrompt, bool bDefaultAnswer, void(*OnYes)(), void(*OnNo)() ) +ScreenPrompt::ScreenPrompt( ScreenMessage SM_SendWhenDone, CString sText, bool bYesNoPrompt, bool bDefaultAnswer, void(*OnYes)(), void(*OnNo)() ) : + Screen("ScreenPrompt") { m_bIsTransparent = true; // draw screens below us @@ -148,8 +149,8 @@ void ScreenPrompt::MenuRight( PlayerNumber pn ) m_rectAnswerBox.StopTweening(); m_rectAnswerBox.BeginTweening( 0.2f ); - m_rectAnswerBox.SetTweenXY( m_textAnswer[m_bAnswer].GetX(), m_textAnswer[m_bAnswer].GetY() ); - m_rectAnswerBox.SetTweenZoomX( m_textAnswer[m_bAnswer].GetWidestLineWidthInSourcePixels()+10.0f ); + m_rectAnswerBox.SetXY( m_textAnswer[m_bAnswer].GetX(), m_textAnswer[m_bAnswer].GetY() ); + m_rectAnswerBox.SetZoomX( m_textAnswer[m_bAnswer].GetWidestLineWidthInSourcePixels()+10.0f ); SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","ScreenPrompt change") ); } @@ -159,17 +160,17 @@ void ScreenPrompt::MenuStart( PlayerNumber pn ) m_Fade.OpenWipingRight( SM_DoneOpeningWipingRight ); m_textQuestion.BeginTweening( 0.2f ); - m_textQuestion.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textQuestion.SetDiffuse( RageColor(1,1,1,0) ); m_rectAnswerBox.BeginTweening( 0.2f ); - m_rectAnswerBox.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_rectAnswerBox.SetDiffuse( RageColor(1,1,1,0) ); m_textAnswer[m_bAnswer].SetEffectNone(); m_textAnswer[0].BeginTweening( 0.2f ); - m_textAnswer[0].SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textAnswer[0].SetDiffuse( RageColor(1,1,1,0) ); m_textAnswer[1].BeginTweening( 0.2f ); - m_textAnswer[1].SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textAnswer[1].SetDiffuse( RageColor(1,1,1,0) ); SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); diff --git a/stepmania/src/ScreenSandbox.cpp b/stepmania/src/ScreenSandbox.cpp index 7617f49f35..2ec66f75f4 100644 --- a/stepmania/src/ScreenSandbox.cpp +++ b/stepmania/src/ScreenSandbox.cpp @@ -19,7 +19,7 @@ #include "GameConstantsAndTypes.h" -ScreenSandbox::ScreenSandbox() +ScreenSandbox::ScreenSandbox() : Screen("ScreenSandbox") { m_quad.StretchTo( RectI(SCREEN_LEFT, SCREEN_TOP, SCREEN_RIGHT, SCREEN_BOTTOM) ); m_quad.SetDiffuse( RageColor(1,1,1,1) ); diff --git a/stepmania/src/ScreenSelect.cpp b/stepmania/src/ScreenSelect.cpp index 7c2bbfcbea..50f1b77721 100644 --- a/stepmania/src/ScreenSelect.cpp +++ b/stepmania/src/ScreenSelect.cpp @@ -26,17 +26,17 @@ #include "ModeChoice.h" -#define CHOICES THEME->GetMetric (m_sClassName,"Choices") -#define HELP_TEXT THEME->GetMetric (m_sClassName,"HelpText") -#define TIMER_SECONDS THEME->GetMetricI(m_sClassName,"TimerSeconds") -#define NEXT_SCREEN( choice ) THEME->GetMetric (m_sClassName,ssprintf("NextScreen%d",choice+1)) +#define CHOICES THEME->GetMetric (m_sName,"Choices") +#define HELP_TEXT THEME->GetMetric (m_sName,"HelpText") +#define TIMER_SECONDS THEME->GetMetricI(m_sName,"TimerSeconds") +#define NEXT_SCREEN( choice ) THEME->GetMetric (m_sName,ssprintf("NextScreen%d",choice+1)) -ScreenSelect::ScreenSelect( CString sClassName ) +ScreenSelect::ScreenSelect( CString sClassName ) : Screen(sClassName) { LOG->Trace( "ScreenSelect::ScreenSelect()" ); - m_sClassName = sClassName; + m_sName = sClassName; GAMESTATE->m_bPlayersCanJoin = false; // Set this true later if we discover a choice that chooses the Style @@ -122,18 +122,18 @@ ScreenSelect::ScreenSelect( CString sClassName ) m_aModeChoices.push_back( mc ); - CString sBGAnimationDir = THEME->GetPathToOptional("BGAnimations",ssprintf("%s %s",m_sClassName.GetString(),mc.name)); + CString sBGAnimationDir = THEME->GetPathToOptional("BGAnimations",ssprintf("%s %s",m_sName.GetString(),mc.name)); if( sBGAnimationDir == "" ) - sBGAnimationDir = THEME->GetPathTo("BGAnimations",m_sClassName+" background"); + sBGAnimationDir = THEME->GetPathTo("BGAnimations",m_sName+" background"); m_BGAnimations[c].LoadFromAniDir( sBGAnimationDir ); } m_Menu.Load( sClassName ); this->AddChild( &m_Menu ); - SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo(m_sClassName+" intro") ); + SOUNDMAN->PlayOnceFromDir( ANNOUNCER->GetPathTo(m_sName+" intro") ); - SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds",m_sClassName+" music") ); + SOUNDMAN->PlayMusic( THEME->GetPathTo("Sounds",m_sName+" music") ); } diff --git a/stepmania/src/ScreenSelect.h b/stepmania/src/ScreenSelect.h index 6a546d68da..8bbbb62107 100644 --- a/stepmania/src/ScreenSelect.h +++ b/stepmania/src/ScreenSelect.h @@ -39,7 +39,7 @@ protected: virtual int GetSelectionIndex( PlayerNumber pn ) = 0; virtual void UpdateSelectableChoices() = 0; // derived screens must handle this - CString m_sClassName; + CString m_sName; MenuElements m_Menu; BGAnimation m_BGAnimations[MAX_CHOICES]; diff --git a/stepmania/src/ScreenSelectCharacter.cpp b/stepmania/src/ScreenSelectCharacter.cpp index 4db477b19f..c321ffa1d9 100644 --- a/stepmania/src/ScreenSelectCharacter.cpp +++ b/stepmania/src/ScreenSelectCharacter.cpp @@ -44,7 +44,7 @@ const PlayerNumber CPU_PLAYER[NUM_PLAYERS] = { PLAYER_2, PLAYER_1 }; -ScreenSelectCharacter::ScreenSelectCharacter() +ScreenSelectCharacter::ScreenSelectCharacter() : Screen("ScreenSelectCharacter") { LOG->Trace( "ScreenSelectCharacter::ScreenSelectCharacter()" ); diff --git a/stepmania/src/ScreenSelectCourse.cpp b/stepmania/src/ScreenSelectCourse.cpp index 7fc7be3d2a..a09eb62ede 100644 --- a/stepmania/src/ScreenSelectCourse.cpp +++ b/stepmania/src/ScreenSelectCourse.cpp @@ -56,7 +56,7 @@ static const ScreenMessage SM_AllowOptionsMenuRepeat = ScreenMessage(SM_User+1); -ScreenSelectCourse::ScreenSelectCourse() +ScreenSelectCourse::ScreenSelectCourse() : Screen("ScreenSelectCourse") { LOG->Trace( "ScreenSelectCourse::ScreenSelectCourse()" ); @@ -346,12 +346,12 @@ void ScreenSelectCourse::MenuStart( PlayerNumber pn ) // show "hold START for options" m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,0) ); m_sprOptionsMessage.BeginTweening( 0.15f ); // fade in - m_sprOptionsMessage.SetTweenZoomY( 1 ); - m_sprOptionsMessage.SetTweenDiffuse( RageColor(1,1,1,1) ); + m_sprOptionsMessage.SetZoomY( 1 ); + m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,1) ); m_sprOptionsMessage.BeginTweening( fShowSeconds-0.35f ); // sleep m_sprOptionsMessage.BeginTweening( 0.15f ); // fade out - m_sprOptionsMessage.SetTweenDiffuse( RageColor(1,1,1,0) ); - m_sprOptionsMessage.SetTweenZoomY( 0 ); + m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,0) ); + m_sprOptionsMessage.SetZoomY( 0 ); /* Don't accept a held START for a little while, so it's not * hit accidentally. Accept an initial START right away, though, diff --git a/stepmania/src/ScreenSelectDifficulty.cpp b/stepmania/src/ScreenSelectDifficulty.cpp index 6a3e0b7abe..721c4e210c 100644 --- a/stepmania/src/ScreenSelectDifficulty.cpp +++ b/stepmania/src/ScreenSelectDifficulty.cpp @@ -19,36 +19,25 @@ #include "AnnouncerManager.h" #include "ModeChoice.h" +#define SET_XY( actor ) actor.SetXY( THEME->GetMetricF(m_sName,actor.GetName()+"X"), THEME->GetMetricF(m_sName,actor.GetName()+"Y") ) +#define ON_COMMAND( actor ) actor.Command( THEME->GetMetric(m_sName,actor.GetName()+"OnCommand") ) +#define OFF_COMMAND( actor ) actor.Command( THEME->GetMetric(m_sName,actor.GetName()+"OffCommand") ) +#define SET_XY_AND_ON_COMMAND( actor ) SET_XY(actor); ON_COMMAND(actor) #define NUM_CHOICES_ON_PAGE_1 THEME->GetMetricI("ScreenSelectDifficulty","NumChoicesOnPage1") #define LOCK_INPUT_SECONDS THEME->GetMetricF("ScreenSelectDifficulty","LockInputSeconds") #define SLEEP_AFTER_CHOICE_SECONDS THEME->GetMetricF("ScreenSelectDifficulty","SleepAfterChoiceSeconds") #define SLEEP_AFTER_TWEEN_OFF_SECONDS THEME->GetMetricF("ScreenSelectDifficulty","SleepAfterTweenOffSeconds") -#define MORE_ON_COMMAND( page ) THEME->GetMetric ("ScreenSelectDifficulty",ssprintf("MorePage%dOnCommand",page+1)) -#define MORE_OFF_COMMAND( page ) THEME->GetMetric ("ScreenSelectDifficulty",ssprintf("MorePage%dOffCommand",page+1)) -#define EXPLANATION_ON_COMMAND( page ) THEME->GetMetric ("ScreenSelectDifficulty",ssprintf("ExplanationPage%dOnCommand",page+1)) -#define EXPLANATION_OFF_COMMAND( page ) THEME->GetMetric ("ScreenSelectDifficulty",ssprintf("ExplanationPage%dOffCommand",page+1)) -#define INFO_ON_COMMAND( page, choice ) THEME->GetMetric ("ScreenSelectDifficulty",ssprintf("InfoPage%dChoice%dOnCommand",page+1,choice+1)) -#define INFO_OFF_COMMAND( page, choice ) THEME->GetMetric ("ScreenSelectDifficulty",ssprintf("InfoPage%dChoice%dOffCommand",page+1,choice+1)) -#define PICTURE_ON_COMMAND( page, choice ) THEME->GetMetric ("ScreenSelectDifficulty",ssprintf("PicturePage%dChoice%dOnCommand",page+1,choice+1)) -#define PICTURE_OFF_COMMAND( page, choice ) THEME->GetMetric ("ScreenSelectDifficulty",ssprintf("PicturePage%dChoice%dOffCommand",page+1,choice+1)) -#define CURSOR_ON_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","CursorOnCommand") #define CURSOR_CHOOSE_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","CursorChooseCommand") -#define CURSOR_OFF_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","CursorOffCommand") #define CURSOR_OFFSET_X_FROM_PICTURE( p ) THEME->GetMetricF("ScreenSelectDifficulty",ssprintf("CursorP%dOffsetXFromPicture",p+1)) #define CURSOR_OFFSET_Y_FROM_PICTURE( p ) THEME->GetMetricF("ScreenSelectDifficulty",ssprintf("CursorP%dOffsetYFromPicture",p+1)) -#define SHADOW_ON_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","ShadowOnCommand") #define SHADOW_CHOOSE_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","ShadowChooseCommand") -#define SHADOW_OFF_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","ShadowOffCommand") #define SHADOW_LENGTH_X THEME->GetMetricF("ScreenSelectDifficulty","ShadowLengthX") #define SHADOW_LENGTH_Y THEME->GetMetricF("ScreenSelectDifficulty","ShadowLengthY") -#define OK_ON_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","OKOnCommand") #define OK_CHOOSE_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","OKChooseCommand") -#define OK_OFF_COMMAND THEME->GetMetric ("ScreenSelectDifficulty","OKOffCommand") #define DISABLED_COLOR THEME->GetMetricC("ScreenSelectDifficulty","DisabledColor") - ScreenSelectDifficulty::ScreenSelectDifficulty() : ScreenSelect( "ScreenSelectDifficulty" ) { m_CurrentPage = PAGE_1; @@ -75,17 +64,20 @@ ScreenSelectDifficulty::ScreenSelectDifficulty() : ScreenSelect( "ScreenSelectDi CString sInfoFile = ssprintf( "ScreenSelectDifficulty info %s", m_ModeChoices[page][choice].name ); CString sPictureFile = ssprintf( "ScreenSelectDifficulty picture %s", m_ModeChoices[page][choice].name ); + m_sprPicture[page][choice].SetName( ssprintf("PicturePage%dChoice%d",page+1,choice+1) ); m_sprPicture[page][choice].Load( THEME->GetPathTo("Graphics",sPictureFile) ); m_framePages.AddChild( &m_sprPicture[page][choice] ); + m_sprInfo[page][choice].SetName( ssprintf("InfoPage%dChoice%d",page+1,choice+1) ); m_sprInfo[page][choice].Load( THEME->GetPathTo("Graphics",sInfoFile) ); m_framePages.AddChild( &m_sprInfo[page][choice] ); } - + m_sprMore[page].SetName( ssprintf("MorePage%d",page+1) ); m_sprMore[page].Load( THEME->GetPathTo("Graphics", ssprintf("ScreenSelectDifficulty more page%d",page+1) ) ); m_framePages.AddChild( &m_sprMore[page] ); + m_sprExplanation[page].SetName( ssprintf("ExplanationPage%d",page+1) ); m_sprExplanation[page].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficulty explanation") ); m_sprExplanation[page].StopAnimating(); m_sprExplanation[page].SetState( page ); @@ -101,17 +93,20 @@ ScreenSelectDifficulty::ScreenSelectDifficulty() : ScreenSelect( "ScreenSelectDi if( !GAMESTATE->IsPlayerEnabled((PlayerNumber)p) ) continue; + m_sprShadow[p].SetName( "Shadow" ); m_sprShadow[p].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficulty shadow 2x1") ); m_sprShadow[p].StopAnimating(); m_sprShadow[p].SetState( p ); m_sprShadow[p].SetDiffuse( RageColor(0,0,0,0.6f) ); m_framePages.AddChild( &m_sprShadow[p] ); + m_sprCursor[p].SetName( "Cursor" ); m_sprCursor[p].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficulty cursor 2x1") ); m_sprCursor[p].StopAnimating(); m_sprCursor[p].SetState( p ); m_framePages.AddChild( &m_sprCursor[p] ); + m_sprOK[p].SetName( "OK" ); m_sprOK[p].Load( THEME->GetPathTo("Graphics", "ScreenSelectDifficulty ok 2x1") ); m_sprOK[p].SetState( p ); m_sprOK[p].StopAnimating(); @@ -250,7 +245,7 @@ void ScreenSelectDifficulty::ChangePage( Page newPage ) // move frame with choices m_framePages.StopTweening(); m_framePages.BeginTweening( 0.2f ); - m_framePages.SetTweenX( (float)newPage*-SCREEN_WIDTH ); + m_framePages.SetX( (float)newPage*-SCREEN_WIDTH ); } void ScreenSelectDifficulty::ChangeWithinPage( PlayerNumber pn, int iNewChoice, bool bChangingPages ) @@ -270,13 +265,13 @@ void ScreenSelectDifficulty::ChangeWithinPage( PlayerNumber pn, int iNewChoice, m_sprCursor[p].StopTweening(); m_sprCursor[p].BeginTweening( 0.2f, bChangingPages ? TWEEN_LINEAR : TWEEN_DECELERATE ); - m_sprCursor[p].SetTweenX( fCursorX ); - m_sprCursor[p].SetTweenY( fCursorY ); + m_sprCursor[p].SetX( fCursorX ); + m_sprCursor[p].SetY( fCursorY ); m_sprShadow[p].StopTweening(); m_sprShadow[p].BeginTweening( 0.2f, bChangingPages ? TWEEN_LINEAR : TWEEN_DECELERATE ); - m_sprShadow[p].SetTweenX( fCursorX + SHADOW_LENGTH_X ); - m_sprShadow[p].SetTweenY( fCursorY + SHADOW_LENGTH_Y ); + m_sprShadow[p].SetX( fCursorX + SHADOW_LENGTH_X ); + m_sprShadow[p].SetY( fCursorY + SHADOW_LENGTH_Y ); } /* If we're changing pages, it's ChangePage's responsibility to play this @@ -294,7 +289,7 @@ void ScreenSelectDifficulty::MenuStart( PlayerNumber pn ) m_bChosen[pn] = true; for( int page=0; pageIsHumanPlayer((PlayerNumber)p) ) + if( !GAMESTATE->IsHumanPlayer(p) ) continue; - m_sprCursor[p].Command( CURSOR_OFF_COMMAND ); - m_sprOK[p].Command( OK_OFF_COMMAND ); - m_sprShadow[p].Command( SHADOW_OFF_COMMAND ); + OFF_COMMAND( m_sprCursor[p] ); + OFF_COMMAND( m_sprOK[p] ); + OFF_COMMAND( m_sprShadow[p] ); } for( unsigned c=0; c +#define SET_XY( actor ) actor.SetXY( THEME->GetMetricF(m_sName,actor.GetName()+"X"), THEME->GetMetricF(m_sName,actor.GetName()+"Y") ) +#define ON_COMMAND( actor ) actor.Command( THEME->GetMetric(m_sName,actor.GetName()+"OnCommand") ) +#define OFF_COMMAND( actor ) actor.Command( THEME->GetMetric(m_sName,actor.GetName()+"OffCommand") ) +#define SET_XY_AND_ON_COMMAND( actor ) SET_XY(actor); ON_COMMAND(actor) -#define FRAME_ON_COMMAND THEME->GetMetric ("ScreenSelectGroup","FrameOnCommand") -#define FRAME_OFF_COMMAND THEME->GetMetric ("ScreenSelectGroup","FrameOffCommand") -#define BANNER_ON_COMMAND THEME->GetMetric ("ScreenSelectGroup","BannerOnCommand") -#define BANNER_OFF_COMMAND THEME->GetMetric ("ScreenSelectGroup","BannerOffCommand") #define BANNER_WIDTH THEME->GetMetricF("ScreenSelectGroup","BannerWidth") #define BANNER_HEIGHT THEME->GetMetricF("ScreenSelectGroup","BannerHeight") -#define NUMBER_ON_COMMAND THEME->GetMetric ("ScreenSelectGroup","NumberOnCommand") -#define NUMBER_OFF_COMMAND THEME->GetMetric ("ScreenSelectGroup","NumberOffCommand") -#define EXPLANATION_ON_COMMAND THEME->GetMetric ("ScreenSelectGroup","ExplanationOnCommand") -#define EXPLANATION_OFF_COMMAND THEME->GetMetric ("ScreenSelectGroup","ExplanationOffCommand") -#define CONTENTS_ON_COMMAND THEME->GetMetric ("ScreenSelectGroup","ContentsOnCommand") -#define CONTENTS_OFF_COMMAND THEME->GetMetric ("ScreenSelectGroup","ContentsOffCommand") -#define MUSIC_LIST_ON_COMMAND THEME->GetMetric ("ScreenSelectGroup","MusicListOnCommand") -#define MUSIC_LIST_OFF_COMMAND THEME->GetMetric ("ScreenSelectGroup","MusicListOffCommand") -#define GROUP_LIST_ON_COMMAND THEME->GetMetric ("ScreenSelectGroup","GroupListOnCommand") -#define GROUP_LIST_OFF_COMMAND THEME->GetMetric ("ScreenSelectGroup","GroupListOnCommand") #define SLEEP_AFTER_TWEEN_OFF_SECONDS THEME->GetMetricF("ScreenSelectGroup","SleepAfterTweenOffSeconds") #define HELP_TEXT THEME->GetMetric ("ScreenSelectGroup","HelpText") #define TIMER_SECONDS THEME->GetMetricI("ScreenSelectGroup","TimerSeconds") #define NEXT_SCREEN THEME->GetMetric ("ScreenSelectGroup","NextScreen") -ScreenSelectGroup::ScreenSelectGroup() +ScreenSelectGroup::ScreenSelectGroup() : Screen("ScreenSelectGroup") { LOG->Trace( "ScreenSelectGroup::ScreenSelectGroup()" ); @@ -123,24 +113,31 @@ ScreenSelectGroup::ScreenSelectGroup() m_bChosen = false; + m_sprExplanation.SetName( "Explanation" ); m_sprExplanation.Load( THEME->GetPathTo("Graphics","ScreenSelectGroup explanation") ); this->AddChild( &m_sprExplanation ); // these guys get loaded SetSong and TweenToSong + m_Banner.SetName( "Banner" ); m_Banner.SetCroppedSize( BANNER_WIDTH, BANNER_HEIGHT ); this->AddChild( &m_Banner ); + m_sprFrame.SetName( "Frame" ); m_sprFrame.Load( THEME->GetPathTo("Graphics","ScreenSelectGroup frame") ); this->AddChild( &m_sprFrame ); + m_textNumber.SetName( "Number" ); m_textNumber.LoadFromNumbers( THEME->GetPathTo("Numbers","ScreenSelectGroup num songs") ); this->AddChild( &m_textNumber ); + m_sprContents.SetName( "Contents" ); m_sprContents.Load( THEME->GetPathTo("Graphics","ScreenSelectGroup contents") ); this->AddChild( &m_sprContents ); + m_MusicList.SetName( "MusicList" ); this->AddChild( &m_MusicList ); + m_GroupList.SetName( "GroupList" ); m_GroupList.Load( asGroupNames ); this->AddChild( &m_GroupList ); @@ -281,26 +278,26 @@ void ScreenSelectGroup::MenuBack( PlayerNumber pn ) void ScreenSelectGroup::TweenOffScreen() { - m_sprExplanation.Command( EXPLANATION_OFF_COMMAND ); - m_sprFrame.Command( FRAME_OFF_COMMAND ); - m_Banner.Command( BANNER_OFF_COMMAND ); - m_textNumber.Command( NUMBER_OFF_COMMAND ); - m_sprContents.Command( CONTENTS_OFF_COMMAND ); - m_MusicList.Command( MUSIC_LIST_OFF_COMMAND ); - m_GroupList.Command( GROUP_LIST_OFF_COMMAND ); + OFF_COMMAND( m_sprExplanation ); + OFF_COMMAND( m_sprFrame ); + OFF_COMMAND( m_Banner ); + OFF_COMMAND( m_textNumber ); + OFF_COMMAND( m_sprContents ); + OFF_COMMAND( m_MusicList ); + OFF_COMMAND( m_GroupList ); m_MusicList.TweenOffScreen(); m_GroupList.TweenOffScreen(); } void ScreenSelectGroup::TweenOnScreen() { - m_sprExplanation.Command( EXPLANATION_ON_COMMAND ); - m_sprFrame.Command( FRAME_ON_COMMAND ); - m_Banner.Command( BANNER_ON_COMMAND ); - m_textNumber.Command( NUMBER_ON_COMMAND ); - m_sprContents.Command( CONTENTS_ON_COMMAND ); - m_MusicList.Command( MUSIC_LIST_ON_COMMAND ); - m_GroupList.Command( GROUP_LIST_ON_COMMAND ); + SET_XY_AND_ON_COMMAND( m_sprExplanation ); + SET_XY_AND_ON_COMMAND( m_sprFrame ); + SET_XY_AND_ON_COMMAND( m_Banner ); + SET_XY_AND_ON_COMMAND( m_textNumber ); + SET_XY_AND_ON_COMMAND( m_sprContents ); + SET_XY_AND_ON_COMMAND( m_MusicList ); + SET_XY_AND_ON_COMMAND( m_GroupList ); m_MusicList.TweenOnScreen(); m_GroupList.TweenOnScreen(); } diff --git a/stepmania/src/ScreenSelectMode.cpp b/stepmania/src/ScreenSelectMode.cpp index 263fb91aff..a97ea0e6da 100644 --- a/stepmania/src/ScreenSelectMode.cpp +++ b/stepmania/src/ScreenSelectMode.cpp @@ -52,7 +52,7 @@ ScreenSelectMode (Constructor) Desc: Sets up the screen display ************************************/ -ScreenSelectMode::ScreenSelectMode() +ScreenSelectMode::ScreenSelectMode() : Screen("ScreenSelectMode") { LOG->Trace( "ScreenSelectMode::ScreenSelectMode()" ); GAMESTATE->m_bPlayersCanJoin = true; @@ -356,9 +356,9 @@ void ScreenSelectMode::MenuStart( PlayerNumber pn ) if( FOLD_ON_JOIN ) { m_sprJoinMessage[pn].BeginTweening( 0.25f ); - m_sprJoinMessage[pn].SetTweenZoomY( 0 ); + m_sprJoinMessage[pn].SetZoomY( 0 ); m_sprJoinFrame[pn].BeginTweening( 0.25f ); - m_sprJoinFrame[pn].SetTweenZoomY( 0 ); + m_sprJoinFrame[pn].SetZoomY( 0 ); } RefreshModeChoices(); @@ -381,7 +381,7 @@ void ScreenSelectMode::TweenOnScreen() { float fOriginalZoomY = m_ScrollingList.GetZoomY(); m_ScrollingList.BeginTweening( 0.5f ); - m_ScrollingList.SetTweenZoomY( fOriginalZoomY ); + m_ScrollingList.SetZoomY( fOriginalZoomY ); for( int p=0; pTrace( "ScreenSelectMusic::ScreenSelectMusic()" ); @@ -286,7 +286,7 @@ void ScreenSelectMusic::TweenScoreOnAndOffAfterChangeSort() float fOriginalX = apActorsInScore[i]->GetX(); apActorsInScore[i]->BeginTweening( factor*0.5f, TWEEN_DECELERATE ); // tween off screen - apActorsInScore[i]->SetTweenX( fOriginalX+400 ); + apActorsInScore[i]->SetX( fOriginalX+400 ); apActorsInScore[i]->BeginTweening( factor*0.5f ); // sleep @@ -642,12 +642,12 @@ void ScreenSelectMusic::MenuStart( PlayerNumber pn ) m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,1) ); // visible m_sprOptionsMessage.Command( OPTIONS_MESSAGE_SHOW_COMMAND ); /* m_sprOptionsMessage.BeginTweening( 0.15f ); // fade in - m_sprOptionsMessage.SetTweenZoomY( 1 ); - m_sprOptionsMessage.SetTweenDiffuse( RageColor(1,1,1,1) ); + m_sprOptionsMessage.SetZoomY( 1 ); + m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,1) ); m_sprOptionsMessage.BeginTweening( fShowSeconds-0.35f ); // sleep m_sprOptionsMessage.BeginTweening( 0.15f ); // fade out - m_sprOptionsMessage.SetTweenDiffuse( RageColor(1,1,1,0) ); - m_sprOptionsMessage.SetTweenZoomY( 0 ); + m_sprOptionsMessage.SetDiffuse( RageColor(1,1,1,0) ); + m_sprOptionsMessage.SetZoomY( 0 ); */ m_bAllowOptionsMenu = true; /* Don't accept a held START for a little while, so it's not @@ -706,7 +706,7 @@ void ScreenSelectMusic::AfterNotesChange( PlayerNumber pn ) // m_BPMDisplay.SetZoomY( 0 ); // m_BPMDisplay.BeginTweening( 0.2f ); -// m_BPMDisplay.SetTweenZoomY( 1.2f ); +// m_BPMDisplay.SetZoomY( 1.2f ); Notes* m_pNotes = GAMESTATE->m_pCurNotes[pn]; diff --git a/stepmania/src/ScreenSelectStyle.cpp b/stepmania/src/ScreenSelectStyle.cpp index 6f12bace04..fd663cdc3d 100644 --- a/stepmania/src/ScreenSelectStyle.cpp +++ b/stepmania/src/ScreenSelectStyle.cpp @@ -18,13 +18,10 @@ #include "GameState.h" #include "AnnouncerManager.h" -#define ACTOR_ON( actor, name ) \ - actor.SetX( THEME->GetMetricF("ScreenSelectStyle",CString(name)+"X") ); \ - actor.SetY( THEME->GetMetricF("ScreenSelectStyle",CString(name)+"Y") ); \ - actor.Command( THEME->GetMetric("ScreenSelectStyle",CString(name)+"OnCommand") ) - -#define ACTOR_OFF( actor, name ) \ - actor.Command( THEME->GetMetric("ScreenSelectStyle",CString(name)+"OffCommand") ) +#define SET_XY( actor ) actor.SetXY( THEME->GetMetricF(m_sName,actor.GetName()+"X"), THEME->GetMetricF(m_sName,actor.GetName()+"Y") ) +#define ON_COMMAND( actor ) actor.Command( THEME->GetMetric(m_sName,actor.GetName()+"OnCommand") ) +#define OFF_COMMAND( actor ) actor.Command( THEME->GetMetric(m_sName,actor.GetName()+"OffCommand") ) +#define SET_XY_AND_ON_COMMAND( actor ) SET_XY(actor); ON_COMMAND(actor) #define ICON_GAIN_FOCUS_COMMAND THEME->GetMetric ("ScreenSelectStyle","IconGainFocusCommand") #define ICON_LOSE_FOCUS_COMMAND THEME->GetMetric ("ScreenSelectStyle","IconLoseFocusCommand") @@ -46,6 +43,10 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) // CString sIconElementName = ssprintf("ScreenSelectStyle icon %s", mc.name ); CString sIconPath = THEME->GetPathTo("Graphics",sIconElementName); + + m_textIcon[i].SetName( ssprintf("Icon%d",i+1) ); + m_sprIcon[i].SetName( ssprintf("Icon%d",i+1) ); + if( sIconPath.empty() ) // element doesn't exist { m_textIcon[i].LoadFromFont( THEME->GetPathTo("Fonts","Common normal") ); @@ -67,6 +68,7 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) CString sPicturePath = THEME->GetPathTo("Graphics",sPictureElementName); if( sPicturePath != "" ) { + m_sprPicture[i].SetName( ssprintf("Picture") ); m_sprPicture[i].Load( sPicturePath ); m_sprPicture[i].SetDiffuse( RageColor(1,1,1,0) ); this->AddChild( &m_sprPicture[i] ); @@ -80,6 +82,7 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) CString sInfoPath = THEME->GetPathTo("Graphics",sInfoElementName); if( sInfoPath != "" ) { + m_sprInfo[i].SetName( ssprintf("Info") ); m_sprInfo[i].Load( sInfoPath ); m_sprInfo[i].SetDiffuse( RageColor(1,1,1,0) ); this->AddChild( &m_sprInfo[i] ); @@ -87,9 +90,11 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) } + m_sprWarning.SetName( "Warning" ); m_sprWarning.Load( THEME->GetPathTo("Graphics","ScreenSelectStyle warning") ); this->AddChild( &m_sprWarning ); + m_sprExplanation.SetName( "Explanation" ); m_sprExplanation.Load( THEME->GetPathTo("Graphics","ScreenSelectStyle explanation") ); this->AddChild( &m_sprExplanation ); @@ -106,6 +111,7 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) if( PREFSMAN->m_bJointPremium ) { + m_sprJointPremium.SetName( "JointPremium" ); m_sprJointPremium.Load( THEME->GetPathTo("Graphics","ScreenSelectStyle joint premium") ); this->AddChild( &m_sprJointPremium ); } @@ -120,12 +126,12 @@ ScreenSelectStyle::ScreenSelectStyle() : ScreenSelect( "ScreenSelectStyle" ) // for( i=0; iTrace( "ScreenSelectStyle5th::ScreenSelectStyle5th()" ); @@ -222,7 +222,7 @@ void ScreenSelectStyle5th::HandleScreenMessage( const ScreenMessage SM ) break; case SM_TweenExplanation2: m_textExplanation2.BeginTweening( 0.7f ); - m_textExplanation2.SetTweenZoomX( EXPLANATION2_ZOOM_X ); + m_textExplanation2.SetZoomX( EXPLANATION2_ZOOM_X ); break; case SM_UpdateAnimations: for( int i=0; iStopMusic(); @@ -249,7 +249,7 @@ ScreenStage::ScreenStage() // // m_frameStage.SetXY( CENTER_X, fStageOffScreenY ); // m_frameStage.BeginTweening(0.8f, Actor::TWEEN_DECELERATE ); -// m_frameStage.SetTweenY( CENTER_Y ); +// m_frameStage.SetY( CENTER_Y ); // // this->AddChild( &m_quadMask ); // add quad mask before stage so that it will block out the stage sprites // this->AddChild( &m_frameStage ); @@ -297,8 +297,8 @@ ScreenStage::ScreenStage() // m_sprNumbers[i].SetRotationZ( 10 ); // make this thing rotated // // m_sprNumbers[i].BeginTweening(0.8f, Actor::TWEEN_ACCELERATE ); -// m_sprNumbers[i].SetTweenZoom( 3.0f ); // shrink it down to it's proper size -// m_sprNumbers[i].SetTweenRotationZ( 0 ); // make it rotate into place +// m_sprNumbers[i].SetZoom( 3.0f ); // shrink it down to it's proper size +// m_sprNumbers[i].SetRotationZ( 0 ); // make it rotate into place // } // // // m_frameStage.SetXY( CENTER_X, CENTER_Y ); @@ -340,7 +340,7 @@ ScreenStage::ScreenStage() // m_sprbgxtra.ZoomToWidth( SCREEN_WIDTH + 50 ); // stretching shouldn't be a concern. // m_sprbgxtra.SetRotationZ( -20 ); // rotate this graphic // m_sprbgxtra.BeginTweening(0.3f); // start tweening -// m_sprbgxtra.SetTweenRotationZ( 0 ); // set the rotation we want it to finally appear as +// m_sprbgxtra.SetRotationZ( 0 ); // set the rotation we want it to finally appear as // } // // @@ -357,22 +357,22 @@ ScreenStage::ScreenStage() // m_sprbg[0].ZoomToWidth( SCREEN_WIDTH + 50 ); // no matter what... it's this wide // m_sprbg[0].SetRotationZ( -20 ); // and is initially this rotation // m_sprbg[0].BeginTweening(0.3f); // start tweening -// m_sprbg[0].SetTweenRotationZ( 0 ); // and set the rotation to where we want it to end up +// m_sprbg[0].SetRotationZ( 0 ); // and set the rotation to where we want it to end up // // m_sprbg[1].SetXY( CENTER_X-(SCREEN_WIDTH/2)-20, CENTER_Y+element_y_offsets); // m_sprbg[1].ZoomToHeight( SCREEN_HEIGHT - 140 ); // m_sprbg[1].ZoomToWidth( 130 ); // m_sprbg[1].SetRotationZ( -20 ); // m_sprbg[1].BeginTweening(0.3f); -// m_sprbg[1].SetTweenRotationZ( 0 ); +// m_sprbg[1].SetRotationZ( 0 ); // // m_sprbg[2].SetXY( CENTER_X+430, CENTER_Y+element_y_offsets); // m_sprbg[2].ZoomToHeight( SCREEN_HEIGHT - 140 ); // m_sprbg[2].ZoomToWidth( SCREEN_WIDTH + 50 ); // m_sprbg[2].SetRotationZ( -20 ); // m_sprbg[2].BeginTweening(0.3f); -// m_sprbg[2].SetTweenX( CENTER_X ); -// m_sprbg[2].SetTweenRotationZ( 0 ); +// m_sprbg[2].SetX( CENTER_X ); +// m_sprbg[2].SetRotationZ( 0 ); // // for (i = 3; i >= 0; i--) // add them backwards // AddChild( &m_sprbg[i] ); @@ -432,10 +432,10 @@ ScreenStage::ScreenStage() // // } // -// m_ez2ukm[0].SetTweenX(CENTER_X+90); // set their new locations -// m_ez2ukm[1].SetTweenX(CENTER_X-160); -// m_stagedesc[0].SetTweenX(CENTER_X+10); // set their new locations -// m_stagedesc[1].SetTweenX(CENTER_X-100); +// m_ez2ukm[0].SetX(CENTER_X+90); // set their new locations +// m_ez2ukm[1].SetX(CENTER_X-160); +// m_stagedesc[0].SetX(CENTER_X+10); // set their new locations +// m_stagedesc[1].SetX(CENTER_X-100); // // for (i=0; i<2; i++) // add the actors // { @@ -487,9 +487,9 @@ ScreenStage::ScreenStage() // // m_sprScrollingBlobs[j][i].BeginTweening(0.2f * i / 7); // start them tweening, different delay for each blob // if (j == 0) // set 1 -// m_sprScrollingBlobs[j][i].SetTweenX(CENTER_X-(SCREEN_WIDTH/2)+30+(i*30.0f)); // keep them at equal distance when they arrive +// m_sprScrollingBlobs[j][i].SetX(CENTER_X-(SCREEN_WIDTH/2)+30+(i*30.0f)); // keep them at equal distance when they arrive // else // set 2 -// m_sprScrollingBlobs[j][i].SetTweenX(CENTER_X+(SCREEN_WIDTH/2)+30-70-(i*30.0f)); +// m_sprScrollingBlobs[j][i].SetX(CENTER_X+(SCREEN_WIDTH/2)+30-70-(i*30.0f)); // // AddChild( &m_sprScrollingBlobs[j][i] ); // } @@ -541,7 +541,7 @@ ScreenStage::ScreenStage() // // m_stagename.BeginTweening(0.5f); // start tweening them to their new home // -// m_stagename.SetTweenX(CENTER_X+70); // set their new locations +// m_stagename.SetX(CENTER_X+70); // set their new locations // AddChild( &m_stagename ); //add the actor // // this->AddChild( &m_frameStage ); diff --git a/stepmania/src/ScreenStyleSplash.cpp b/stepmania/src/ScreenStyleSplash.cpp index f46023858e..61cc90a383 100644 --- a/stepmania/src/ScreenStyleSplash.cpp +++ b/stepmania/src/ScreenStyleSplash.cpp @@ -26,7 +26,7 @@ const ScreenMessage SM_DoneOpening = ScreenMessage(SM_User-7); const ScreenMessage SM_StartClosing = ScreenMessage(SM_User-8); -ScreenStyleSplash::ScreenStyleSplash() +ScreenStyleSplash::ScreenStyleSplash() : Screen("ScreenStyleSplash") { SOUNDMAN->StopMusic(); diff --git a/stepmania/src/ScreenTest.cpp b/stepmania/src/ScreenTest.cpp index 63850e3466..308cdad114 100644 --- a/stepmania/src/ScreenTest.cpp +++ b/stepmania/src/ScreenTest.cpp @@ -38,7 +38,7 @@ void ScreenTest::SetScreen(int num) current=new ScreenTestFonts; } -ScreenTest::ScreenTest() +ScreenTest::ScreenTest() : Screen("ScreenTest") { current = NULL; cur_screen = -1; diff --git a/stepmania/src/ScreenTestFonts.cpp b/stepmania/src/ScreenTestFonts.cpp index 0cacba5773..d4d9300e44 100644 --- a/stepmania/src/ScreenTestFonts.cpp +++ b/stepmania/src/ScreenTestFonts.cpp @@ -25,7 +25,7 @@ void ScreenTestFonts::HandleScreenMessage( const ScreenMessage SM ) SetText(CustomText); } -ScreenTestFonts::ScreenTestFonts() +ScreenTestFonts::ScreenTestFonts() : Screen("ScreenTestFonts") { Hline.SetXY(CENTER_X, CENTER_Y); Hline.SetZoomX(LineWidth); diff --git a/stepmania/src/ScreenTestSound.cpp b/stepmania/src/ScreenTestSound.cpp index 38ae37a8bc..243d04e04b 100644 --- a/stepmania/src/ScreenTestSound.cpp +++ b/stepmania/src/ScreenTestSound.cpp @@ -6,7 +6,6 @@ Desc: Area for testing. Copyright (c) 2001-2002 by the person(s) listed below. All rights reserved. - Chris Danford Glenn Maynard (OpenGL Code) Lance Gilbert (OpenGL/Usability Modifications) ----------------------------------------------------------------------------- @@ -21,7 +20,7 @@ #include "RageSoundManager.h" #include "ThemeManager.h" -ScreenTestSound::ScreenTestSound() +ScreenTestSound::ScreenTestSound() : Screen("ScreenTestSound") { int i; this->AddChild(&HEEEEEEEEELP); diff --git a/stepmania/src/ScreenTextEntry.cpp b/stepmania/src/ScreenTextEntry.cpp index 39d36f2c25..ba4e2abced 100644 --- a/stepmania/src/ScreenTextEntry.cpp +++ b/stepmania/src/ScreenTextEntry.cpp @@ -35,7 +35,8 @@ const float ANSWER_HEIGHT = 30; * Handle UTF-8. Right now, we need to at least be able to backspace * a whole UTF-8 character. Better would be to operate in longchars. */ -ScreenTextEntry::ScreenTextEntry( ScreenMessage SM_SendWhenDone, CString sQuestion, CString sInitialAnswer, void(*OnOK)(CString sAnswer), void(*OnCancel)() ) +ScreenTextEntry::ScreenTextEntry( ScreenMessage SM_SendWhenDone, CString sQuestion, CString sInitialAnswer, void(*OnOK)(CString sAnswer), void(*OnCancel)() ) : + Screen("ScreenTextEntry") { m_bIsTransparent = true; // draw screens below us @@ -190,15 +191,15 @@ void ScreenTextEntry::MenuStart( PlayerNumber pn ) m_Fade.OpenWipingRight( SM_DoneOpeningWipingRight ); m_textQuestion.BeginTweening( 0.2f ); - m_textQuestion.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textQuestion.SetDiffuse( RageColor(1,1,1,0) ); m_rectAnswerBox.BeginTweening( 0.2f ); - m_rectAnswerBox.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_rectAnswerBox.SetDiffuse( RageColor(1,1,1,0) ); m_textAnswer.SetEffectNone(); m_textAnswer.BeginTweening( 0.2f ); - m_textAnswer.SetTweenDiffuse( RageColor(1,1,1,0) ); + m_textAnswer.SetDiffuse( RageColor(1,1,1,0) ); SOUNDMAN->PlayOnce( THEME->GetPathTo("Sounds","Common start") ); diff --git a/stepmania/src/ScreenTitleMenu.cpp b/stepmania/src/ScreenTitleMenu.cpp index a3e6f62726..05ad32e4ba 100644 --- a/stepmania/src/ScreenTitleMenu.cpp +++ b/stepmania/src/ScreenTitleMenu.cpp @@ -290,14 +290,14 @@ void ScreenTitleMenu::LoseFocus( int iChoiceIndex ) m_textChoice[iChoiceIndex].SetEffectNone(); m_textChoice[iChoiceIndex].StopTweening(); m_textChoice[iChoiceIndex].BeginTweening( 0.3f ); - m_textChoice[iChoiceIndex].SetTweenZoom( ZOOM_NOT_SELECTED ); + m_textChoice[iChoiceIndex].SetZoom( ZOOM_NOT_SELECTED ); } void ScreenTitleMenu::GainFocus( int iChoiceIndex ) { m_textChoice[iChoiceIndex].StopTweening(); m_textChoice[iChoiceIndex].BeginTweening( 0.3f ); - m_textChoice[iChoiceIndex].SetTweenZoom( ZOOM_SELECTED ); + m_textChoice[iChoiceIndex].SetZoom( ZOOM_SELECTED ); RageColor color1, color2; color1 = COLOR_SELECTED; color2 = color1 * 0.5f; diff --git a/stepmania/src/StepMania.vcproj b/stepmania/src/StepMania.vcproj index 6fe39160cb..4d419dbcb1 100644 --- a/stepmania/src/StepMania.vcproj +++ b/stepmania/src/StepMania.vcproj @@ -1349,12 +1349,6 @@ cl /Zl /nologo /c verstub.cpp /Fo$(IntDir)\ - - - - diff --git a/stepmania/src/ThemeManager.h b/stepmania/src/ThemeManager.h index 2e37d82196..2e41812598 100644 --- a/stepmania/src/ThemeManager.h +++ b/stepmania/src/ThemeManager.h @@ -58,7 +58,7 @@ extern ThemeManager* THEME; // global and accessable from anywhere in our progra class CachedThemeMetric { protected: - CString m_sClassName; + CString m_sName; CString m_sValueName; bool m_bInited; @@ -71,14 +71,14 @@ protected: public: CachedThemeMetric( CString sClassName, CString sValueName ) { - m_sClassName = sClassName; + m_sName = sClassName; m_sValueName = sValueName; m_bInited = false; } void Refresh() { - m_sValue = THEME->GetMetric(m_sClassName,m_sValueName); + m_sValue = THEME->GetMetric(m_sName,m_sValueName); m_iValue = atoi( m_sValue ); m_fValue = (float)atof( m_sValue ); m_bValue = atoi( m_sValue ) != 0; diff --git a/stepmania/stepmania.nsi b/stepmania/stepmania.nsi index 92c6ee11f1..5d7ee7b7a2 100644 --- a/stepmania/stepmania.nsi +++ b/stepmania/stepmania.nsi @@ -19,7 +19,7 @@ !define PRODUCT_NAME_VER "${PRODUCT_NAME} ${VERSION}" Name "${PRODUCT_NAME}" -OutFile "StepMania-CVS-20030324.exe" +OutFile "StepMania-CVS-20030410.exe" ;OutFile "StepMania301.exe" ; Some default compiler settings (uncomment and change at will): @@ -121,9 +121,16 @@ CreateDirectory "$INSTDIR\CDTitles" SetOutPath "$INSTDIR\CDTitles" File "CDTitles\instructions.txt" +CreateDirectory "$INSTDIR\Characters" +SetOutPath "$INSTDIR\Characters" +File "Characters\instructions.txt" + CreateDirectory "$INSTDIR\Courses" SetOutPath "$INSTDIR\Courses" File "Courses\instructions.txt" +CreateDirectory "$INSTDIR\Courses\Samples" +SetOutPath "$INSTDIR\Courses\Samples" +File /r "Courses\Samples" RMDir /r "$INSTDIR\NoteSkins\dance\MAX" RMDir /r "$INSTDIR\NoteSkins\dance\default" @@ -133,6 +140,7 @@ RMDir /r "$INSTDIR\NoteSkins\dance\solo" SetOutPath "$INSTDIR\NoteSkins" File "NoteSkins\instructions.txt" ; why do this? -glenn +; instructions.txt can be deleted. -Chris CreateDirectory "$INSTDIR\NoteSkins\dance\default" CreateDirectory "$INSTDIR\NoteSkins\dance\flat" CreateDirectory "$INSTDIR\NoteSkins\dance\note" @@ -215,7 +223,7 @@ CreateDirectory "$SMPROGRAMS\${PRODUCT_ID}\" CreateShortCut "$DESKTOP\Play ${PRODUCT_NAME_VER}.lnk" "$INSTDIR\stepmania.exe" CreateShortCut "$SMPROGRAMS\${PRODUCT_ID}\${PRODUCT_NAME_VER}.lnk" "$INSTDIR\stepmania.exe" CreateShortCut "$SMPROGRAMS\${PRODUCT_ID}\Open Songs Folder.lnk" "$WINDIR\explorer.exe" "$INSTDIR\Songs\" -CreateShortCut "$SMPROGRAMS\${PRODUCT_ID}\SMZIP Package Exporter.lnk" "$INSTDIR\smpackage.exe" +CreateShortCut "$SMPROGRAMS\${PRODUCT_ID}\StepMania Tools and Package Exporter.lnk" "$INSTDIR\smpackage.exe" CreateShortCut "$SMPROGRAMS\${PRODUCT_ID}\README-FIRST.lnk" "$INSTDIR\README-FIRST.html" CreateShortCut "$SMPROGRAMS\${PRODUCT_ID}\Uninstall ${PRODUCT_NAME_VER}.lnk" "$INSTDIR\uninst.exe" CreateShortCut "$SMPROGRAMS\${PRODUCT_ID}\Go To StepMania web site.lnk" "http://www.stepmania.com" @@ -253,6 +261,9 @@ RMDir "$INSTDIR\Cache" Delete "$INSTDIR\CDTitles\instructions.txt" RMDir "$INSTDIR\CDTitles" +Delete "$INSTDIR\Characters\instructions.txt" +RMDir "$INSTDIR\Characters" + RMDir /r "$INSTDIR\Cache" Delete "$INSTDIR\Courses\instructions.txt"