Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

debugging stdout in client

  • Loading branch information...
commit 3c45f91a995252a05892d678b9b5562cd8b0667b 1 parent 434a5fa
@kripken authored
Showing with 3 additions and 0 deletions.
  1. +1 −0  cube2/game.html
  2. +2 −0  cube2/js/game-setup.js
View
1  cube2/game.html
@@ -102,6 +102,7 @@
<p><a href="index.html">&lt; Back to Main Page</a></p>
</div>
<canvas id="canvas" class="hide" oncontextmenu="event.preventDefault()"></canvas>
+ <!--textarea id="stdout" cols="100" rows="8"></textarea-->
<script type='text/javascript' src='js/game-setup.js'></script>
<script src="//www.mozilla.org/tabzilla/media/js/tabzilla.js"></script>
</body>
View
2  cube2/js/game-setup.js
@@ -7,6 +7,8 @@ var Module = {
preloadPlugins: [],
print: function(text) {
console.log('[STDOUT] ' + text);
+ //if (!Module.stdoutElement) Module.stdoutElement = document.getElementById('stdout');
+ //Module.stdoutElement.value += text + '\n';
},
printErr: function(text) {
console.log(text);
Please sign in to comment.
Something went wrong with that request. Please try again.