Commit Graph

105 Commits

Author SHA1 Message Date
Chris Danford c52ab6fa5e Code -> UnlockEntryID
UnlockedSongs -> UnlockedEntryIDs
UnlockIndex -> UnlockEntryID
2006-01-28 22:08:16 +00:00
Chris Danford 7f821e8cfc CString -> RString 2006-01-22 01:00:06 +00:00
Glenn Maynard e341ce46bb remove unused 2006-01-15 08:12:27 +00:00
Glenn Maynard 55efe79054 Most of the time we use a GameCommand to store state, we don't want
Apply() itself to load the screen; we want to stuff it in m_sNextScreen
and let the normal screen loading code path do it.  That's why we have
GetAndClearScreen.

However, GetAndClearScreen is a non-const, and applying a GameCommand
should be a const operation.  It doesn't get along well with screen
reuse; once you've applied it, you've destroyed the GameCommand.

Instead, hold a flag indicating whether or not to apply screens, and
set this true on load when we handle it manually.  We should probably
*always* do this, and never load a screen within GameCommand itself, so
this may go away soon (always on).
2006-01-15 08:00:37 +00:00
Glenn Maynard d8ae5df6ef fix leak 2006-01-14 06:46:15 +00:00
Glenn Maynard 9c867fdd70 We have two "gamestate Lua environments": mapEnv and m_Environment. The
former is a map<CString,CString>; the latter is a Lua table.  The former
is reset on gamestate reset, the latter is not.

Merge the map into the table, and eliminate it.  We only need one, and
it makes sense for a Lua environment to be a Lua table.

Do reset the table on Reset.  Otherwise, there's little point; if you want
to store data inside Lua, you don't need GameState to help.
2006-01-13 21:49:35 +00:00
Chris Danford 800158e185 move floating globals into a namespace 2005-12-02 01:16:28 +00:00
Chris Danford 557ae44dc7 re-add applydefaultoptions 2005-11-30 04:27:10 +00:00
Chris Danford cd9cf4c1e2 move some service menu actions from GameCommand into ScreenServiceAction 2005-11-29 23:15:11 +00:00
Chris Danford 6e5b3a5ed8 fix PrefsManager::m_sCurrentGame not current, so GamePrefs from Static.ini weren't being used 2005-10-28 01:44:19 +00:00
Glenn Maynard 4c62c63e84 move m_sDefaultLocalProfileID into ProfileManager 2005-10-27 17:47:42 +00:00
Chris Danford 112564dc99 fix [Common] DefaultModifers not being applied in most places 2005-10-27 07:51:37 +00:00
Chris Danford 5d7885c764 move game prefs into PrefsManager 2005-10-27 04:54:45 +00:00
Chris Danford e00a57e05e use Preference1D 2005-10-26 23:09:56 +00:00
Steve Checkoway 01d315364a Fix gcc (3.3) compile. 2005-10-17 06:55:58 +00:00
Glenn Maynard f56cea11aa Fix "style,single;song,foo;steps,fum;screen,ScreenFoo" causing an assert
in GetAndClearScreen.  We can't LoadOne each part without actually applying
each first; "steps" will fail due to style and song not actually having
been set.
2005-10-16 01:04:55 +00:00
Glenn Maynard 346376a96d fix comment 2005-09-11 04:34:24 +00:00
Chris Danford 65d71a4f23 expermienting with DEFINE_METHOD macro for Lua methods 2005-09-10 02:47:04 +00:00
Glenn Maynard 781017c4c0 ChooseRandomMofifiers -> ChooseRandomModifiers 2005-09-08 01:06:01 +00:00
Chris Danford ae8f754b1f add Lua method bindings 2005-09-07 22:05:41 +00:00
Glenn Maynard 0022bc3338 cleanup 2005-09-03 02:08:27 +00:00
Chris Danford b9f82be7a9 add separate MultiPlayer value. index = enabled player index (max num joined players). multiPlayer = MultiPlayer value for this player (max NUM_MultiPlayer) 2005-08-26 17:34:42 +00:00
Chris Danford 70d1f0eadb use mixed case values for enum Grade so that enum matches strings matches Lua 2005-08-14 11:38:31 +00:00
Chris Danford ff7c122289 cleanup: move ProfileLoadResult into GameConstantsAndTypes so we don't take dependencies on Profile.h for ProfileLoadResult 2005-08-13 06:59:27 +00:00
Glenn Maynard 18911711c4 split FillProfile 2005-08-13 00:10:18 +00:00
Glenn Maynard 095513c3d7 hide more 2005-08-12 03:10:53 +00:00
Glenn Maynard 2b1b57b81f hide more 2005-08-12 03:03:54 +00:00
Glenn Maynard 8af1f7003d hide more 2005-08-12 02:55:48 +00:00
Glenn Maynard 70a109c54b fPercentDP, fSurviveSeconds 2005-08-12 02:46:58 +00:00
Glenn Maynard d3bd7a7723 hide iScore 2005-08-12 02:37:04 +00:00
Glenn Maynard aa04fe60dd hide grade 2005-08-12 02:19:08 +00:00
Glenn Maynard 2307fa23d9 hidden HighScore::sName 2005-08-12 01:52:01 +00:00
Chris Danford a2c439a17a support loading of course edits 2005-07-31 05:41:32 +00:00
Chris Danford 881001b6c6 broadcast on PlayMode changed 2005-07-25 03:59:24 +00:00
Glenn Maynard 6939289f67 remove deletepreparedscreens 2005-07-22 08:46:06 +00:00
Chris Danford 015e72253b add "text," command so that elements can look up their text 2005-07-14 20:13:14 +00:00
Chris Danford fcc6c4408a working on SSelectProfile 2005-07-07 22:08:05 +00:00
Glenn Maynard bb8af41cb1 missing headers 2005-07-01 05:07:22 +00:00
Chris Danford 2a6dcba6e8 cleanup:
"GroupName" -> "SongGroup" to make room for CourseGroup
replace checks for "cvs" with a call to StripCvs()
m_Rows -> m_pRows
broadcast on preferred group changes
2005-06-23 08:05:09 +00:00
Glenn Maynard c0a65b3503 lua locking 2005-06-16 22:10:24 +00:00
Chris Danford 47e5a2059d tweak error message 2005-06-16 01:21:31 +00:00
Chris Danford c21314e114 fix coins subtracted in event mode 2005-06-03 05:05:54 +00:00
Ben Anderson 98c5e7348b Preference<int> != int 2005-05-28 00:36:30 +00:00
Chris Danford 50717c6ee9 COIN_ -> COIN_MODE_ 2005-05-20 17:45:44 +00:00
Chris Danford 6d49da50ee doubles -> double
add Lua Premium constants
2005-05-20 08:03:01 +00:00
Chris Danford e504fb4e98 broadcast on changed course/trail 2005-05-18 07:14:19 +00:00
Chris Danford fb1d69add3 rename: IsUsingProfile -> IsPersistentProfile
Don't require IsPersistentProfile in some places related to fitness mode where a non-persistent Profile will suffice
2005-05-09 08:44:01 +00:00
Glenn Maynard e822ee71ce one line 2005-05-09 07:33:15 +00:00
Chris Danford 16818e54c8 broadcast on style change 2005-05-07 08:34:20 +00:00
Chris Danford 0938d9d9a7 conver more to use Preference 2005-04-28 08:27:40 +00:00