Question about pausing and resuming a game
  • I tried the following scripts and it doesn't appear to work. What am i missing?

    $("#mbutton a").on('click',function(e){
    e.preventDefault();
    $.playground().clearAll();
    });

    $("#mbuttonb a").on('click',function(e){
    e.preventDefault();
    $.playground().resumeGame();
    });

    when I click pause, everything goes away.  But when I click resume right after that, nothing loads.



  • Got it!

    $('#mbutton').toggle(function(e) {
    e.preventDefault();
    $.playground().pauseGame();
    },function(){
    $.playground().resumeGame();
    });

    #mbutton being my anchor link.

This discussion has been closed.
All Discussions

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!