diff --git a/stepmania/NEWS b/stepmania/NEWS index bf65206deb..50b1e6cd84 100644 --- a/stepmania/NEWS +++ b/stepmania/NEWS @@ -18,6 +18,7 @@ NEW FEATURE: Option for user-selectable extra stage 1 CHANGE: Documentation now in HTML format. CHANGE: Overhauled NoteSkin format. See README-FIRST.htm for details. BUG FIX: Super-shuffle fixed (now doesn't add extra notes) +NEW FEATURE: Added BIG transform (changes notes on beats to jumps) ----------------------- 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 8d8f72d907..966e35c99f 100644 --- a/stepmania/README-FIRST.html +++ b/stepmania/README-FIRST.html @@ -6,13 +6,14 @@ -

StepMania 3.0 final
+

StepMania 3.0 final
©2001-2003, StepMania team, All rights reserved.
-http://www.stepmania.com

+http://www.stepmania.com


-Table of Contents +Table of Contents
+
About StepMania
Minimum Requirements
@@ -41,9 +42,13 @@ and Help

See the file NEWS for version history.

+

+ About StepMania
+

+
StepMania is capable of playing many game types. Currently, it supports games similar to Dance Dance Revolution, Pump It Up, EZ 2 Dancer, and Para Para @@ -56,9 +61,12 @@ controller in time to the. All games can be played using the keyboard, but the real fun comes when using specially designed controllers, like a dance pad or hand sensors.

+

-Minimum Requirements + +Minimum Requirements
+
* Windows 98, Windows ME, Windows 2000, or Windows XP
* Pentium II, Pentium III, Celeron, Athlon, or compatible processor, 266MHz @@ -70,26 +78,35 @@ minimum (400 MHz recommended)
* DivX 5 video codec for movie visualizations (www.divx.com)


+

-DirectX + +DirectX
+
DirectX 8.0 is required before installing StepMania. If DirectX 8.0 is not installed on your computer, the StepMania installer will display a warning and abort the installation.

+

-Installation + +Installation
+
To install StepMania, download the file stepmania300.exe to a known location on your hard drive, then double-click the file icon to begin the installation. The installer may prompt you to remove an older version of the program if one is present. The default installation directory is 'C:\Program Files\StepMania'.

+

-Controls + +Controls
+
Use the "Config Key/Joy" option from the Title Menu to configure your keyboard, dance pad, or other game controller. This menu allows you to map up to 2 @@ -145,9 +162,12 @@ In editor:
In the music select screen:
* F9 = Toggle title translations

+

-How StepMania Loads Songs + +How StepMania Loads Songs
+
All files for a specific song (data file, music file, banner, background) must reside in a single folder. This folder must have the following path:
@@ -182,9 +202,12 @@ fails, StepMania will guess which image is most appropriate.
If there is exactly one movie in the song folder, StepMania will insert a background change to that movie at beat 0.

+

-Connecting Dance Pads + +Connecting Dance Pads
+
There are several devices that allow you to connect PlayStation dance pads to your PC.
@@ -221,9 +244,12 @@ is NTPad XP 1.x or
StepMania now natively supports USB Pump It Up pads.

+

-Compatibility Issues + +Compatibility Issues
+
Some video card/driver combinations have visual errors when running StepMania. If you experience any visual errors, please visit your video card manufacturer's @@ -246,9 +272,12 @@ Symptom: Various graphical glitches.
Explanation: These problems are most often caused by buggy video card drivers bugs. Please upgrade to the latest drivers, which will hopefully fix the errors.

+

-FAQ / Troubleshooting + +FAQ / Troubleshooting
+
* The error "Cannot find Dinput8.dll" appears when launching the game.

@@ -276,9 +305,12 @@ Nope, Sorry. It's gotten me in trouble before.
The reasons I won't tell is because: a) I don't know yet, and b) I don't want to make anyone angry if it takes longer than expected (it usually does).

+

-StepMania Packages - .smzip + +StepMania Packages - .smzip
+
The StepMania package format was created to make the distribution of songs and other add-ons very easy.  StepMania package files have the extension '.smzip' @@ -300,10 +332,13 @@ will take all of the selected items and make one package that contains them all. "Export Individual" will create one separate package for each selected item in the list.

+

+ Questions, Bugs, Suggestions, -and Help +and Help
+
If you have a question about or problem with StepMania, please first ask your question a StepMania message board. For a list of StepMania message boards, see @@ -330,9 +365,12 @@ If you would like to help with development of StepMania, please send an email to the StepMania developers list or to Chris.

+

-The StepMania editor + +The StepMania editor
+
The StepMania editor allows you to edit, record, synchronize, and play back note patterns. When you choose 'Save', your song will be saved in both the .SM format @@ -352,9 +390,12 @@ the editor:
* P - Play back current selection (if no selection, play whole song)
* R - Record over current selection (if no selection, record whole song)

+

-The .SM file format + +The .SM file format
+
The .SM song file format was created to be one file format that supports all game types that StepMania can play (dance, pump, beat, guitar, etc). The syntax @@ -405,22 +446,24 @@ the background should begin playing a new background named 'bg name'. 'beat' is a fractional value value and 'bg name' is a string. Different bg changes are separated by commas. e.g. "60=falling,80=flower".  When StepMania looks for a backgound, it searches in this order:
+
    -
  1. Looks for a movie with file name = "bg name" in the song folder. You must -include the file extension in "bg name". e.g. "60=falling.avi,80=flower.mpg".
  2. -
  3. Looks for a BGAnimation folder with the name "bg name" in the song folder.
  4. -
  5. Looks for a movie with file name "bg name" in the RandomMovies folder. You -must include the file extension in "bg name". e.g. "60=falling.avi,80=flower.mpg".
  6. -
  7. Looks for a BGAnimation with file name "bg name" in the BGAnimations folder.
  8. -
  9. Looks for a Visualization with the file name "bg name" in the Visualizations +
  10. Looks for a movie with file name = "bg name" in the song folder. You must +include the file extension in "bg name". e.g. "60=falling.avi,80=flower.mpg".
  11. +
  12. Looks for a BGAnimation folder with the name "bg name" in the song folder.
  13. +
  14. Looks for a movie with file name "bg name" in the RandomMovies folder. You +must include the file extension in "bg name". e.g. "60=falling.avi,80=flower.mpg".
  15. +
  16. Looks for a BGAnimation with file name "bg name" in the BGAnimations folder.
  17. +
  18. Looks for a Visualization with the file name "bg name" in the Visualizations folder. For example, suppose you have a song B4U and special B4U-specific BGAnimations called "robot" and "electric". First, move the robot and electric BGAnimation folders into the B4U song folder (e.g. Songs\4th Mix\B4U\robot and Songs\4th Mix\B4U\electric). Then, using the editor, insert a new background change at each point in the song where you to switch to a new BGAnimation. When prompted for the name of the background change, you could type either "robot" or -"electric".
  19. +"electric".
+
Each pattern of notes has the same basic format:

@@ -504,9 +547,12 @@ Example:
0000
;

+

-Backgrounds + +Backgrounds
+
StepMania supports three different modes of backgrounds. The default background mode can be set in the Graphic Options menu.
@@ -532,9 +578,12 @@ computers.
Sample animations, visualizations, and random movies can be found at www.stepmania.com.

+

-BGAnimations Format + +BGAnimations Format
+
The BGAnimations folder in the StepMania program directory may contain several BGAnimation folders.
@@ -621,21 +670,67 @@ TileFlipY,
TilePulse,
- Tiles zoom in and out.

+

-The .CRS File Format + +The .CRS File Format
+
-CRS files define the courses used in the "Oni" Nonstop Challenge mode. All CRS -files must reside in the "Courses" folder in the StepMania program folder.
+CRS files define the courses used in the Nonstop, Oni, and Endless modes.  All CRS +files must reside in the "Courses" folder in the StepMania program folder.  +These rules determine which of the three modes a course will appear in:
+
+Nonstop: Will appear if #LIVES=-1 and #REPEAT=OFF.
+Oni (Challenge): Will appear if #LIVES > 0 and #REPEAT=OFF.
+Endless: Will appear if #REPEAT is ON.

#COURSE:...; - name of the course
#LIVES:<0..10>; - An integer between 0 and 10. This line is optional.
#REPEAT:<YES|NO>; - start over after last stage?
-#SONG:<group folder>\<song folder>:<description>[:modifiers]; -
-group folder - The name of the folder that contains the song folder.
-song folder - the name of the folder that contains files for the song
-description - BASIC, TRICK, SSR, MANIAC, HEAVY, etc.
-modifiers - One or more of:
+#SONG: - can use any one of the following formats:
+
+A fixed song:
+        #SONG:<group folder>/<song +folder>:<difficulty>:<modifiers>;
+        example: #SONG:DDRMAX/MAX300:BASIC;
+        example: +#SONG:DDR4th/B4U:MANIAC:sudden,shuffle,reverse;
+A random song:
+        #SONG:*:(<difficulty>|<meter +range>):<modifiers>;
+        example: #SONG:*:MANIAC;
+        example: #SONG:*:8..10:1.5x,reverse;
+A random song within a group:
+        #SONG:<group +folder>/*:(<difficulty>|<meter range>):<modifiers>;
+        example: #SONG:DDRMAX/*:3..6;
+        example: +#SONG:DDR3rd/*:MANIAC:1.5x,reverse;
+A players best song:
+        #SONG:PlayersBest:<number>:<modifiers>;
+        example: #PlayersBest1:TRICK;
+        example: +#PlayersBest4:MANIAC:1.5x,reverse;
+A players worst song:
+        #SONG:PlayersWorst:<number>:<modifiers>;
+        example: #PlayersWorst4:MANIAC;
+        example: +#PlayersWorst1:TRICK:1.5x,reverse,drunk;
+
+Descriptions:
+group folder - The name of the folder that contains the song folder. (e.g. +"DDR4th")
+song folder - the name of the folder that contains files for the song. (e.g. +"B4U")
+difficulty - Can be one of the following: BEGINNER, BASIC, TRICK, MANIAC, +CHALLENGE.
+meter range - A value in the format "x..y" where x is the lowest meter allowed +and y is the highest meter allowed.  For example, the string "7..9" would +choose only from songs with a foot meter of 7, 8, or 9.
+modifiers - A comma separated series of modifier strings.  This value may +be left blank.  Any string you see on the Player Options screen is a +modifier string.  Some examples are:
0.5x, 0.75x, 1.5x, 2.0x, 3.0x, 4.0x, 5.0x, 8.0x
boost, wave, drunk, dizzy, space, mini
hidden, sudden, stealth, blink
@@ -646,13 +741,15 @@ note, flat, plain
noholds
nofreeze
dark
-norecover, suddendeath, power-drop, death
0.7xmusic, 0.8xmusic, 0.9xmusic, 1.0xmusic, 1.1xmusic,
1.2xmusic, 1.3xmusic, 1.4xmusic, 1.5xmusic

