diff --git a/Docs/Changelog_sm-ssc.txt b/Docs/Changelog_sm-ssc.txt index ccc229b0b6..f89a760601 100644 --- a/Docs/Changelog_sm-ssc.txt +++ b/Docs/Changelog_sm-ssc.txt @@ -30,11 +30,20 @@ sm-ssc $SM5VERSION | 2011???? jump to different labels made. [Wolfman2000] ================================================================================ -sm-ssc $NEXTVERSION | 2011???? +sm-ssc v1.2.5 | 201104?? -------------------------------------------------------------------------------- -It depends on who you ask. -It could be v1.2.5, it could be v1.3.0, it could even be StepMania 5. -We will wait and see. + +20110416 +-------- +* [PlayerOptions] Added UsingReverse() Lua binding (automatically tests + GetReverse() == 1) [AJ] +* [PlayerState] Added GetCurrentPlayerOptions() Lua binding [AJ] + +20110413 +-------- +* [ScreenSelectMusic] Made score frame into an AutoActor, changed the filename + from "score frame p1" to "ScoreFrame P1" for consistency with other elements. + [AJ] 20110405 -------- diff --git a/Docs/CourseFormat.txt b/Docs/CourseFormat.txt index b23aee8e63..6051a6044a 100644 --- a/Docs/CourseFormat.txt +++ b/Docs/CourseFormat.txt @@ -44,6 +44,11 @@ Complete Course Template TIME:0.500:END:1.000:MODS:2x; TIME:1.500:END:1.500:MODS:0.5x; +#GAINSECONDS:60.5; +-- The number of seconds gained before starting a song. This and #LIVES are +-- mutually exclusive: you can either have one, the other, or none: both +-- is not possible. This is meant to be used for Survival courses. + #SONG:*:Medium:2x; -- #SONG can take quite a variety of parameters, of which may be useful to you -- for testing or randomocity purpose. @@ -80,4 +85,4 @@ Finally, here's an example course: #SONG:In The Groove/Dawn:Overhead; #SONG:In The Groove/Mouth:; #SONG:In The Groove 2/Funk Factory:; -#SONG:In The Groove 3/Disconnected Zeo:; \ No newline at end of file +#SONG:In The Groove 3/Disconnected Zeo:; diff --git a/autoconf/m4/bzip.m4 b/autoconf/m4/bzip.m4 new file mode 100644 index 0000000000..2f0dfc6490 --- /dev/null +++ b/autoconf/m4/bzip.m4 @@ -0,0 +1,27 @@ +AC_DEFUN([SM_BZIP], +[ + AC_REQUIRE([SM_STATIC]) + AC_CHECK_LIB(bz2, BZ2_bzCompressInit, have_bzip=yes, have_bzip=no) + AC_CHECK_HEADER(bzlib.h, have_bzip_header=yes, have_bzip_header=no) + AC_ARG_WITH(static-bzip, AS_HELP_STRING([--with-static-bzip],[Statically link bzip]), with_static_bzip=$withval, with_static_bzip=no) + + if test "$with_static_bzip" = "yes"; then + LIB_PRE=$START_STATIC + LIB_POST=$END_STATIC + fi + + if test "$have_bzip_header" = "no"; then + have_bzip=no + fi + + if test "$have_bzip" = "no"; then + echo "*** bzip is required to build StepMania; please make sure" + echo "*** that bzip is installed to continue the installation process." + exit 0; + fi + + LIBS="$LIBS $LIB_PRE -lbz2 $LIB_POST" + + LIB_PRE= + LIB_POST= +]) diff --git a/configure.ac b/configure.ac index 2fb749062c..786027c60b 100644 --- a/configure.ac +++ b/configure.ac @@ -197,6 +197,7 @@ fi AM_CONDITIONAL(WITHOUT_NETWORKING, test "$with_network" = "no") SM_ZLIB +SM_BZIP SM_AUDIO SM_VIDEO SM_TLS diff --git a/src/AutoKeysounds.cpp b/src/AutoKeysounds.cpp index 5118be44fd..5aac67976b 100644 --- a/src/AutoKeysounds.cpp +++ b/src/AutoKeysounds.cpp @@ -99,7 +99,7 @@ void AutoKeysounds::LoadAutoplaySoundsInto( RageSoundReader_Chain *pChain ) if( tn[pn].iKeysoundIndex >= 0 ) { RString sKeysoundFilePath = sSongDir + pSong->m_vsKeysoundFile[tn[pn].iKeysoundIndex]; - float fSeconds = pSong->m_Timing.GetElapsedTimeFromBeatNoOffset( NoteRowToBeat(iRow) ); + float fSeconds = pSong->m_Timing.GetElapsedTimeFromBeatNoOffset( NoteRowToBeat(iRow) ) + SOUNDMAN->GetPlayLatency(); float fPan = 0; if( !bSoundIsGlobal ) diff --git a/src/MusicWheel.cpp b/src/MusicWheel.cpp index e767612f14..0ee25ae52a 100644 --- a/src/MusicWheel.cpp +++ b/src/MusicWheel.cpp @@ -659,6 +659,7 @@ void MusicWheel::BuildWheelItemDatas( vector &arrayWheelIt if( so != SORT_ROULETTE ) { + // todo: allow themers to change the order of the items. -aj if( SHOW_ROULETTE ) arrayWheelItemDatas.push_back( new MusicWheelItemData(TYPE_ROULETTE, NULL, "", NULL, ROULETTE_COLOR, 0) ); diff --git a/src/PlayerOptions.cpp b/src/PlayerOptions.cpp index e91dbb8742..8d1a8199cd 100644 --- a/src/PlayerOptions.cpp +++ b/src/PlayerOptions.cpp @@ -908,6 +908,7 @@ public: // Scroll DEFINE_METHOD( GetReverse, m_fScrolls[PlayerOptions::SCROLL_REVERSE] ) + DEFINE_METHOD( UsingReverse, m_fScrolls[PlayerOptions::SCROLL_REVERSE] == 1 ) static int GetReversePercentForColumn( T *p, lua_State *L ) { // todo: make sure IArg is within boundaries -aj @@ -1021,6 +1022,7 @@ public: // Scroll ADD_METHOD( GetReverse ); + ADD_METHOD( UsingReverse ); ADD_METHOD( GetReversePercentForColumn ); ADD_METHOD( GetSplit ); ADD_METHOD( GetAlternate ); diff --git a/src/PlayerState.cpp b/src/PlayerState.cpp index a18e85c3e7..070e96c7be 100644 --- a/src/PlayerState.cpp +++ b/src/PlayerState.cpp @@ -229,6 +229,12 @@ public: LuaHelpers::Push( L, s ); return 1; } + static int GetCurrentPlayerOptions( T* p, lua_State *L ) + { + PlayerOptions po = p->m_PlayerOptions.GetCurrent(); + po.PushSelf(L); + return 1; + } DEFINE_METHOD( GetHealthState, m_HealthState ); LunaPlayerState() @@ -239,6 +245,7 @@ public: ADD_METHOD( GetPlayerOptions ); ADD_METHOD( GetPlayerOptionsArray ); ADD_METHOD( GetPlayerOptionsString ); + ADD_METHOD( GetCurrentPlayerOptions ); ADD_METHOD( GetHealthState ); } }; diff --git a/src/RoomInfoDisplay.cpp b/src/RoomInfoDisplay.cpp index 86b568612b..847db6846f 100644 --- a/src/RoomInfoDisplay.cpp +++ b/src/RoomInfoDisplay.cpp @@ -179,7 +179,6 @@ void RoomInfoDisplay::SetRoomInfo( const RoomInfo& info) m_playerList[i] = new BitmapText; m_playerList[i]->LoadFromFont( THEME->GetPathF(GetName(),"text") ); m_playerList[i]->SetName("PlayerListElement"); - m_playerList[i]->SetShadowLength( 0 ); m_playerList[i]->SetHorizAlign( align_left ); m_playerList[i]->SetX(PLAYERLISTX + (i * PLAYERLISTOFFSETX)); m_playerList[i]->SetY(PLAYERLISTY + (i * PLAYERLISTOFFSETY)); diff --git a/src/ScreenGameplay.cpp b/src/ScreenGameplay.cpp index c9ea70bc6e..e6b84cca04 100644 --- a/src/ScreenGameplay.cpp +++ b/src/ScreenGameplay.cpp @@ -590,7 +590,6 @@ void ScreenGameplay::Init() ASSERT( pi->m_ptextCourseSongNumber == NULL ); pi->m_ptextCourseSongNumber = new BitmapText; pi->m_ptextCourseSongNumber->LoadFromFont( THEME->GetPathF(m_sName,"SongNum") ); - pi->m_ptextCourseSongNumber->SetShadowLength( 0 ); pi->m_ptextCourseSongNumber->SetName( ssprintf("SongNumber%s",pi->GetName().c_str()) ); LOAD_ALL_COMMANDS_AND_SET_XY( pi->m_ptextCourseSongNumber ); pi->m_ptextCourseSongNumber->SetText( "" ); @@ -609,7 +608,6 @@ void ScreenGameplay::Init() ASSERT( pi->m_ptextPlayerOptions == NULL ); pi->m_ptextPlayerOptions = new BitmapText; pi->m_ptextPlayerOptions->LoadFromFont( THEME->GetPathF(m_sName,"player options") ); - pi->m_ptextPlayerOptions->SetShadowLength( 0 ); pi->m_ptextPlayerOptions->SetName( ssprintf("PlayerOptions%s",pi->GetName().c_str()) ); LOAD_ALL_COMMANDS_AND_SET_XY( pi->m_ptextPlayerOptions ); this->AddChild( pi->m_ptextPlayerOptions ); diff --git a/src/ScreenSelectMaster.cpp b/src/ScreenSelectMaster.cpp index 3d76c7cdfa..83276d4e33 100644 --- a/src/ScreenSelectMaster.cpp +++ b/src/ScreenSelectMaster.cpp @@ -755,8 +755,11 @@ float ScreenSelectMaster::DoMenuStart( PlayerNumber pn ) } if( SHOW_CURSOR ) { - m_sprCursor[pn]->PlayCommand( "Choose" ); - fSecs = max( fSecs, m_sprCursor[pn]->GetTweenTimeLeft() ); + if(m_sprCursor[pn] != NULL) + { + m_sprCursor[pn]->PlayCommand( "Choose" ); + fSecs = max( fSecs, m_sprCursor[pn]->GetTweenTimeLeft() ); + } } return fSecs; diff --git a/src/ScreenSelectMusic.cpp b/src/ScreenSelectMusic.cpp index 14cb6bf61c..422487438c 100644 --- a/src/ScreenSelectMusic.cpp +++ b/src/ScreenSelectMusic.cpp @@ -199,10 +199,10 @@ void ScreenSelectMusic::Init() FOREACH_ENUM( PlayerNumber, p ) { - m_sprHighScoreFrame[p].SetName( ssprintf("ScoreFrameP%d",p+1) ); - m_sprHighScoreFrame[p].Load( THEME->GetPathG(m_sName,ssprintf("score frame p%d",p+1)) ); + m_sprHighScoreFrame[p].Load( THEME->GetPathG(m_sName,ssprintf("ScoreFrame P%d",p+1)) ); + m_sprHighScoreFrame[p]->SetName( ssprintf("ScoreFrameP%d",p+1) ); LOAD_ALL_COMMANDS_AND_SET_XY( m_sprHighScoreFrame[p] ); - this->AddChild( &m_sprHighScoreFrame[p] ); + this->AddChild( m_sprHighScoreFrame[p] ); m_textHighScore[p].SetName( ssprintf("ScoreP%d",p+1) ); m_textHighScore[p].LoadFromFont( THEME->GetPathF(m_sName,"score") ); @@ -247,7 +247,7 @@ void ScreenSelectMusic::BeginScreen() { if( GAMESTATE->IsHumanPlayer(pn) ) continue; - m_sprHighScoreFrame[pn].SetVisible( false ); + m_sprHighScoreFrame[pn]->SetVisible( false ); m_textHighScore[pn].SetVisible( false ); } diff --git a/src/ScreenSelectMusic.h b/src/ScreenSelectMusic.h index 6e75a65b34..1531aa80c8 100644 --- a/src/ScreenSelectMusic.h +++ b/src/ScreenSelectMusic.h @@ -123,7 +123,7 @@ protected: FadingBanner m_Banner; Sprite m_sprCDTitleFront, m_sprCDTitleBack; - Sprite m_sprHighScoreFrame[NUM_PLAYERS]; + AutoActor m_sprHighScoreFrame[NUM_PLAYERS]; BitmapText m_textHighScore[NUM_PLAYERS]; MusicWheel m_MusicWheel; OptionsList m_OptionsList[NUM_PLAYERS];