base game

This commit is contained in:
Johannes
2026-03-12 16:50:36 +01:00
commit 992ee59995
52 changed files with 54181 additions and 0 deletions

26
libs/webpack-interface.js Normal file
View File

@@ -0,0 +1,26 @@
let wiRes = {}
let wiCounter = 0
class wi {
static get res(){ return wiRes }
static set res(v){ wiRes = v}
static get c(){ return wiCounter }
static set c(v){ wiCounter = v }
static register(fun) {
const index = this.c++;
this.res[index] = fun;
return `wi.call(${index});`
}
static call(id) {
this.res[id]();
}
static reset(){
this.res = {}
this.c = 0
}
static publishFunction(name, fun){
window[name] = fun
return `${name}`
}
}