Skip to content

Commit

Permalink
Minor CSS fixes and a bug fix
Browse files Browse the repository at this point in the history
Fixes a bug that meant the time and clones wasn't filled out correctly
  • Loading branch information
hobnob committed Nov 27, 2012
1 parent 5842e6d commit f597d54
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 5 deletions.
4 changes: 2 additions & 2 deletions css/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@
width:180px;
height:92px;
top:-313px;
margin-left:275px;
margin-left:277px;
}

#game_scorecard .nextLevel:hover
Expand All @@ -144,5 +144,5 @@
width:100px;
height:101px;
top:-160px;
margin-left:197px;
margin-left:198px;
}
4 changes: 2 additions & 2 deletions js/lib/scorecard.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,8 @@ function scorecard()
}

this.show = function(){
$('#game_scorecard p.clones').text(_clones);
$('#game_scorecard p.time').text(_calcTime());
$('#game_scorecard .clones').text(_clones);
$('#game_scorecard .time').text(_calcTime());

var score = 0;

Expand Down
16 changes: 15 additions & 1 deletion js/lib/startMenu.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,10 +37,24 @@ function startMenu()
return false;
}

$('.nextLevel .resetLevel').die();
var backToMenu = function(event){
if ( typeof(event) !== 'undefined' )
{
event.preventDefault();
}

_world = null;
$('#game_scorecard_bg').remove();
return false;
}

$('.nextLevel').die();
$('.resetLevel').die();
$('.mainMenu').die();

$('.nextLevel').live('click', nextLevel);
$('.resetLevel').live('click', resetLevel);
$('.mainMenu').live('click', backToMenu);

//Initialise the first level
nextLevel();
Expand Down

0 comments on commit f597d54

Please sign in to comment.