+

-Extra Stages + +Extra Stages
+
You can manually specify extra stages for each song group by creating .CRS files called "extra1.crs" and "extra2.crs" and placing them in the song group folder @@ -664,9 +761,12 @@ CRS file is not found or is invalid, appropriate song, notes, and modifiers will Don't forget: extra stage CRS files belong in the song group folder (e.g. "Songs/DDRMAX/"), not in "Courses".

+

-Creating an Announcer + +Creating an Announcer
+
Announcers folders must reside in the "Announcers" folder inside the StepMania program directory (e.g. "Announcers\DDRMAX\"). An announcer folder contains @@ -683,9 +783,12 @@ trigger folder is missing, then no sound will be played for that trigger.
For a complete list of announcer trigger names, see the example announcer packs that are available at www.stepmania.com.

+

-Creating a Note Skin + +Creating a Note Skin
+
Note skins allow you to customize the way notes appear. Note skins must reside in the folder "NoteSkins\<Game Name>\<Note Skin Name>". Note skins are specific @@ -714,9 +817,12 @@ wide, and hold parts which must be 4x2.
For more information on about textures with multiple frames, see the section "How StepMania Loads Textures" in this document.

+

-Creating a Theme + +Creating a Theme
+
All themes must reside in the Themes folder below the StepMania program directory. Inside a theme folder, you will all or only a few of the items below:
@@ -829,9 +935,12 @@ Graphics folder "Themes\MySuperTheme\Graphics".
- Edit your new title menu graphic to be whatever you want.
- Start StepMania, go to Appearance Options, and change your theme to "MySuperTheme".

+

-How StepMania Loads Textures + +How StepMania Loads Textures
+
* What are textures?

@@ -906,9 +1015,13 @@ greater in size than 256x256. If a texture is larger than the card's maximum texture size, the image will scaled down internally resulting in output that looks blurry.

+

+ Building StepMania from CVS source +
+
CVS is the repository that manages the StepMania source code. Our CVS server is graciously provided by SourceForge. You can get the absolute-latest bleeding @@ -1032,20 +1145,24 @@ and put "ssh.bat" into the editbox.

* All done!  Congrats.

+

-Thanks + +Thanks
+
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)

+

-End of document +End of document

