mirror of
https://github.com/doukutsu-rs/doukutsu-rs
synced 2025-01-10 13:07:17 +00:00
prepare it for api docs
This commit is contained in:
parent
812acac4e8
commit
7ef3b70edb
19
src/scripting/doukutsu.d.ts
vendored
19
src/scripting/doukutsu.d.ts
vendored
|
@ -69,6 +69,25 @@ declare namespace doukutsu {
|
|||
*/
|
||||
function playMusic(id: number): void;
|
||||
|
||||
/**
|
||||
* Sets an implementation-defined game setting.
|
||||
* @param name
|
||||
* @param value
|
||||
*/
|
||||
function setSetting(name: string, value: any): void;
|
||||
|
||||
/**
|
||||
* Registers an event handler called after all scripts are loaded.
|
||||
* @param event event name
|
||||
* @param handler event handler procedure
|
||||
*/
|
||||
function on(event: "init", handler: EventHandler<void>): EventHandler<void>;
|
||||
|
||||
/**
|
||||
* Registers an event handler called on each tick.
|
||||
* @param event event name
|
||||
* @param handler event handler procedure
|
||||
*/
|
||||
function on(event: "tick", handler: EventHandler<DoukutsuScene>): EventHandler<DoukutsuScene>;
|
||||
|
||||
function on<T>(event: string, handler: EventHandler<T>): EventHandler<T>;
|
||||
|
|
23
src/scripting/tsconfig.json
Normal file
23
src/scripting/tsconfig.json
Normal file
|
@ -0,0 +1,23 @@
|
|||
{
|
||||
"files": [
|
||||
"doukutsu.d.ts"
|
||||
],
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"target": "es6",
|
||||
"lib": [
|
||||
"es2018"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "./",
|
||||
"typeRoots": [
|
||||
"./"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue