This is the bug/patch tracker for Rockbox. Click here for more information.
Quick links: Bugs · Patches · Rockbox frontpage
FS#9041 - Jewels - Score cleared on level change
Attached to Project:
Rockbox
Opened by Corey (EMonk) - Monday, 26 May 2008, 02:37 GMT+1
Last edited by Adam Boot (rotator) - Saturday, 31 May 2008, 01:12 GMT+1
Opened by Corey (EMonk) - Monday, 26 May 2008, 02:37 GMT+1
Last edited by Adam Boot (rotator) - Saturday, 31 May 2008, 01:12 GMT+1
|
DetailsWhen changing to a new level on Jewels the scored is cleared to the base for the level immediately after re-filling the board and before checking for 3+ groupings in the new board.
While not normally an issue, it is possible to have a multi-drop or 4+ group which brings the score above the next 100-point level threshold. Any points gained which exceed the 100-point level are discarded. The worst case I have had is an 8-point set bringing my score to 307, which was reset to 300 after level change. |
This task depends upon
Closed by Adam Boot (rotator)
Saturday, 31 May 2008, 01:12 GMT+1
Reason for closing: Fixed
Additional comments about closing: Fixed in r17664
Saturday, 31 May 2008, 01:12 GMT+1
Reason for closing: Fixed
Additional comments about closing: Fixed in r17664
Is the current scoring method different from other jewel-like games?
I'll close this task if you don't have any objections.
If it's by design, no worries... except I feel slightly disappointed when it happens :)
Adam:
I don't play in Puzzle mode, so I have no comment on point rollover there. In normal game mode however it *does* clear the points.
I've just had my first look at the source and I think I've found the culprit near the bottom of the jewels_main loop in the following lines:
case GAME_TYPE_NORMAL:
if(bj->score >= LEVEL_PTS) bj->score = jewels_nextlevel(bj);
break;
Now, presuming that bj->level = 1 and bj->score = 103 prior to this point, immediately after jewels_nextlevel returns but prior to the assignment bj->level = 2 and bj->score = 3, which is correct. Unfortunately bj->score is then overwritten by the assignment which replaces it with the points gained from any drops that happened in the new board only. If we assume that no valid drops were generated by the newly added jewels during jewels_initlevel, then return from jewels_nextlevel will be 0 and player's total score will be (bj->level-1)*LEVEL_PTS+bj->score = 200.
Simplest fix might be to change the above to read "... bj->score += jewels_nextlevel(bj);" or similar.