- + \ No newline at end of file diff --git a/stepmania/Themes/default/metrics.ini b/stepmania/Themes/default/metrics.ini index 1738ba4c96..c516099f0d 100644 --- a/stepmania/Themes/default/metrics.ini +++ b/stepmania/Themes/default/metrics.ini @@ -688,7 +688,7 @@ Left=Up,Down,Right,Left Right=Up,Down,Left,Right Shuffle=Down,Up,Down,Up SuperShuffle=Down,Up,Left,Right -Little= +NextTransform= NextScrollSpeed= PreviousScrollSpeed= NextAccel=Left,Right,Down,Up diff --git a/stepmania/src/CodeDetector.cpp b/stepmania/src/CodeDetector.cpp index 278370184d..67a9b070bb 100644 --- a/stepmania/src/CodeDetector.cpp +++ b/stepmania/src/CodeDetector.cpp @@ -31,7 +31,7 @@ enum Code { CODE_RIGHT, CODE_SHUFFLE, CODE_SUPER_SHUFFLE, - CODE_LITTLE, + CODE_NEXT_TRANSFORM, CODE_NEXT_SCROLL_SPEED, CODE_PREVIOUS_SCROLL_SPEED, CODE_NEXT_ACCEL, @@ -58,7 +58,7 @@ const CString g_sCodeNames[NUM_CODES] = { "Right", "Shuffle", "SuperShuffle", - "Little", + "NextTransform", "NextScrollSpeed", "PreviousScrollSpeed", "NextAccel", @@ -174,7 +174,7 @@ bool CodeDetector::DetectAndAdjustOptions( GameController controller ) case CODE_RIGHT: TOGGLE( GAMESTATE->m_PlayerOptions[pn].m_TurnType, PlayerOptions::TURN_RIGHT, PlayerOptions::TURN_NONE ); break; case CODE_SHUFFLE: TOGGLE( GAMESTATE->m_PlayerOptions[pn].m_TurnType, PlayerOptions::TURN_SHUFFLE, PlayerOptions::TURN_NONE ); break; case CODE_SUPER_SHUFFLE: TOGGLE( GAMESTATE->m_PlayerOptions[pn].m_TurnType, PlayerOptions::TURN_SUPER_SHUFFLE, PlayerOptions::TURN_NONE ); break; - case CODE_LITTLE: TOGGLE( GAMESTATE->m_PlayerOptions[pn].m_bLittle, true, false ); break; + case CODE_NEXT_TRANSFORM: GAMESTATE->m_PlayerOptions[pn].NextTransform(); break; case CODE_NEXT_SCROLL_SPEED:INCREMENT_SCROLL_SPEED( GAMESTATE->m_PlayerOptions[pn].m_fScrollSpeed ); break; case CODE_PREVIOUS_SCROLL_SPEED:DECREMENT_SCROLL_SPEED( GAMESTATE->m_PlayerOptions[pn].m_fScrollSpeed ); break; case CODE_NEXT_ACCEL: GAMESTATE->m_PlayerOptions[pn].NextAccel(); break; diff --git a/stepmania/src/NoteData.cpp b/stepmania/src/NoteData.cpp index dde3864689..b8f1ec5078 100644 --- a/stepmania/src/NoteData.cpp +++ b/stepmania/src/NoteData.cpp @@ -122,7 +122,7 @@ void NoteData::CopyAll( NoteData* pFrom ) void NoteData::AddHoldNote( HoldNote add ) { - ASSERT( add.m_fStartBeat>=0 && add.m_fEndBeat>=0 ); + ASSERT( add.fStartBeat>=0 && add.fEndBeat>=0 ); int i; @@ -132,33 +132,33 @@ void NoteData::AddHoldNote( HoldNote add ) for( i=0; i= add.m_fEndBeat ) || // other consumes add - ( other.m_fStartBeat >= add.m_fStartBeat && other.m_fEndBeat <= add.m_fEndBeat ) || // other inside add - ( add.m_fStartBeat <= other.m_fStartBeat && other.m_fStartBeat <= add.m_fEndBeat ) || // other overlaps add - ( add.m_fStartBeat <= other.m_fEndBeat && other.m_fEndBeat <= add.m_fEndBeat ) // other overlaps add + ( other.fStartBeat <= add.fStartBeat && other.fEndBeat >= add.fEndBeat ) || // other consumes add + ( other.fStartBeat >= add.fStartBeat && other.fEndBeat <= add.fEndBeat ) || // other inside add + ( add.fStartBeat <= other.fStartBeat && other.fStartBeat <= add.fEndBeat ) || // other overlaps add + ( add.fStartBeat <= other.fEndBeat && other.fEndBeat <= add.fEndBeat ) // other overlaps add ) ) { - add.m_fStartBeat = min(add.m_fStartBeat, other.m_fStartBeat); - add.m_fEndBeat = max(add.m_fEndBeat, other.m_fEndBeat); + add.fStartBeat = min(add.fStartBeat, other.fStartBeat); + add.fEndBeat = max(add.fEndBeat, other.fEndBeat); // delete this HoldNote m_HoldNotes.erase(m_HoldNotes.begin()+i, m_HoldNotes.begin()+i+1); } } - int iAddStartIndex = BeatToNoteRow(add.m_fStartBeat); - int iAddEndIndex = BeatToNoteRow(add.m_fEndBeat); + int iAddStartIndex = BeatToNoteRow(add.fStartBeat); + int iAddEndIndex = BeatToNoteRow(add.fEndBeat); // delete TapNotes under this HoldNote for( i=iAddStartIndex+1; i<=iAddEndIndex; i++ ) - SetTapNote(add.m_iTrack, i, TAP_EMPTY); + SetTapNote(add.iTrack, i, TAP_EMPTY); // add a tap note at the start of this hold - SetTapNote(add.m_iTrack, iAddStartIndex, TAP_HOLD_HEAD); // Hold begin marker. Don't draw this, but do grade it. + SetTapNote(add.iTrack, iAddStartIndex, TAP_HOLD_HEAD); // Hold begin marker. Don't draw this, but do grade it. m_HoldNotes.push_back(add); } @@ -169,10 +169,10 @@ void NoteData::RemoveHoldNote( int iHoldIndex ) HoldNote& hn = GetHoldNote(iHoldIndex); - int iHoldStartIndex = BeatToNoteRow(hn.m_fStartBeat); + int iHoldStartIndex = BeatToNoteRow(hn.fStartBeat); // delete a tap note at the start of this hold - SetTapNote(hn.m_iTrack, iHoldStartIndex, TAP_EMPTY); + SetTapNote(hn.iTrack, iHoldStartIndex, TAP_EMPTY); // remove from list m_HoldNotes.erase(m_HoldNotes.begin()+iHoldIndex, m_HoldNotes.begin()+iHoldIndex+1); @@ -216,8 +216,8 @@ float NoteData::GetFirstBeat() const } for( i=0; i fOldestBeatFoundSoFar ) - fOldestBeatFoundSoFar = GetHoldNote(i).m_fEndBeat; + if( GetHoldNote(i).fEndBeat > fOldestBeatFoundSoFar ) + fOldestBeatFoundSoFar = GetHoldNote(i).fEndBeat; } return fOldestBeatFoundSoFar; @@ -303,7 +303,7 @@ int NoteData::GetNumHoldNotes( const float fStartBeat, const float fEndBeat ) co for( int i=0; im_PlayerOptions[m_PlayerNumber].m_bReverseScroll; - const int iCol = hn.m_iTrack; - const float fStartYOffset = ArrowGetYOffset( m_PlayerNumber, hn.m_fStartBeat ); + const int iCol = hn.iTrack; + const float fStartYOffset = ArrowGetYOffset( m_PlayerNumber, hn.fStartBeat ); const float fStartYPos = ArrowGetYPos( m_PlayerNumber, fStartYOffset ); - const float fEndYOffset = ArrowGetYOffset( m_PlayerNumber, hn.m_fEndBeat ); + const float fEndYOffset = ArrowGetYOffset( m_PlayerNumber, hn.fEndBeat ); const float fEndYPos = ArrowGetYPos( m_PlayerNumber, fEndYOffset ); const float fYHead = bReverse ? fEndYPos : fStartYPos; // the center of the head @@ -379,7 +379,7 @@ void NoteDisplay::DrawHold( const HoldNote& hn, const bool bActive, const float // Draw the bottom cap (always wavy) // { - Sprite* pBottomCap = GetHoldBottomCapSprite( hn.m_fStartBeat, bActive ); + Sprite* pBottomCap = GetHoldBottomCapSprite( hn.fStartBeat, bActive ); // draw manually in small segments RageVertex *v = &queue[0]; @@ -444,7 +444,7 @@ void NoteDisplay::DrawHold( const HoldNote& hn, const bool bActive, const float // Draw the body (always wavy) // { - Sprite* pSprBody = GetHoldBodySprite( hn.m_fStartBeat, bActive ); + Sprite* pSprBody = GetHoldBodySprite( hn.fStartBeat, bActive ); // draw manually in small segments RageVertex *v = &queue[0]; @@ -522,7 +522,7 @@ void NoteDisplay::DrawHold( const HoldNote& hn, const bool bActive, const float // Draw the top cap (always wavy) // { - Sprite* pSprTopCap = GetHoldTopCapSprite( hn.m_fStartBeat, bActive ); + Sprite* pSprTopCap = GetHoldTopCapSprite( hn.fStartBeat, bActive ); // draw manually in small segments RageVertex *v = &queue[0]; @@ -586,7 +586,7 @@ void NoteDisplay::DrawHold( const HoldNote& hn, const bool bActive, const float // Draw the tail // { - Sprite* pSprTail = GetHoldTailSprite( hn.m_fStartBeat, bActive ); + Sprite* pSprTail = GetHoldTailSprite( hn.fStartBeat, bActive ); const float fY = fYTail; const float fX = ArrowGetXPos( m_PlayerNumber, iCol, fY ); @@ -613,7 +613,7 @@ void NoteDisplay::DrawHold( const HoldNote& hn, const bool bActive, const float // Draw the head // { - Sprite* pSprHead = GetHoldHeadSprite( hn.m_fStartBeat, bActive ); + Sprite* pSprHead = GetHoldHeadSprite( hn.fStartBeat, bActive ); // draw with normal Sprite const float fY = fYHead; diff --git a/stepmania/src/NoteField.cpp b/stepmania/src/NoteField.cpp index 48ccc20d03..b9b94d0498 100644 --- a/stepmania/src/NoteField.cpp +++ b/stepmania/src/NoteField.cpp @@ -266,13 +266,13 @@ void NoteField::DrawPrimitives() if( hns == HNS_OK ) // if this HoldNote was completed continue; // don't draw anything - if( hn.m_iTrack != c ) // this HoldNote doesn't belong to this column + if( hn.iTrack != c ) // this HoldNote doesn't belong to this column continue; // If no part of this HoldNote is on the screen, skip it - if( !( fFirstBeatToDraw <= hn.m_fEndBeat && hn.m_fEndBeat <= fLastBeatToDraw || - fFirstBeatToDraw <= hn.m_fStartBeat && hn.m_fStartBeat <= fLastBeatToDraw || - hn.m_fStartBeat < fFirstBeatToDraw && hn.m_fEndBeat > fLastBeatToDraw ) ) + if( !( fFirstBeatToDraw <= hn.fEndBeat && hn.fEndBeat <= fLastBeatToDraw || + fFirstBeatToDraw <= hn.fStartBeat && hn.fStartBeat <= fLastBeatToDraw || + hn.fStartBeat < fFirstBeatToDraw && hn.fEndBeat > fLastBeatToDraw ) ) { continue; // skip } diff --git a/stepmania/src/NoteTypes.h b/stepmania/src/NoteTypes.h index c782566c3d..0d4551b58a 100644 --- a/stepmania/src/NoteTypes.h +++ b/stepmania/src/NoteTypes.h @@ -83,9 +83,9 @@ CString NoteTypeToString( NoteType nt ); struct HoldNote { - int m_iTrack; - float m_fStartBeat; - float m_fEndBeat; + int iTrack; + float fStartBeat; + float fEndBeat; }; diff --git a/stepmania/src/Player.cpp b/stepmania/src/Player.cpp index 9211f46fe6..5fa7a40f6b 100644 --- a/stepmania/src/Player.cpp +++ b/stepmania/src/Player.cpp @@ -157,8 +157,20 @@ void Player::Load( PlayerNumber pn, NoteData* pNoteData, LifeMeter* pLM, ScoreDi NoteDataUtil::Turn( *this, GAMESTATE->m_PlayerOptions[pn].m_TurnType ); - if( GAMESTATE->m_PlayerOptions[pn].m_bLittle ) + switch( GAMESTATE->m_PlayerOptions[pn].m_Transform ) + { + case PlayerOptions::TRANSFORM_NONE: + break; + case PlayerOptions::TRANSFORM_LITTLE: NoteDataUtil::MakeLittle(*this); + break; + case PlayerOptions::TRANSFORM_BIG: + NoteDataUtil::MakeBig(*this); + break; + default: + ASSERT(0); // invalid value + break; + } int iPixelsToDrawBefore = -60; int iPixelsToDrawAfter = 350; @@ -223,21 +235,21 @@ void Player::Update( float fDeltaTime ) const HoldNote &hn = GetHoldNote(i); HoldNoteScore hns = GetHoldNoteScore(i); float fLife = GetHoldNoteLife(i); - int iHoldStartIndex = BeatToNoteRow(hn.m_fStartBeat); + int iHoldStartIndex = BeatToNoteRow(hn.fStartBeat); m_NoteField.m_bIsHoldingHoldNote[i] = false; // set host flag so NoteField can do intelligent drawing if( hns != HNS_NONE ) // if this HoldNote already has a result continue; // we don't need to update the logic for this one - const StyleInput StyleI( m_PlayerNumber, hn.m_iTrack ); + const StyleInput StyleI( m_PlayerNumber, hn.iTrack ); const GameInput GameI = GAMESTATE->GetCurrentStyleDef()->StyleInputToGameInput( StyleI ); // if they got a bad score or haven't stepped on the corresponding tap yet - const TapNoteScore tns = GetTapNoteScore(hn.m_iTrack, iHoldStartIndex); + const TapNoteScore tns = GetTapNoteScore(hn.iTrack, iHoldStartIndex); const bool bSteppedOnTapNote = tns != TNS_NONE && tns != TNS_MISS; // did they step on the start of this hold? - if( hn.m_fStartBeat < fSongBeat && fSongBeat < hn.m_fEndBeat ) // if the song beat is in the range of this hold + if( hn.fStartBeat < fSongBeat && fSongBeat < hn.fEndBeat ) // if the song beat is in the range of this hold { bool bIsHoldingButton = INPUTMAPPER->IsButtonDown( GameI ); if( !GAMESTATE->m_bEditing && (PREFSMAN->m_bAutoPlay || GAMESTATE->m_bDemonstration) ) @@ -247,7 +259,7 @@ void Player::Update( float fDeltaTime ) if( bSteppedOnTapNote ) // this note is not judged and we stepped on its head { - m_NoteField.GetHoldNote(i).m_fStartBeat = fSongBeat; // move the start of this Hold + m_NoteField.GetHoldNote(i).fStartBeat = fSongBeat; // move the start of this Hold } if( bSteppedOnTapNote && bIsHoldingButton ) @@ -256,11 +268,11 @@ void Player::Update( float fDeltaTime ) fLife += fDeltaTime/HOLD_ARROW_NG_TIME; fLife = min( fLife, 1 ); // clamp - m_GhostArrowRow.HoldNote( hn.m_iTrack ); // update the "electric ghost" effect + m_GhostArrowRow.HoldNote( hn.iTrack ); // update the "electric ghost" effect } else { - if( fSongBeat-hn.m_fStartBeat > GAMESTATE->m_fCurBPS * GetMaxStepDistanceSeconds() ) + if( fSongBeat-hn.fStartBeat > GAMESTATE->m_fCurBPS * GetMaxStepDistanceSeconds() ) { // Decrease life fLife -= fDeltaTime/HOLD_ARROW_NG_TIME; @@ -275,7 +287,7 @@ void Player::Update( float fDeltaTime ) hns = HNS_NG; // check for OK - if( fSongBeat >= hn.m_fEndBeat && bSteppedOnTapNote && fLife > 0 ) // if this HoldNote is in the past + if( fSongBeat >= hn.fEndBeat && bSteppedOnTapNote && fLife > 0 ) // if this HoldNote is in the past { fLife = 1; hns = HNS_OK; @@ -286,7 +298,7 @@ void Player::Update( float fDeltaTime ) { /* this note's been judged */ HandleHoldNoteScore( hns, tns ); - m_HoldJudgement[hn.m_iTrack].SetHoldJudgement( hns ); + m_HoldJudgement[hn.iTrack].SetHoldJudgement( hns ); } m_NoteField.SetHoldNoteLife(i, fLife); // update the NoteField display diff --git a/stepmania/src/PlayerOptions.cpp b/stepmania/src/PlayerOptions.cpp index e1dc3c3aba..f5dfa7e4df 100644 --- a/stepmania/src/PlayerOptions.cpp +++ b/stepmania/src/PlayerOptions.cpp @@ -21,7 +21,7 @@ void PlayerOptions::Init() ZERO( m_bEffects ); m_AppearanceType = APPEARANCE_VISIBLE; m_TurnType = TURN_NONE; - m_bLittle = false; + m_Transform = TRANSFORM_NONE; m_bReverseScroll = false; m_ColorType = COLOR_VIVID; m_bHoldNotes = true; @@ -73,7 +73,7 @@ CString PlayerOptions::GetString() case APPEARANCE_SUDDEN: sReturn += "Sudden, "; break; case APPEARANCE_STEALTH: sReturn += "Stealth, "; break; case APPEARANCE_BLINK: sReturn += "Blink, "; break; - default: ASSERT(0); // invalid EFFECT + default: ASSERT(0); // invalid } switch( m_TurnType ) @@ -84,11 +84,16 @@ CString PlayerOptions::GetString() case TURN_RIGHT: sReturn += "Right, "; break; case TURN_SHUFFLE: sReturn += "Shuffle, "; break; case TURN_SUPER_SHUFFLE:sReturn += "SuperShuffle, ";break; - default: ASSERT(0); // invalid EFFECT + default: ASSERT(0); // invalid } - if( m_bLittle ) - sReturn += "Little, "; + switch( m_Transform ) + { + case TRANSFORM_NONE: break; + case TRANSFORM_LITTLE: sReturn += "Little, "; break; + case TRANSFORM_BIG: sReturn += "Big, "; break; + default: ASSERT(0); // invalid + } if( m_bReverseScroll ) sReturn += "Reverse, "; @@ -154,7 +159,8 @@ void PlayerOptions::FromString( CString sOptions ) else if( sBit == "right" ) m_TurnType = TURN_RIGHT; else if( sBit == "shuffle" ) m_TurnType = TURN_SHUFFLE; else if( sBit == "supershuffle" )m_TurnType = TURN_SUPER_SHUFFLE; - else if( sBit == "little" ) m_bLittle = true; + else if( sBit == "little" ) m_Transform = TRANSFORM_LITTLE; + else if( sBit == "big" ) m_Transform = TRANSFORM_BIG; else if( sBit == "reverse" ) m_bReverseScroll = true; else if( sBit == "note" ) m_ColorType = COLOR_NOTE; else if( sBit == "flat" ) m_ColorType = COLOR_FLAT; @@ -207,6 +213,11 @@ void PlayerOptions::NextTurn() m_TurnType = (TurnType) ((m_TurnType+1)%NUM_TURN_TYPES); } +void PlayerOptions::NextTransform() +{ + m_Transform = (Transform) ((m_Transform+1)%NUM_TRANSFORMS); +} + void PlayerOptions::ChooseRandomMofifiers() { if( RandomFloat(0,1)>0.8f ) diff --git a/stepmania/src/PlayerOptions.h b/stepmania/src/PlayerOptions.h index 216175d59f..5ed6062165 100644 --- a/stepmania/src/PlayerOptions.h +++ b/stepmania/src/PlayerOptions.h @@ -54,7 +54,13 @@ struct PlayerOptions NUM_TURN_TYPES } m_TurnType; void NextTurn(); - bool m_bLittle; + enum Transform { + TRANSFORM_NONE=0, + TRANSFORM_LITTLE, + TRANSFORM_BIG, + NUM_TRANSFORMS + } m_Transform; + void NextTransform(); bool m_bReverseScroll; enum ColorType { COLOR_VIVID=0, diff --git a/stepmania/src/ScreenEdit.cpp b/stepmania/src/ScreenEdit.cpp index 2d56da68e2..84e358301f 100644 --- a/stepmania/src/ScreenEdit.cpp +++ b/stepmania/src/ScreenEdit.cpp @@ -729,8 +729,8 @@ void ScreenEdit::InputEdit( const DeviceInput& DeviceI, const InputEventType typ for( int i=0; i= hn.m_fStartBeat && fSongBeat <= hn.m_fEndBeat ) // the cursor lies within this HoldNote + if( iCol == hn.iTrack && // the notes correspond + fSongBeat >= hn.fStartBeat && fSongBeat <= hn.fEndBeat ) // the cursor lies within this HoldNote { m_NoteFieldEdit.RemoveHoldNote( i ); bRemovedAHoldNote = true; @@ -798,12 +798,12 @@ void ScreenEdit::InputEdit( const DeviceInput& DeviceI, const InputEventType typ // create a new hold note HoldNote newHN; - newHN.m_iTrack = col; - newHN.m_fStartBeat = min(fStartBeat, fEndBeat); - newHN.m_fEndBeat = max(fStartBeat, fEndBeat); + newHN.iTrack = col; + newHN.fStartBeat = min(fStartBeat, fEndBeat); + newHN.fEndBeat = max(fStartBeat, fEndBeat); - newHN.m_fStartBeat = max(newHN.m_fStartBeat, 0); - newHN.m_fEndBeat = max(newHN.m_fEndBeat, 0); + newHN.fStartBeat = max(newHN.fStartBeat, 0); + newHN.fEndBeat = max(newHN.fEndBeat, 0); m_NoteFieldEdit.AddHoldNote( newHN ); } diff --git a/stepmania/src/ScreenPlayerOptions.cpp b/stepmania/src/ScreenPlayerOptions.cpp index 50a9e42289..8b2bca21b8 100644 --- a/stepmania/src/ScreenPlayerOptions.cpp +++ b/stepmania/src/ScreenPlayerOptions.cpp @@ -26,7 +26,7 @@ enum { PO_EFFECT, PO_APPEAR, PO_TURN, - PO_LITTLE, + PO_TRANSFORM, PO_SCROLL, PO_COLOR, PO_HOLD_NOTES, @@ -39,7 +39,7 @@ OptionRowData g_PlayerOptionsLines[NUM_PLAYER_OPTIONS_LINES] = { { "Effect", 7, {"OFF","DRUNK","DIZZY","SPACE","MINI","FLIP","TORNADO"} }, { "Appear\n-ance", 5, {"VISIBLE","HIDDEN","SUDDEN","STEALTH","BLINK"} }, { "Turn", 6, {"OFF","MIRROR","LEFT","RIGHT","SHUFFLE","SUPER SHUFFLE"} }, - { "Little", 2, {"OFF","ON"} }, + { "Trans\n-form", 3, {"OFF","LITTLE","BIG"} }, { "Scroll", 2, {"STANDARD","REVERSE"} }, { "Color", 3, {"VIVID","NOTE","FLAT"} }, { "Holds", 2, {"OFF","ON"} }, @@ -95,7 +95,7 @@ void ScreenPlayerOptions::ImportOptions() m_iSelectedOption[p][PO_APPEAR] = po.m_AppearanceType; m_iSelectedOption[p][PO_TURN] = po.m_TurnType; - m_iSelectedOption[p][PO_LITTLE] = po.m_bLittle ? 1 : 0; + m_iSelectedOption[p][PO_TRANSFORM] = po.m_Transform; m_iSelectedOption[p][PO_SCROLL] = po.m_bReverseScroll ? 1 : 0 ; m_iSelectedOption[p][PO_COLOR] = po.m_ColorType; m_iSelectedOption[p][PO_HOLD_NOTES] = po.m_bHoldNotes ? 1 : 0; @@ -132,7 +132,7 @@ void ScreenPlayerOptions::ExportOptions() po.m_AppearanceType = (PlayerOptions::AppearanceType)m_iSelectedOption[p][PO_APPEAR]; po.m_TurnType = (PlayerOptions::TurnType)m_iSelectedOption[p][PO_TURN]; - po.m_bLittle = m_iSelectedOption[p][PO_LITTLE] == 1; + po.m_Transform = (PlayerOptions::Transform)m_iSelectedOption[p][PO_TRANSFORM]; po.m_bReverseScroll = (m_iSelectedOption[p][PO_SCROLL] == 1); po.m_ColorType = (PlayerOptions::ColorType)m_iSelectedOption[p][PO_COLOR]; po.m_bHoldNotes = (m_iSelectedOption[p][PO_HOLD_NOTES] == 1);