koishi-plugin-satori-ai 1.3.0 → 1.3.2
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/lib/abstractGame.d.ts +6 -1
- package/lib/game.d.ts +0 -1
- package/lib/gamefencing.d.ts +1 -0
- package/lib/gamegobang.d.ts +1 -0
- package/lib/gobang.cpp +605 -464
- package/lib/gobang_ai.exe +0 -0
- package/lib/index.js +100 -73
- package/package.json +1 -1
- package/lib/gobang-ai.exe +0 -0
package/lib/abstractGame.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ declare module 'koishi' {
|
|
|
5
5
|
}
|
|
6
6
|
}
|
|
7
7
|
export interface gameResult {
|
|
8
|
+
playerID: string;
|
|
8
9
|
message: string;
|
|
9
10
|
gameName: string;
|
|
10
11
|
}
|
|
@@ -14,12 +15,16 @@ export interface gameResult {
|
|
|
14
15
|
export declare abstract class abstractGameSingleGame {
|
|
15
16
|
protected session: Session;
|
|
16
17
|
protected disposeListener: () => boolean;
|
|
18
|
+
protected lastActionTime: number;
|
|
17
19
|
constructor(disposeListener: () => boolean, session: Session);
|
|
18
20
|
startGame(): Promise<string>;
|
|
19
21
|
endGame(): Promise<{
|
|
20
22
|
message: string;
|
|
21
23
|
gameName: string;
|
|
24
|
+
playerID: string;
|
|
22
25
|
}>;
|
|
26
|
+
getPlayerID(): string;
|
|
27
|
+
getLastActionTime(): number;
|
|
23
28
|
processInput(str: string): Promise<string>;
|
|
24
29
|
}
|
|
25
30
|
type Constructor<T> = new (...args: any[]) => T;
|
|
@@ -47,6 +52,6 @@ export declare abstract class abstractGame<T extends abstractGameSingleGame> {
|
|
|
47
52
|
/**
|
|
48
53
|
* 结束游戏实例,触发结果事件
|
|
49
54
|
*/
|
|
50
|
-
endGame(session: Session, ctx: Context): Promise<
|
|
55
|
+
endGame(session: Session, ctx: Context): Promise<boolean>;
|
|
51
56
|
}
|
|
52
57
|
export {};
|
package/lib/game.d.ts
CHANGED
package/lib/gamefencing.d.ts
CHANGED