Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix HUD and stats disappearing in fullscreen.

  • Loading branch information...
commit b65404d60aa25cdb09f7a0a95d8d81c2733e438e 1 parent 8714b84
@tapio authored
Showing with 40 additions and 40 deletions.
  1. +20 −19 game.html
  2. +20 −19 game_dev.html
  3. +0 −2  js/ui.js
View
39 game.html
@@ -19,27 +19,28 @@
</head>
<body>
- <div id="container"><br /><br /><br /><br /><br />Initializing...</div>
- <div id="instructions">
- <h1>Click to play</h1>
- (W, A, S, D = Move, Mouse = Look, LMB = Shoot,<br/>R = Reload, F = Flashlight)
- </div>
- <div id="message"></div>
- <div id="minor-messages"></div>
- <div id="hud">
- <img src="assets/icons/health.png" alt="Health" />
- <span id="health">n/a</span><br/>
- <img src="assets/icons/bullet.png" alt="Bullets" />
- <span id="bullets">n/a</span><br/>
- <img src="assets/icons/clip.png" alt="Clips" />
- <span id="clips">n/a</span><br/>
- </div>
+ <div id="container">
+ <div id="instructions">
+ <h1>Click to play</h1>
+ (W, A, S, D = Move, Mouse = Look, LMB = Shoot,<br/>R = Reload, F = Flashlight)
+ </div>
+ <div id="message"></div>
+ <div id="minor-messages"></div>
+ <div id="hud">
+ <img src="assets/icons/health.png" alt="Health" />
+ <span id="health">n/a</span><br/>
+ <img src="assets/icons/bullet.png" alt="Bullets" />
+ <span id="bullets">n/a</span><br/>
+ <img src="assets/icons/clip.png" alt="Clips" />
+ <span id="clips">n/a</span><br/>
+ </div>
- <div id="deathscreen">
- <div>Oh noes, you died!</div>
- </div>
+ <div id="deathscreen">
+ <div>Oh noes, you died!</div>
+ </div>
- <div id="renderer-info"></div>
+ <div id="renderer-info"></div>
+ </div>
<script src="build/libs.min.js"></script>
<script src="build/game.min.js"></script>
View
39 game_dev.html
@@ -19,27 +19,28 @@
</head>
<body>
- <div id="container"><br /><br /><br /><br /><br />Initializing...</div>
- <div id="instructions">
- <h1>Click to play</h1>
- (W, A, S, D = Move, Mouse = Look, LMB = Shoot,<br/>R = Reload, F = Flashlight)
- </div>
- <div id="message"></div>
- <div id="minor-messages"></div>
- <div id="hud">
- <img src="assets/icons/health.png" alt="Health" />
- <span id="health">n/a</span><br/>
- <img src="assets/icons/bullet.png" alt="Bullets" />
- <span id="bullets">n/a</span><br/>
- <img src="assets/icons/clip.png" alt="Clips" />
- <span id="clips">n/a</span><br/>
- </div>
+ <div id="container">
+ <div id="instructions">
+ <h1>Click to play</h1>
+ (W, A, S, D = Move, Mouse = Look, LMB = Shoot,<br/>R = Reload, F = Flashlight)
+ </div>
+ <div id="message"></div>
+ <div id="minor-messages"></div>
+ <div id="hud">
+ <img src="assets/icons/health.png" alt="Health" />
+ <span id="health">n/a</span><br/>
+ <img src="assets/icons/bullet.png" alt="Bullets" />
+ <span id="bullets">n/a</span><br/>
+ <img src="assets/icons/clip.png" alt="Clips" />
+ <span id="clips">n/a</span><br/>
+ </div>
- <div id="deathscreen">
- <div>Oh noes, you died!</div>
- </div>
+ <div id="deathscreen">
+ <div>Oh noes, you died!</div>
+ </div>
- <div id="renderer-info"></div>
+ <div id="renderer-info"></div>
+ </div>
<script src="libs/jquery-1.8.1.min.js"></script>
<script src="libs/dat.gui.min.js"></script>
View
2  js/ui.js
@@ -3,8 +3,6 @@ var renderStats, physicsStats, rendererInfo;
function initUI() {
var container = document.getElementById('container');
-
- container.innerHTML = "";
container.appendChild(renderer.domElement);
renderStats = new Stats();
Please sign in to comment.
Something went wrong with that request. Please try again.