Created
December 26, 2019 11:14
-
-
Save Stals/ad0c2a4a62d3e7ea4acf4a53b0c0d0f7 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html lang="en-us"> | |
<head> | |
<style> | |
canvas { | |
width: 100%; | |
height: 100%; | |
position: absolute; | |
} | |
</style> | |
<meta charset="utf-8"> | |
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"> | |
<title>%UNITY_WEB_NAME%</title> | |
<script src="%UNITY_WEBGL_LOADER_URL%"></script> | |
<script> | |
//turn off unity's annoying alert() dialog. | |
UnityLoader.Error.handler = function(){} | |
var gameInstance = UnityLoader.instantiate("gameContainer", "%UNITY_WEBGL_BUILD_URL%"); | |
</script> | |
</head> | |
<body> | |
<div id="gameContainer" style="width: 100%; height: 100%; position: absolute; margin: auto"></div> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is a modified Unity's index.html that I used for my web gamedev tools made using Unity & WebAssembly.