forked from len0rd/rockbox
Brickmania: Add an extra check in the hit logic to make sure that the brick isn't /hit/ after it has been removed from play.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22938 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
1f4245be34
commit
5f93489218
1 changed files with 4 additions and 1 deletions
|
|
@ -1141,6 +1141,9 @@ static int brickmania_find_empty_fire(void)
|
|||
|
||||
void brick_hit(int brick_number)
|
||||
{
|
||||
if(!brick[brick_number].used)
|
||||
return;
|
||||
|
||||
/* if this is a crackable brick hits starts as
|
||||
* greater than 0.
|
||||
*/
|
||||
|
|
@ -1150,7 +1153,7 @@ void brick_hit(int brick_number)
|
|||
score+=2;
|
||||
}
|
||||
else {
|
||||
brick[brick_number].used=0;
|
||||
brick[brick_number].used=false;
|
||||
/* Was there a powerup on the brick? */
|
||||
if (brick[brick_number].power<10) {
|
||||
/* Activate the powerup */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue