keystonemc 1.0.0 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/event/eventManager.d.ts +33 -0
- package/dist/core/event/flow.d.ts +18 -0
- package/dist/core/event/priority.d.ts +8 -0
- package/dist/core/event/types.d.ts +6 -0
- package/dist/core/index.d.ts +7 -0
- package/dist/core/keystone.d.ts +5 -0
- package/dist/core/math/axisAlignedBB.d.ts +114 -0
- package/dist/core/math/vector3.d.ts +225 -0
- package/dist/core/timer/timer.d.ts +94 -0
- package/dist/core/utils/debugger.d.ts +1 -0
- package/dist/index.js +988 -0
- package/dist/vite-plugin/index.d.ts +11 -0
- package/dist/vite-plugin/index.js +120 -0
- package/package.json +1 -1
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { world } from '@minecraft/server';
|
|
2
|
+
import { Listener } from './types';
|
|
3
|
+
/**
|
|
4
|
+
* AfterEventMap / BeforeEventMap を world.afterEvents / world.beforeEvents の
|
|
5
|
+
* subscribe のハンドラ引数から自動抽出する。
|
|
6
|
+
*
|
|
7
|
+
* 例: world.afterEvents.playerSpawn.subscribe((ev: PlayerSpawnAfterEvent) => {...})
|
|
8
|
+
* の ev の型を自動的に E として取り出す。
|
|
9
|
+
*/
|
|
10
|
+
type ExtractSubscribeArg<T> = T extends {
|
|
11
|
+
subscribe: (handler: (ev: infer E) => any) => any;
|
|
12
|
+
} ? E : never;
|
|
13
|
+
export type AfterEventMap = {
|
|
14
|
+
[K in keyof typeof world.afterEvents]: ExtractSubscribeArg<(typeof world.afterEvents)[K]>;
|
|
15
|
+
};
|
|
16
|
+
export type BeforeEventMap = {
|
|
17
|
+
[K in keyof typeof world.beforeEvents]: ExtractSubscribeArg<(typeof world.beforeEvents)[K]>;
|
|
18
|
+
};
|
|
19
|
+
type AfterEventName = keyof AfterEventMap;
|
|
20
|
+
type BeforeEventName = keyof BeforeEventMap;
|
|
21
|
+
export declare class EventManager {
|
|
22
|
+
private static afterListeners;
|
|
23
|
+
private static beforeListeners;
|
|
24
|
+
/** init: world.beforeEvents / world.afterEvents を全自動で subscribe して dispatch に流す */
|
|
25
|
+
static initialize(): void;
|
|
26
|
+
static registerAfter<K extends AfterEventName>(eventName: K, listener: Listener<AfterEventMap[K]>): void;
|
|
27
|
+
static registerBefore<K extends BeforeEventName>(eventName: K, listener: Listener<BeforeEventMap[K]>): void;
|
|
28
|
+
private static dispatchAfter;
|
|
29
|
+
private static dispatchBefore;
|
|
30
|
+
/** 登録済みリスナーを全部クリア(Plugin 単位で実装するなら拡張する) */
|
|
31
|
+
private static clearAll;
|
|
32
|
+
}
|
|
33
|
+
export {};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
interface WaitForOptions {
|
|
2
|
+
onInterval?: () => void;
|
|
3
|
+
onTimeout?: () => void;
|
|
4
|
+
interval?: number;
|
|
5
|
+
timeout?: number;
|
|
6
|
+
resolveOnInterval?: boolean;
|
|
7
|
+
resolveOnTimeout?: boolean;
|
|
8
|
+
}
|
|
9
|
+
/**
|
|
10
|
+
* イベントを条件付きで待機(タイムアウト付き)
|
|
11
|
+
*/
|
|
12
|
+
export declare function waitFor<T extends object>(predicate: (event: T) => boolean, options?: WaitForOptions): Promise<T>;
|
|
13
|
+
/**
|
|
14
|
+
* 複数イベントを束ねて非同期フローを開始
|
|
15
|
+
* すべてのイベントで、Entityを自動検出
|
|
16
|
+
*/
|
|
17
|
+
export declare function flowListen<E extends object>(...args: any[]): void;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export { keystone } from './keystone';
|
|
2
|
+
export { Vector3 } from './math/vector3';
|
|
3
|
+
export { AxisAlignedBB } from './math/axisAlignedBB';
|
|
4
|
+
export { Priority } from './event/priority';
|
|
5
|
+
export { EventManager } from './event/eventManager';
|
|
6
|
+
export { debug } from './utils/debugger';
|
|
7
|
+
export { RepeatingTimer, DelayedTimer, repeating, delayed, sleep } from './timer/timer';
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
import { AABB, Vector3 } from '@minecraft/server';
|
|
2
|
+
export declare class AxisAlignedBB implements AABB {
|
|
3
|
+
center: Vector3;
|
|
4
|
+
extent: Vector3;
|
|
5
|
+
constructor(center: Vector3, extent: Vector3);
|
|
6
|
+
/**
|
|
7
|
+
* 最小点最大点からオブジェクト化
|
|
8
|
+
* @param min
|
|
9
|
+
* @param max
|
|
10
|
+
* @returns {AxisAlignedBB}
|
|
11
|
+
*/
|
|
12
|
+
static fromMinMax(min: Vector3, max: Vector3): AxisAlignedBB;
|
|
13
|
+
/**
|
|
14
|
+
* 大きさ1のAABB生成
|
|
15
|
+
* @returns {AxisAlignedBB}
|
|
16
|
+
*/
|
|
17
|
+
static one(): AxisAlignedBB;
|
|
18
|
+
/**
|
|
19
|
+
* {center, extent} オブジェクトから生成
|
|
20
|
+
* @param aabb
|
|
21
|
+
* @returns {AxisAlignedBB}
|
|
22
|
+
*/
|
|
23
|
+
static fromBDS(aabb: AABB): AxisAlignedBB;
|
|
24
|
+
/**
|
|
25
|
+
* 最小点
|
|
26
|
+
* @returns {Vector3}
|
|
27
|
+
*/
|
|
28
|
+
get min(): Vector3;
|
|
29
|
+
/**
|
|
30
|
+
* 最大点
|
|
31
|
+
* @returns {Vector3}
|
|
32
|
+
*/
|
|
33
|
+
get max(): Vector3;
|
|
34
|
+
/**
|
|
35
|
+
* オフセット
|
|
36
|
+
* @param dx
|
|
37
|
+
* @param dy
|
|
38
|
+
* @param dz
|
|
39
|
+
* @returns {AxisAlignedBB}
|
|
40
|
+
*/
|
|
41
|
+
offset(dx: number, dy: number, dz: number): AxisAlignedBB;
|
|
42
|
+
/**
|
|
43
|
+
* 拡大
|
|
44
|
+
* @param dx
|
|
45
|
+
* @param dy
|
|
46
|
+
* @param dz
|
|
47
|
+
* @returns {AxisAlignedBB}
|
|
48
|
+
*/
|
|
49
|
+
expand(dx: number, dy: number, dz: number): AxisAlignedBB;
|
|
50
|
+
/**
|
|
51
|
+
* 縮小
|
|
52
|
+
* @param dx
|
|
53
|
+
* @param dy
|
|
54
|
+
* @param dz
|
|
55
|
+
* @returns {AxisAlignedBB}
|
|
56
|
+
*/
|
|
57
|
+
contract(dx: number, dy: number, dz: number): AxisAlignedBB;
|
|
58
|
+
/**
|
|
59
|
+
* 接触判定
|
|
60
|
+
* @param other
|
|
61
|
+
* @param epsilon
|
|
62
|
+
* @returns {boolean}
|
|
63
|
+
*/
|
|
64
|
+
intersects(other: AxisAlignedBB, epsilon?: number): boolean;
|
|
65
|
+
/**
|
|
66
|
+
* 対象座標が内包されているか
|
|
67
|
+
* @param v
|
|
68
|
+
* @returns {boolean}
|
|
69
|
+
*/
|
|
70
|
+
contains(v: Vector3): boolean;
|
|
71
|
+
/**
|
|
72
|
+
* Xの長さ
|
|
73
|
+
* @returns {number}
|
|
74
|
+
*/
|
|
75
|
+
getXLength(): number;
|
|
76
|
+
/**
|
|
77
|
+
* Yの長さ
|
|
78
|
+
* @returns {number}
|
|
79
|
+
*/
|
|
80
|
+
getYLength(): number;
|
|
81
|
+
/**
|
|
82
|
+
* Zの長さ
|
|
83
|
+
* @returns {number}
|
|
84
|
+
*/
|
|
85
|
+
getZLength(): number;
|
|
86
|
+
/**
|
|
87
|
+
* 体積
|
|
88
|
+
* @returns {number}
|
|
89
|
+
*/
|
|
90
|
+
getVolume(): number;
|
|
91
|
+
/**
|
|
92
|
+
* キューブ判定
|
|
93
|
+
* @param epsilon
|
|
94
|
+
* @returns {boolean}
|
|
95
|
+
*/
|
|
96
|
+
isCube(epsilon?: number): boolean;
|
|
97
|
+
/**
|
|
98
|
+
* BDS ScriptAPIで使える {center, extent} 形式に変換
|
|
99
|
+
* @returns {AABB}
|
|
100
|
+
*/
|
|
101
|
+
toBDS(): AABB;
|
|
102
|
+
/**
|
|
103
|
+
* オブジェクトに変換
|
|
104
|
+
*/
|
|
105
|
+
toObject(): {
|
|
106
|
+
center: Vector3;
|
|
107
|
+
extent: Vector3;
|
|
108
|
+
};
|
|
109
|
+
/**
|
|
110
|
+
* toString
|
|
111
|
+
* @returns {string}
|
|
112
|
+
*/
|
|
113
|
+
toString(): string;
|
|
114
|
+
}
|
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
import { Vector3 as _Vector3 } from '@minecraft/server';
|
|
2
|
+
export declare class Vector3 {
|
|
3
|
+
x: number;
|
|
4
|
+
y: number;
|
|
5
|
+
z: number;
|
|
6
|
+
constructor(x: number, y: number, z: number);
|
|
7
|
+
/**
|
|
8
|
+
* ゼロベクトルで生成
|
|
9
|
+
* @return {Vector3}
|
|
10
|
+
*/
|
|
11
|
+
static zero(): Vector3;
|
|
12
|
+
/**
|
|
13
|
+
* {x, y, z} オブジェクトから生成
|
|
14
|
+
* @param pos
|
|
15
|
+
* @returns {Vector3}
|
|
16
|
+
*/
|
|
17
|
+
static fromBDS(pos: _Vector3): Vector3;
|
|
18
|
+
/**
|
|
19
|
+
* x
|
|
20
|
+
* @returns {number}
|
|
21
|
+
*/
|
|
22
|
+
getX(): number;
|
|
23
|
+
/**
|
|
24
|
+
* y
|
|
25
|
+
* @returns {number}
|
|
26
|
+
*/
|
|
27
|
+
getY(): number;
|
|
28
|
+
/**
|
|
29
|
+
* z
|
|
30
|
+
* @returns {number}
|
|
31
|
+
*/
|
|
32
|
+
getZ(): number;
|
|
33
|
+
/**
|
|
34
|
+
* x (整数値)
|
|
35
|
+
* @returns {number}
|
|
36
|
+
*/
|
|
37
|
+
getFloorX(): number;
|
|
38
|
+
/**
|
|
39
|
+
* y (整数値)
|
|
40
|
+
* @returns {number}
|
|
41
|
+
*/
|
|
42
|
+
getFloorY(): number;
|
|
43
|
+
/**
|
|
44
|
+
* z (整数値)
|
|
45
|
+
* @returns {number}
|
|
46
|
+
*/
|
|
47
|
+
getFloorZ(): number;
|
|
48
|
+
/**
|
|
49
|
+
* 加算
|
|
50
|
+
* @param x
|
|
51
|
+
* @param y
|
|
52
|
+
* @param z
|
|
53
|
+
* @return {Vector3}
|
|
54
|
+
*/
|
|
55
|
+
add(x: number, y: number, z: number): Vector3;
|
|
56
|
+
/**
|
|
57
|
+
* ベクトル単位での加算
|
|
58
|
+
* @param v
|
|
59
|
+
* @returns {Vector3}
|
|
60
|
+
*/
|
|
61
|
+
addVector(v: _Vector3): Vector3;
|
|
62
|
+
/**
|
|
63
|
+
* 減算
|
|
64
|
+
* @param x
|
|
65
|
+
* @param y
|
|
66
|
+
* @param z
|
|
67
|
+
* @return {Vector3}
|
|
68
|
+
*/
|
|
69
|
+
subtract(x: number, y: number, z: number): Vector3;
|
|
70
|
+
/**
|
|
71
|
+
* ベクトル単位での減算
|
|
72
|
+
* @param v
|
|
73
|
+
* @return {Vector3}
|
|
74
|
+
*/
|
|
75
|
+
subtractVector(v: _Vector3): Vector3;
|
|
76
|
+
/**
|
|
77
|
+
* 乗算
|
|
78
|
+
* @param value
|
|
79
|
+
* @return {Vector3}
|
|
80
|
+
*/
|
|
81
|
+
multiply(value: number): Vector3;
|
|
82
|
+
/**
|
|
83
|
+
* 除算
|
|
84
|
+
* @param value
|
|
85
|
+
* @return {Vector3}
|
|
86
|
+
*/
|
|
87
|
+
divide(value: number): Vector3;
|
|
88
|
+
/**
|
|
89
|
+
* ベクトルの内部数値小数点切り上げ
|
|
90
|
+
* @return {Vector3}
|
|
91
|
+
*/
|
|
92
|
+
ceil(): Vector3;
|
|
93
|
+
/**
|
|
94
|
+
* ベクトルの内部数値小数点切り捨て
|
|
95
|
+
* @return {Vector3}
|
|
96
|
+
*/
|
|
97
|
+
floor(): Vector3;
|
|
98
|
+
/**
|
|
99
|
+
* ベクトルの内部数値小数点四捨五入
|
|
100
|
+
* @param precision
|
|
101
|
+
* @return {Vector3}
|
|
102
|
+
*/
|
|
103
|
+
round(precision?: number): Vector3;
|
|
104
|
+
/**
|
|
105
|
+
* ベクトルの内部数値の絶対値
|
|
106
|
+
* @return {Vector3}
|
|
107
|
+
*/
|
|
108
|
+
abs(): Vector3;
|
|
109
|
+
/**
|
|
110
|
+
* 指定した2点間のユークリッド距離
|
|
111
|
+
* @param pos
|
|
112
|
+
* @return {number}
|
|
113
|
+
*/
|
|
114
|
+
distance(pos: _Vector3): number;
|
|
115
|
+
/**
|
|
116
|
+
* 指定した2点間のユークリッド距離の2乗
|
|
117
|
+
* @param pos
|
|
118
|
+
* @return {number}
|
|
119
|
+
*/
|
|
120
|
+
distanceSquared(pos: _Vector3): number;
|
|
121
|
+
/**
|
|
122
|
+
* 内積
|
|
123
|
+
* @param pos
|
|
124
|
+
* @return {number}
|
|
125
|
+
*/
|
|
126
|
+
dot(pos: _Vector3): number;
|
|
127
|
+
/**
|
|
128
|
+
* 外積
|
|
129
|
+
* @param pos
|
|
130
|
+
* @return {Vector3}
|
|
131
|
+
*/
|
|
132
|
+
cross(pos: _Vector3): Vector3;
|
|
133
|
+
/**
|
|
134
|
+
* ベクトルの比較
|
|
135
|
+
* @param pos
|
|
136
|
+
* @return {boolean}
|
|
137
|
+
*/
|
|
138
|
+
equals(pos: _Vector3): boolean;
|
|
139
|
+
/**
|
|
140
|
+
* ベクトルの長さ
|
|
141
|
+
* @return {number}
|
|
142
|
+
*/
|
|
143
|
+
length(): number;
|
|
144
|
+
/**
|
|
145
|
+
* ベクトルの長さの2乗
|
|
146
|
+
* @return {number}
|
|
147
|
+
*/
|
|
148
|
+
lengthSquared(): number;
|
|
149
|
+
/**
|
|
150
|
+
* 正規化
|
|
151
|
+
* @return {Vector3}
|
|
152
|
+
*/
|
|
153
|
+
normalize(): Vector3;
|
|
154
|
+
/**
|
|
155
|
+
* オブジェクトの数値指定再生成
|
|
156
|
+
* @param x
|
|
157
|
+
* @param y
|
|
158
|
+
* @param z
|
|
159
|
+
* @return {Vector3}
|
|
160
|
+
*/
|
|
161
|
+
withComponents(x?: number, y?: number, z?: number): Vector3;
|
|
162
|
+
/**
|
|
163
|
+
* X座標をxValueにしたとき線分上に存在する点を返す
|
|
164
|
+
* @param end 終点
|
|
165
|
+
* @param xValue 途中点のX値
|
|
166
|
+
* @returns {Vector3|undefined}
|
|
167
|
+
*/
|
|
168
|
+
getIntermediateWithXValue(end: Vector3, xValue: number): Vector3 | undefined;
|
|
169
|
+
/**
|
|
170
|
+
* Y座標をyValueにしたとき線分上に存在する点を返す
|
|
171
|
+
* @param end 終点
|
|
172
|
+
* @param yValue 途中点のY値
|
|
173
|
+
* @returns {Vector3|undefined}
|
|
174
|
+
*/
|
|
175
|
+
getIntermediateWithYValue(end: Vector3, yValue: number): Vector3 | undefined;
|
|
176
|
+
/**
|
|
177
|
+
* Z座標をzValueにしたとき線分上に存在する点を返す
|
|
178
|
+
* @param end 終点
|
|
179
|
+
* @param zValue 途中点のZ値
|
|
180
|
+
* @returns {Vector3|undefined}
|
|
181
|
+
*/
|
|
182
|
+
getIntermediateWithZValue(end: Vector3, zValue: number): Vector3 | undefined;
|
|
183
|
+
/**
|
|
184
|
+
* BDS ScriptAPIで使える {x, y, z} 形式に変換
|
|
185
|
+
* @returns {_Vector3}
|
|
186
|
+
*/
|
|
187
|
+
toBDS(): _Vector3;
|
|
188
|
+
/**
|
|
189
|
+
* オブジェクトに変換
|
|
190
|
+
*/
|
|
191
|
+
toObject(): {
|
|
192
|
+
x: number;
|
|
193
|
+
y: number;
|
|
194
|
+
z: number;
|
|
195
|
+
};
|
|
196
|
+
/**
|
|
197
|
+
* toString
|
|
198
|
+
* @returns {string}
|
|
199
|
+
*/
|
|
200
|
+
toString(): string;
|
|
201
|
+
/**
|
|
202
|
+
* 最大点
|
|
203
|
+
* @param vector
|
|
204
|
+
* @param vectors
|
|
205
|
+
* @returns {Vector3}
|
|
206
|
+
*/
|
|
207
|
+
static maxComponents(vector: _Vector3, ...vectors: _Vector3[]): Vector3;
|
|
208
|
+
/**
|
|
209
|
+
* 最小点
|
|
210
|
+
* @param vector
|
|
211
|
+
* @param vectors
|
|
212
|
+
* @returns {Vector3}
|
|
213
|
+
*/
|
|
214
|
+
static minComponents(vector: _Vector3, ...vectors: _Vector3[]): Vector3;
|
|
215
|
+
/**
|
|
216
|
+
* 合計
|
|
217
|
+
* @param vectors
|
|
218
|
+
* @returns {Vector3}
|
|
219
|
+
*/
|
|
220
|
+
static sum(...vectors: {
|
|
221
|
+
x: number;
|
|
222
|
+
y: number;
|
|
223
|
+
z: number;
|
|
224
|
+
}[]): Vector3;
|
|
225
|
+
}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ============================================================
|
|
3
|
+
* マスター Interval(負荷分散スケジューラ)
|
|
4
|
+
* ============================================================
|
|
5
|
+
*/
|
|
6
|
+
export declare class TimerScheduler {
|
|
7
|
+
private static tasks;
|
|
8
|
+
private static tick;
|
|
9
|
+
private static started;
|
|
10
|
+
/** スケジューラにタスクを登録 */
|
|
11
|
+
static addTask(task: () => void): void;
|
|
12
|
+
/** タスクを削除 */
|
|
13
|
+
static removeTask(task: () => void): void;
|
|
14
|
+
/** Interval を開始(1 本だけ) */
|
|
15
|
+
private static ensureStarted;
|
|
16
|
+
}
|
|
17
|
+
/** 内部キャンセル結果 */
|
|
18
|
+
declare enum CancelResult {
|
|
19
|
+
SUCCESS = 0,
|
|
20
|
+
FORCE = 1,
|
|
21
|
+
FAILURE = 2
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* ============================================================
|
|
25
|
+
* Base Timer
|
|
26
|
+
* ============================================================
|
|
27
|
+
* スケジューラに登録され、tick ごとに管理される抽象クラス
|
|
28
|
+
*/
|
|
29
|
+
declare abstract class Timer {
|
|
30
|
+
protected currentTick: number;
|
|
31
|
+
protected onRun?: (currentTick: number) => void;
|
|
32
|
+
protected onCancel?: () => void;
|
|
33
|
+
protected stopped: boolean;
|
|
34
|
+
protected canceled: boolean;
|
|
35
|
+
protected forceCanceled: boolean;
|
|
36
|
+
/** スケジューラに登録されたタスク */
|
|
37
|
+
protected task?: () => void;
|
|
38
|
+
constructor(onRun?: (currentTick: number) => void, onCancel?: () => void);
|
|
39
|
+
/** 開始(各派生クラスで実装) */
|
|
40
|
+
abstract start(): void;
|
|
41
|
+
/** 一時停止 */
|
|
42
|
+
stop(): void;
|
|
43
|
+
/** 再開 */
|
|
44
|
+
resume(): void;
|
|
45
|
+
/** 停止しているか */
|
|
46
|
+
isStopped(): boolean;
|
|
47
|
+
/** キャンセル要求 */
|
|
48
|
+
cancel(force?: boolean): void;
|
|
49
|
+
/** タイマー内部キャンセル */
|
|
50
|
+
protected internalCancel(force?: boolean): CancelResult;
|
|
51
|
+
}
|
|
52
|
+
export interface RepeatingOptions {
|
|
53
|
+
period?: number;
|
|
54
|
+
endless?: boolean;
|
|
55
|
+
silenceOnStop?: boolean;
|
|
56
|
+
maxElapsedTicks?: number;
|
|
57
|
+
onFinal?: () => void;
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* 一定間隔で実行される繰り返しタイマー
|
|
61
|
+
*/
|
|
62
|
+
export declare class RepeatingTimer extends Timer {
|
|
63
|
+
private period;
|
|
64
|
+
private endless;
|
|
65
|
+
private silenceOnStop;
|
|
66
|
+
private maxElapsedTicks?;
|
|
67
|
+
private onFinal?;
|
|
68
|
+
constructor(onRun?: (currentTick: number) => void, opts?: RepeatingOptions, onCancel?: () => void);
|
|
69
|
+
/** タイマー開始 */
|
|
70
|
+
start(): void;
|
|
71
|
+
}
|
|
72
|
+
export interface DelayedOptions {
|
|
73
|
+
delay?: number;
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* 指定 tick 後に一度だけ実行されるタイマー
|
|
77
|
+
*/
|
|
78
|
+
export declare class DelayedTimer extends Timer {
|
|
79
|
+
private delay;
|
|
80
|
+
constructor(onRun?: (currentTick: number) => void, opts?: DelayedOptions, onCancel?: () => void);
|
|
81
|
+
start(): void;
|
|
82
|
+
}
|
|
83
|
+
export declare function repeating(opts: {
|
|
84
|
+
every?: number;
|
|
85
|
+
endless?: boolean;
|
|
86
|
+
max?: number;
|
|
87
|
+
silenceWhenStopped?: boolean;
|
|
88
|
+
run?: (tick: number) => void;
|
|
89
|
+
cancel?: () => void;
|
|
90
|
+
final?: () => void;
|
|
91
|
+
}): RepeatingTimer;
|
|
92
|
+
export declare function delayed(ticks: number, run: () => void, cancel?: () => void): DelayedTimer;
|
|
93
|
+
export declare function sleep(tick: number): Promise<void>;
|
|
94
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function debug(...args: any[]): void;
|