Rest of code (because I didn't have enough space): // initialize labels $('#press').html(label_press); $('#collect').html(label_collect); $('#total_term').html(label_balance); $('#total_value').html(total+label_currency); $('#last_term').html(label_last); $('#last_value').html(last_win+label_currency); // below: create functions that define game functionality // what happens when a new round starts var new_round = function() { console.log(number_pumps); console.log(exploded); $('#gonext').hide(); $('#message').hide(); $('#collect').show(); $('#press').show(); round += 1; size = start_size; pumps = 0; $('#ballon').
<script>$(document).ready(function() { var saveThis = 'hidden'; // text fields that saves data should not be shown; can be shown in testing // initialize values var round = 0; var start_size = 150; // start value of widht & height of the image; must correspond to the value that is specified for the #ballon id in style.css var increase = 2; // number of pixels by which balloon is increased each pump var size; // start_size incremented by 'increase' var pumps; var total = 0; // money that has been earned in total var rounds_played = 30; var explode_array = [31, 80, 63, 103, 20, 26, 100, 75, 109, 72, 88, 77, 113, 22, 83, 86, 57, 14, 9, 90, 56, 41, 56, 27, 108, 42, 116, 18, 43, 95]; var maximal_pumps = 128; var pumpmeup; // number pumps in a given round; is updated each round var number_pumps = []; // arr
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.
Sorry, we're still checking this file's contents to make sure it's safe to download. Please try again in a few minutes.
Sorry, our virus scanner detected that this file isn't safe to download.