index.html 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <title>b22</title>
  6. <!--http://www.html5rocks.com/en/mobile/mobifying/-->
  7. <meta name="viewport"
  8. content="width=device-width,user-scalable=no,initial-scale=1, minimum-scale=1,maximum-scale=1"/>
  9. <!--https://developer.apple.com/library/safari/documentation/AppleApplications/Reference/SafariHTMLRef/Articles/MetaTags.html-->
  10. <meta name="apple-mobile-web-app-capable" content="yes">
  11. <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent">
  12. <meta name="format-detection" content="telephone=no">
  13. <!-- force webkit on 360 -->
  14. <meta name="renderer" content="webkit"/>
  15. <meta name="force-rendering" content="webkit"/>
  16. <!-- force edge on IE -->
  17. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"/>
  18. <meta name="msapplication-tap-highlight" content="no">
  19. <!-- force full screen on some browser -->
  20. <meta name="full-screen" content="yes"/>
  21. <meta name="x5-fullscreen" content="true"/>
  22. <meta name="360-fullscreen" content="true"/>
  23. <!-- force screen orientation on some browser -->
  24. <meta name="screen-orientation" content="portrait"/>
  25. <meta name="x5-orientation" content="portrait">
  26. <!--fix fireball/issues/3568 -->
  27. <!--<meta name="browsermode" content="application">-->
  28. <meta name="x5-page-mode" content="app">
  29. <!--<link rel="apple-touch-icon" href=".png" />-->
  30. <!--<link rel="apple-touch-icon-precomposed" href=".png" />-->
  31. <link rel="stylesheet" type="text/css" href="style-mobile.css"/>
  32. <link rel="icon" href="favicon.ico"/>
  33. </head>
  34. <body>
  35. <canvas id="GameCanvas" oncontextmenu="event.preventDefault()" tabindex="0"></canvas>
  36. <div id="splash">
  37. <div class="progress-bar stripes">
  38. <span style="width: 0%"></span>
  39. </div>
  40. </div>
  41. <script src="src/settings.js" charset="utf-8"></script>
  42. <script src="vconsole.min.js"></script>
  43. <script src="main.js" charset="utf-8"></script>
  44. <!--<自定义Start/>-->
  45. <script type="text/javascript">
  46. (function freshFuc() {
  47. var url = window.location.href
  48. if (url.indexOf('fresh') == -1) {
  49. if (url.indexOf('?') == -1) {
  50. url += ('?fresh=' + Date.now())
  51. } else {
  52. url += ('&fresh=' + Date.now())
  53. }
  54. window.location.replace(url)
  55. }
  56. })();
  57. </script>
  58. <!--<自定义End/>-->
  59. <script type="text/javascript">
  60. (function () {
  61. // open web debugger console
  62. if (typeof VConsole !== 'undefined') {
  63. window.vConsole = new VConsole();
  64. }
  65. var debug = window._CCSettings.debug;
  66. var splash = document.getElementById('splash');
  67. splash.style.display = 'block';
  68. function loadScript (moduleName, cb) {
  69. function scriptLoaded () {
  70. document.body.removeChild(domScript);
  71. domScript.removeEventListener('load', scriptLoaded, false);
  72. cb && cb();
  73. };
  74. var domScript = document.createElement('script');
  75. domScript.async = true;
  76. domScript.src = moduleName;
  77. domScript.addEventListener('load', scriptLoaded, false);
  78. document.body.appendChild(domScript);
  79. }
  80. loadScript(debug ? 'cocos2d-js.js' : 'cocos2d-js-min.js', function () {
  81. if (CC_PHYSICS_BUILTIN || CC_PHYSICS_CANNON) {
  82. loadScript(debug ? 'physics.js' : 'physics-min.js', window.boot);
  83. }
  84. else {
  85. window.boot();
  86. }
  87. });
  88. })();
  89. </script>
  90. </body>
  91. </html>