�50 to hide the address bar

0 favourites
  • 11 posts
From the Asset Store
You think you can guess the character’s name?! Then let’s see how smart you are!
  • In iphone 4 and android, its pretty easy to hide the address bar to get the extra screen space. E.g. go to google.com or mobile.williamhill.com with either handset, and you will see the addrss bar go.

    Some sites don't do this, e.g bbc.co.uk does not hide the address bar.

    We need a solution which allows the game to play in the full (retina or non-retina) resolution available without the addess bar (i.e. on ihpone 4: 960 - (height of the bottom tool bar - height of the top status bar)).

    1) This needs to work in portrait and landscape (and allow changes between)

    2) It must work with C2 crop fullscreen mode (as some UI elements are anchored to the endges and move relative to the edge to handle different screen sizes.

    3) It should allow the game to make full use of the maximum browser space avaialble without the address bar in the standard browsers on android and iphone.

    4) Other platforms, such as desktop browsers (such as FF, Chrome, IE etc), and ipad should not be affected.

    5) it must work in R99 (as all our projects are done in this version)

    6) It should work on the standard browser of the iphone 4, 4s and android 2.2 or higher. Iphone 3 highly desirable.

    There are thousands of posts on how to remove the addres bar, and many use this code or a variation:

    // if mobile browser detected

    addEventListener("load", function() {

        window.scrollTo(1, 0);

    }, false);

    However, this requires that the page is at least the screen size wihout the bar. The construct 2 window makes itself the size with the bar, i.e. on iphone 4 with retina enabled = 640x712

    To see the address bar go, simply put some <br><br><br> at the top or bottom of the body tag of the exported index.html, add the above js, and the bar will go. however, the C2 game still thinks its only 640x712, and the <br> obvoiusly screws up the page by adding blank areas.

    A solution might be:

    1) a list of modifications to the index.html produced by the the export function.

    2) a plugin for R99

    This must not use appmobi, phonegap or any other framework which bundels the game in proprietory container.

    Payment will be made on verification of source code working on our project, via bank transfer (UK banks) or paypal.

    Payment will purhcase full excluseive rights to use the solution in any manner.

    A partial amount (?10) will be paid if someone figures out a way to hard code this for retina size iphone 4/4s only, without affecting other browsers, and noone figures out the full solution (which would include android and non-retina)

    The deadline is 5pm (GMT+1) 29th Aug.

    If more than one sumbimsion is recieved by then, the best will be selected. if there are more than one with which work perfectly, then the first will be paid.

    If there are flaws, side-effects or issues with the solution, and these can be fixed within 2 days of the deadline, the amount will still be paid.

    If no-one can find a working soluion, then we will have to abandon C2 and abandon the project. :(

  • If you are building for android you can remove it in the android manifest.

  • If you are building for android you can remove it in the android manifest.

    Thanks mikepixie - is the manifest just for apps? Im looking for something for normal browser based games.

  • I have managed to get a hacky version which only works for iphone4 (breaks everything else).

    The addres bar is 120 high. The space for the game is 712+120=832.

    I made the game window 832 high, in crop fullscreen mode.

    Exported the project, then edited the index.html as below.

    Now need to wrap this in something which only does it if its the right version of android/iphone, and do scaling for android. Will this work on iphone3?

        <script>
    function hideAddressBar()
    {
      if(!window.location.hash)
      {     setTimeout( function(){ window.scrollTo(0, 1); }, 0 );
      }
    }
    window.addEventListener("load", function(){ if(!window.pageYOffset){ hideAddressBar(); } } );
    window.addEventListener("orientationchange", hideAddressBar );
    
              // Size the canvas to fill the browser viewport.
              jQuery(window).resize(function() {
                  ?cr_sizeCanvas(jQuery(window).width(), jQuery(window).height()+60);
              });
              
              window.addEventListener('orientationchange', cr_sizeCanvas, false);
         
              // Start the Construct 2 project running on window load.
              jQuery(document).ready(function ()
              {              ?
                  ?// Create new runtime using the c2canvas
                  ?cr_createRuntime("c2canvas");
                  ?
                  ?cr_sizeCanvas(jQuery(window).width(), jQuery(window).height()+60);
              });
              
    
    
  • I got no takers for this work, so have done it myself. If anyone wants paid work for creating games for mobile, plugins or workarounds like this, let me know as I have plenty.

    In fact, if anyone has any skill based game which works well on mobiles which last less than a minute (or can be adapted to do so), let me know and I'll make you an offer for the source code.

    We have grapic designers, so dont worry about the quailyt of the art.

  • Did you go from asking for help to asking to buy small games? If so, you should probably start a new thread. And give some more details, I'd love to make simple skilled games but I don't know anything besides how small you want the game to be.

  • Excellent, glad to have some interest. Do any of your games involve traffic cones by any chance?

    I'll write up a spec of what we are looking for, but basically we will consider anything, as most games are adaptable to touch/mobile. Currently we are targeting iphone4 type resolutions (832x640)which happen to look pretty good on the dekstop too.

  • Hi do you already get the solution to hide the address bar?..

  • fixious - it's now built in to Construct 2. Set the option in project properties.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Hi Ashley, thank you but when i set yes to hide address bar in configuration setting it's only hide the address bar for IOS not for Android <img src="smileys/smiley5.gif" border="0" align="middle" />

  • fixious : I am looking for a solution to hide address bar problem.Can you please help me?Thank you

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