Commit Graph

104 Commits

Author SHA1 Message Date
Steve Checkoway 15611d510b Simplify. Remove the condition from the iterator. Almost nothing uses it (although other things could), it seems more trouble than it's worth. 2007-09-17 03:27:33 +00:00
Chris Danford 0160e23705 style cleanup: use FOREACH_ENUM( X, x ) everywhere instead of FOREACH_X( x ) for consistency
The FOREACH_X defines are not very useful, and they were created back before FOREACH_ENUM was convenient.
2007-02-23 22:29:42 +00:00
Chris Danford 4e5219cedd SubType_INVALID -> SubType_Invalid 2007-01-15 23:47:55 +00:00
Chris Danford 46a774b5f4 SubType_invalid -> SubType_INVALID 2007-01-15 23:09:23 +00:00
Chris Danford 2f7ac6aa3c Add m_ to StageStats and PlayerStageStats members. There are several methods of these classes with local variable names that are similar to the member names. m_ helps distinguish between those two types. 2006-11-14 11:13:21 +00:00
Chris Danford 21fafaa046 add all_tracks_reverse_iterator 2006-10-22 23:08:13 +00:00
Steve Checkoway 9f1bb1e16f Simplify. 2006-07-21 08:01:28 +00:00
Steve Checkoway d46ec7136e Pass in a PlayerNumber as well.
(This breaks other code, commits coming.)
2006-07-17 00:54:46 +00:00
Steve Checkoway af1652ef28 Add a PlayerNumber. If pn = PLAYER_INVALID, then count all tap notes, irrespective of player. If tn.pn = PLAYER_INVALID, count it. 2006-07-14 04:14:51 +00:00
Steve Checkoway c6ba8423b6 Change this interface to return the tap note itself, rather than just the result. 2006-07-10 04:29:19 +00:00
Steve Checkoway 0b8e8f8512 Use a PlayerStageStats rather than indexing into STATSMAN with a PlayerNumber. 2006-07-10 00:02:07 +00:00
Steve Checkoway 161aa4a035 cleanup 2006-07-07 19:34:51 +00:00
Steve Checkoway 4deb8b8237 Spacing cleanup. 2006-06-16 23:01:38 +00:00
Chris Danford 0b98adff15 make RadarCategory enum and Lua names consistent 2005-12-24 20:18:56 +00:00
Chris Danford feb1bfb0fc naming cleanup: rename scoring "Tier1"s to "W1"s (short for "Window 1")
add Preference1D so that we can index into the grading and life values
2005-10-09 04:30:59 +00:00
Chris Danford b6cf3477b4 Use generic names for TapNoteScore values since they are treated genericly by the code.
Theme changes coming...
2005-10-08 00:57:40 +00:00
Glenn Maynard 4ec405f13b IsHoldNoteAtBeat -> IsHoldNoteAtRow 2005-07-22 00:14:24 +00:00
Chris Danford c36df02254 add rolls to eval and scoring 2005-05-09 06:15:59 +00:00
Chris Danford b5bac56889 fix broken HoldNoteScore count calculation 2005-05-01 05:08:45 +00:00
Chris Danford b33f16d9b7 show early/late in judgment
larger boo window when playing beginner
2005-04-28 00:13:01 +00:00
Glenn Maynard e146476eb5 cleanup 2005-04-25 11:34:08 +00:00
Glenn Maynard 78331c76f3 cleanup 2005-04-25 11:33:17 +00:00
Glenn Maynard c8f39053eb implement RADAR_NUM_ROLLS to fix assertion failure 2005-04-25 10:01:39 +00:00
Chris Danford d4df3a1431 fix successful jumps miscalculation: Player used "latest tap note score". Scoring used "min tap note score". 2005-04-13 04:08:51 +00:00
Chris Danford d312ea5bef add TNS_AVOIDED_MINE. Fixes unattempted mines counted as successful when ending early. 2005-04-13 01:11:44 +00:00
Chris Danford 5befb60456 method name cleanup, add comments 2005-03-20 20:15:41 +00:00
Chris Danford bb712884bb move global StageStats into a singleton 2005-02-16 03:25:45 +00:00
Glenn Maynard 98a558006b fix hands results 2005-02-08 02:08:04 +00:00
Glenn Maynard 06b6f9e185 cleanup 2005-01-25 19:12:03 +00:00
Glenn Maynard bb7482e722 evil big commit (sorry):
Remove m_HoldNote array entirely.  Remove 2sAnd3s.  Store hold note
durations in the hold head.  hold_tail only still exists when InsertHoldTails
is used, to make SM parsing a little easier (may go away).  Add helpers
for iterating over ranges while including or excluding adjacent and overlapping
hold notes.  Range operations are now [start,end) instead of [start,end].
(probably more details coming to sm-dev soon)
2005-01-25 05:02:35 +00:00
Glenn Maynard 9735755e00 Add MAX_NOTE_ROW, indicating the maximum row that we can represent.
We can actually go much higher; I set this to 1<<30 instead of 1<<31 so
we don't overflow when eg. adding one beat or one measure in some
algorithms.

The advantage of this over "999999" is it won't break if ROWS_PER_BEAT
is changed to a large value.

Also, since this value will typically be much larger than any actual row, it'll
quickly show up any algorithms that aren't iterating properly.

An advantage over older code using 999999 is that we don't have to
manually clamp the value to a reasonable range; FOREACH_NONEMPTY_ROW_IN_TRACK_RANGE,
etc. don't care.

An advantage of this over using -1 as a sentinel is that we don't have to
carefully check and fill in the value in every function using it.
2005-01-22 18:51:51 +00:00
Glenn Maynard 22f8eb1214 simplify 2005-01-22 18:37:50 +00:00
Glenn Maynard 4970e024f3 NoteDataWithScoring has no members; turn it into a namespace 2005-01-22 18:22:38 +00:00
Glenn Maynard 765d6019f7 cleanups 2005-01-22 16:12:31 +00:00
Glenn Maynard 46ace22b79 continue merging NoteDataWithScoring stuff 2005-01-22 02:10:54 +00:00
Glenn Maynard c321bbe196 start merging NoteDataWithScoring and NoteField per-hold and per-tap
data into TapNote and HoldNote.  This reduces lookup costs significantly.
It's a bit simpler, though I'm not entirely happy with the resulting encapsulation ...
2005-01-22 01:37:32 +00:00
Glenn Maynard 5407f0998e merge tap result into a TapNoteResult struct 2005-01-21 22:50:13 +00:00
Chris Danford 09d018444e split StageStats into player-specific and non-player-specific structs 2004-12-20 10:47:41 +00:00
Glenn Maynard f63c57b5f4 remove GetTapNoteX 2004-10-25 03:16:40 +00:00
Chris Danford 1b3c786213 cleanup: variable name and const 2004-10-24 10:20:24 +00:00
Chris Danford 0f6ed81faf Use a associative arrays instead of normal vectors to hold TapNotes.
More places NoteDataUtil, NoteDataWithScoring need to be converted to use the new row iteration macros.
2004-09-29 06:43:57 +00:00
Chris Danford d2a54cca31 make TapNote a struct. Over time, more properties will move from the enums and into bit flags. 2004-09-12 05:56:24 +00:00
Chris Danford 809dd7dc27 rename: MaxRow -> NumRows
fix some off-by-1 row errors
2004-09-11 03:50:37 +00:00
Chris Danford 05257b050c fix combo and life history don't accumulate correctly in courses
change combo and life history position units to Seconds from Beats
2004-07-24 18:11:04 +00:00
Chris Danford 96ca652c94 move RadarValues into a separate file
clean up usage of RadarValues
2004-07-11 07:21:33 +00:00
Glenn Maynard 2cab5c4689 license updates 2004-05-31 22:42:12 +00:00
Chris Danford d65404e750 TapSteps -> TapNotes 2004-05-24 04:26:54 +00:00
Chris Danford 4bb777232d name cleanup: "pNotes" -> "pSteps" 2004-05-24 03:41:39 +00:00
Glenn Maynard 9c1a5f6957 encapsulate hold results in HoldNoteResult (HoldNoteScore + life)
instead of moving HoldNote::iStartRow forward while a hold note is
held, set HoldNoteResult::iLastHeldRow
fixes hold heads cycling through all note colors while held (wasn't very
visible due to the hold ghost) and GetSuccessfulHands bugs
2004-05-07 04:57:29 +00:00
Glenn Maynard c139ce871e fix results voltage 2004-02-23 23:21:14 +00:00