fdg
gdfg
This commit is contained in:
parent
3e7bb83d82
commit
78bec662f5
13 changed files with 42 additions and 52 deletions
14
client/.vscode/tasks.json
vendored
14
client/.vscode/tasks.json
vendored
|
@ -2,21 +2,11 @@
|
||||||
// See https://go.microsoft.com/fwlink/?LinkId=733558
|
// See https://go.microsoft.com/fwlink/?LinkId=733558
|
||||||
// for the documentation about the tasks.json format
|
// for the documentation about the tasks.json format
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"tasks": [
|
|
||||||
{
|
|
||||||
"taskName": "typescript",
|
|
||||||
"command": "tsc",
|
"command": "tsc",
|
||||||
"isShellCommand": true,
|
"isShellCommand": true,
|
||||||
"args": ["-w", "-p", "."],
|
"args": ["-w", "-p", "."],
|
||||||
//"showOutput": "silent",
|
//"showOutput": "silent",
|
||||||
"isBackground": true,
|
"isBackground": true,
|
||||||
"problemMatcher": "$tsc-watch"
|
"problemMatcher": "$tsc-watch",
|
||||||
},
|
"isBuildCommand": true
|
||||||
{
|
|
||||||
"taskName": "compile",
|
|
||||||
"command": "build.bat",
|
|
||||||
"isShellCommand": true,
|
|
||||||
"showOutput": "silent"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
|
@ -1,5 +1,5 @@
|
||||||
@echo off
|
@echo off
|
||||||
del lib.js > nul 2>&1
|
del lib.js > nul 2>&1
|
||||||
copy raw\*.js /a lib-raw.js /b > nul 2>&1
|
copy lib\*.js /a lib-raw.js /b > nul 2>&1
|
||||||
cmd /C "uglifyjs lib-raw.js -o lib.js"
|
cmd /C "uglifyjs lib-raw.js -o bin\lib.js"
|
||||||
del lib-raw.js
|
del lib-raw.js > nul 2>&1
|
||||||
|
|
|
@ -82,9 +82,10 @@
|
||||||
<p>
|
<p>
|
||||||
The required features are:
|
The required features are:
|
||||||
<ul>
|
<ul>
|
||||||
<li id="supchk1" class="cross">Canvas</li>
|
<li id="supchk1" class="cross">Animation Frames</li>
|
||||||
<li id="supchk2" class="cross">WebGL</li>
|
<li id="supchk2" class="cross">Canvas</li>
|
||||||
<li id="supchk3" class="cross">IndexedDB</li>
|
<li id="supchk3" class="cross">WebGL</li>
|
||||||
|
<li id="supchk4" class="cross">IndexedDB</li>
|
||||||
</ul>
|
</ul>
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
|
|
|
@ -1,20 +0,0 @@
|
||||||
var FileCache = (function () {
|
|
||||||
function FileCache() {
|
|
||||||
}
|
|
||||||
FileCache.Initialize = function () {
|
|
||||||
var request = window.indexedDB.open("fileCache", 1);
|
|
||||||
request.onupgradeneeded = function (event) {
|
|
||||||
};
|
|
||||||
};
|
|
||||||
return FileCache;
|
|
||||||
}());
|
|
||||||
FileCache.dbHandle = null;
|
|
||||||
/// <reference path="FileCache.ts" />
|
|
||||||
var Entrypoint = (function () {
|
|
||||||
function Entrypoint() {
|
|
||||||
}
|
|
||||||
Entrypoint.Main = function () {
|
|
||||||
FileCache.Initialize();
|
|
||||||
};
|
|
||||||
return Entrypoint;
|
|
||||||
}());
|
|
|
@ -5,8 +5,15 @@
|
||||||
<link rel="stylesheet" type="text/css" href="style.css" />
|
<link rel="stylesheet" type="text/css" href="style.css" />
|
||||||
<meta charset="UTF-8" />
|
<meta charset="UTF-8" />
|
||||||
|
|
||||||
<script type="text/javascript" src="lib.js"></script>
|
<script type="text/javascript" src="bin/lib.js"></script>
|
||||||
<script type="text/javascript" src="game.js"></script>
|
<script type="text/javascript" src="bin/scape.js"></script>
|
||||||
|
|
||||||
|
<script type="notjs" id="loading-vertex">
|
||||||
|
|
||||||
|
</script>
|
||||||
|
<script type="notjs" id="loading-frag">
|
||||||
|
|
||||||
|
</script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<canvas id="cs"></canvas>
|
<canvas id="cs"></canvas>
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -1,5 +1,8 @@
|
||||||
|
// feature checking trashcode (c) obrado 1989
|
||||||
|
|
||||||
window.onload = function() {
|
window.onload = function() {
|
||||||
var support = {
|
var support = {
|
||||||
|
anim: true,
|
||||||
canvas: true,
|
canvas: true,
|
||||||
webgl: true,
|
webgl: true,
|
||||||
idb: true
|
idb: true
|
||||||
|
@ -20,8 +23,9 @@ window.onload = function() {
|
||||||
if(!window.indexedDB)
|
if(!window.indexedDB)
|
||||||
support.idb = false;
|
support.idb = false;
|
||||||
|
|
||||||
if(!support.canvas || !support.webgl || !support.idb) {
|
if(!support.anim || !support.canvas || !support.webgl || !support.idb) {
|
||||||
window.location.href = "error.html?err="+ (+support.canvas)
|
window.location.href = "error.html?err="+ (+support.anim)
|
||||||
|
+""+ (+support.canvas)
|
||||||
+""+ (+support.webgl)
|
+""+ (+support.webgl)
|
||||||
+""+ (+support.idb);
|
+""+ (+support.idb);
|
||||||
return;
|
return;
|
|
@ -4,8 +4,11 @@ class FileCache {
|
||||||
static Initialize(): void {
|
static Initialize(): void {
|
||||||
var request = window.indexedDB.open("fileCache", 1);
|
var request = window.indexedDB.open("fileCache", 1);
|
||||||
|
|
||||||
request.onupgradeneeded = function(event) {
|
request.onupgradeneeded = function(event: any) {
|
||||||
|
var db: IDBDatabase = event.target.result;
|
||||||
|
db.createObjectStore("files", {keyPath: "name"});
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static
|
||||||
}
|
}
|
1
client/src/MD5.d.ts
vendored
Normal file
1
client/src/MD5.d.ts
vendored
Normal file
|
@ -0,0 +1 @@
|
||||||
|
declare function md5(input: string, key?: string, raw?: boolean);
|
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
"target": "es5",
|
"target": "es5",
|
||||||
"out": "game.js",
|
"out": "bin/scape.js",
|
||||||
"watch": true
|
"watch": true
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -63,6 +63,12 @@
|
||||||
<None Include="App.config" />
|
<None Include="App.config" />
|
||||||
<None Include="packages.config" />
|
<None Include="packages.config" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
<ItemGroup>
|
||||||
|
<Folder Include="Assets\Animations\" />
|
||||||
|
<Folder Include="Assets\Models\" />
|
||||||
|
<Folder Include="Assets\Shaders\" />
|
||||||
|
<Folder Include="Assets\Textures\" />
|
||||||
|
</ItemGroup>
|
||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
<Import Project="packages\System.Data.SQLite.Core.1.0.105.0\build\net451\System.Data.SQLite.Core.targets" Condition="Exists('packages\System.Data.SQLite.Core.1.0.105.0\build\net451\System.Data.SQLite.Core.targets')" />
|
<Import Project="packages\System.Data.SQLite.Core.1.0.105.0\build\net451\System.Data.SQLite.Core.targets" Condition="Exists('packages\System.Data.SQLite.Core.1.0.105.0\build\net451\System.Data.SQLite.Core.targets')" />
|
||||||
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
|
||||||
|
|
Loading…
Reference in a new issue