Make a Mini Game Popup

0 favourites
  • 5 posts
From the Asset Store
Relax and relieve stress by popping bubbles in Fidget Anti- Stress Releaser!
  • I'm new here, but I've been searching and I can't find an answer. Maybe I'm using the wrong terminology in my searches.

    Here's the background of my game. It's a simple platformer that has a few levels in it. When the main character dies, they will be presented with a mini game. If they are successful in the mini game, they will be able to continue exactly at the point they died. The mini game would be a full screen scene or level.

    I can't figure out how to accomplish this. I don't want to load a new level and lose the current progress and it seems like making a bunch of new layers would be too much overhead, especially for every time the mini game presents itself. I may also want to make different mini games based on progress/level etc.

    In Corona SDK they have a modal popup that could load a new scene over the current scene. Is there something similar?

  • <Head>

    <script type="text/javascript">

    function popup(){

    cuteLittleWindow = window.open("http://localhost:50000/", "littleWindow", "location=no,width=1024,height=1024");

    }

    </script>

    </Head>

    <body>

    <a href="javascript:popup('red.html')">Here is a popup window.</a>

    </body>

    Copy and paste that into a text editor, and save it.

    Run a game from C2 by pressing F5.

    Open up a browser, and drag the file onto the browser to run it.

    That is the only way I have found so far. I have no idea how to make it dynamically open up a window like that without user clicking on a link first.

    I was going to try had get 2 instances of C2 to communicate, but I have not had the time yet. If you get it working please post how you did it, to save us some time :)

    I want to use it as a floating tool pallet for my texture editor I am making.

  • That code will open a new pop up window, or does construct block the native behavior?

    I basically want to load the mini game level over the current level, basically blocking and pausing the original level. The continuing and dismissing the mini game if successful or going to the game over screen.

    Still new to Construct, so I'm not sure exactly what HTML and JS options are available.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • jojoe

    Any reason why you wouldn't want to use "onload"? That would certainly allow you to open that link without the need for additional user input.

  • Any reason why you wouldn't want to use "onload"?

    Just me being a newbie.Thank you very much for the information :) I was racking my brain trying to think of how I could do this.

    +1 Karma for you

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)