index.html 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  5. <meta charset="UTF-8">
  6. <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  7. <title>滑木块</title>
  8. <link rel="apple-touch-icon" sizes="57x57" href="touch-icon-ipad.png">
  9. <link rel="apple-touch-icon" sizes="114x114" href="touch-icon-iphone-retina.png">
  10. <!-- Allow fullscreen mode on iOS devices. (These are Apple specific meta tags.) --><meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, minimal-ui">
  11. <meta name="apple-mobile-web-app-capable" content="yes">
  12. <meta name="apple-mobile-web-app-status-bar-style" content="black">
  13. <!-- <link rel="apple-touch-icon" sizes="256x256" href="icon-256.png"> -->
  14. <meta name="HandheldFriendly" content="true">
  15. <!-- Chrome for Android web app tags --><meta name="mobile-web-app-capable" content="yes">
  16. <!-- <link rel="shortcut icon" sizes="256x256" href="icon-256.png"> -->
  17. <!-- All margins and padding must be zero for the canvas to fill the screen. --><style>#sg-loadscrn{
  18. position:fixed; top:0;left:0;width:100%; height:100%; background-color:#fff; z-index:9999;
  19. }
  20. #sg-loadtext{
  21. position:absolute;
  22. font-family: sans-serif;
  23. top:50%; left:50%;
  24. width: 250px;
  25. margin-left:-125px;
  26. margin-top:-125px;
  27. text-align:center;
  28. line-height:150%;
  29. font-size:16px;
  30. }</style>
  31. <script type="text/javascript" src="./assets/softgames-1.1.js"></script><script type="text/javascript" src="./assets/sg.hooks.js"></script><script type="text/javascript">
  32. window.gameLangs = ['en', 'es'];
  33. window.gameJS = ['jquery-2.0.0.min.js', 'c2runtime.js'];
  34. window.gameOnLoadScript = "startWoblox();";
  35. </script><script type="text/javascript" src="./localization.js"></script>
  36. </head>
  37. <body>
  38. <style type="text/css">
  39. * {
  40. padding: 0;
  41. margin: 0;
  42. }
  43. body {
  44. background: #000;
  45. color: #fff;
  46. overflow: hidden;
  47. -ms-touch-action: none;
  48. }
  49. canvas {
  50. touch-action-delay: none;
  51. touch-action: none;
  52. -ms-touch-action: none;
  53. }
  54. </style>
  55. <div id="fb-root"></div>
  56. <!-- The canvas must be inside a div called c2canvasdiv -->
  57. <div id="c2canvasdiv">
  58. <!-- The canvas the project will render to. If you change its ID, don't forget to change the
  59. ID the runtime looks for in the jQuery events above (ready() and cr_sizeCanvas()). -->
  60. <canvas id="c2canvas" width="384" height="600"><!-- This text is displayed if the visitor's browser does not support HTML5.
  61. You can change it, but it is a good idea to link to a description of a browser
  62. and provide some links to download some popular HTML5-compatible browsers. --><h1>Your browser does not appear to support HTML5. Try upgrading your browser to the latest version. <a href="http://www.whatbrowser.org">What is a browser?</a>
  63. <br><br><a href="http://www.microsoft.com/windows/internet-explorer/default.aspx">Microsoft Internet Explorer</a><br><a href="http://www.mozilla.com/firefox/">Mozilla Firefox</a><br><a href="http://www.google.com/chrome/">Google Chrome</a><br><a href="http://www.apple.com/safari/download/">Apple Safari</a><br><a href="http://www.google.com/chromeframe">Google Chrome Frame for Internet Explorer</a><br>
  64. </h1>
  65. </canvas>
  66. </div>
  67. <script>
  68. function startWoblox(){
  69. var resizeme = function() {
  70. cr_sizeCanvas(jQuery(window).width(), jQuery(window).height());
  71. };
  72. // Size the canvas to fill the browser viewport.
  73. jQuery(window).resize(resizeme);
  74. SG_Hooks.setOrientationHandler(resizeme);
  75. SG_Hooks.setResizeHandler(resizeme);
  76. // Start the Construct 2 project running on window load.
  77. // Create new runtime using the c2canvas
  78. cr_createRuntime("c2canvas");
  79. // Pause and resume on page becoming visible/invisible
  80. function onVisibilityChanged() {
  81. if (document.hidden || document.mozHidden || document.webkitHidden || document.msHidden)
  82. cr_setSuspended(true);
  83. else
  84. cr_setSuspended(false);
  85. };
  86. document.addEventListener("visibilitychange", onVisibilityChanged, false);
  87. document.addEventListener("mozvisibilitychange", onVisibilityChanged, false);
  88. document.addEventListener("webkitvisibilitychange", onVisibilityChanged, false);
  89. document.addEventListener("msvisibilitychange", onVisibilityChanged, false);
  90. }
  91. </script>
  92. </body>
  93. </html>