mons-web 0.1.98 → 0.1.101
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/README.md +12 -4
- package/mons-web.d.ts +34 -34
- package/mons-web.js +13 -13
- package/mons-web_bg.wasm +0 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -7,7 +7,9 @@ or
|
|
|
7
7
|
|
|
8
8
|
## rules-tests runner
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
Fixtures are stored as chunk archives in `rules-tests-chunks/` (default: `100000` fixtures per chunk).
|
|
11
|
+
|
|
12
|
+
Run all fixtures:
|
|
11
13
|
|
|
12
14
|
`./scripts/run-rules-tests.sh`
|
|
13
15
|
|
|
@@ -17,15 +19,21 @@ Useful options:
|
|
|
17
19
|
|
|
18
20
|
`./scripts/run-rules-tests.sh --log /tmp/rules-tests.log`
|
|
19
21
|
|
|
22
|
+
`./scripts/run-rules-tests.sh --chunks-dir ./rules-tests-chunks --verbose`
|
|
23
|
+
|
|
20
24
|
## rules-tests generator
|
|
21
25
|
|
|
22
|
-
Generate new random unique fixtures
|
|
26
|
+
Generate new random unique fixtures and repack chunks:
|
|
23
27
|
|
|
24
28
|
`./scripts/generate-rules-tests.sh --target-new 100`
|
|
25
29
|
|
|
26
|
-
|
|
30
|
+
Generate directly into a directory (continuous mode):
|
|
31
|
+
|
|
32
|
+
`./scripts/generate-rules-tests.sh --dir /tmp/rules-tests-work`
|
|
33
|
+
|
|
34
|
+
Pack a directory back into chunks:
|
|
27
35
|
|
|
28
|
-
`./scripts/
|
|
36
|
+
`./scripts/pack-rules-tests.sh --dir /tmp/rules-tests-work --chunks-dir ./rules-tests-chunks --chunk-size 100000`
|
|
29
37
|
|
|
30
38
|
## publishing to npm
|
|
31
39
|
|
package/mons-web.d.ts
CHANGED
|
@@ -40,13 +40,9 @@ export enum ManaKind {
|
|
|
40
40
|
}
|
|
41
41
|
/**
|
|
42
42
|
*/
|
|
43
|
-
export enum
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
SupermanaBase = 2,
|
|
47
|
-
ManaBase = 3,
|
|
48
|
-
ManaPool = 4,
|
|
49
|
-
MonBase = 5,
|
|
43
|
+
export enum Color {
|
|
44
|
+
White = 0,
|
|
45
|
+
Black = 1,
|
|
50
46
|
}
|
|
51
47
|
/**
|
|
52
48
|
*/
|
|
@@ -63,34 +59,39 @@ export enum NextInputKind {
|
|
|
63
59
|
}
|
|
64
60
|
/**
|
|
65
61
|
*/
|
|
66
|
-
export enum
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
62
|
+
export enum MonKind {
|
|
63
|
+
Demon = 0,
|
|
64
|
+
Drainer = 1,
|
|
65
|
+
Angel = 2,
|
|
66
|
+
Spirit = 3,
|
|
67
|
+
Mystic = 4,
|
|
72
68
|
}
|
|
73
69
|
/**
|
|
74
70
|
*/
|
|
75
|
-
export enum
|
|
76
|
-
|
|
77
|
-
|
|
71
|
+
export enum OutputModelKind {
|
|
72
|
+
InvalidInput = 0,
|
|
73
|
+
LocationsToStartFrom = 1,
|
|
74
|
+
NextInputOptions = 2,
|
|
75
|
+
Events = 3,
|
|
78
76
|
}
|
|
79
77
|
/**
|
|
80
78
|
*/
|
|
81
|
-
export enum
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
79
|
+
export enum SquareModelKind {
|
|
80
|
+
Regular = 0,
|
|
81
|
+
ConsumableBase = 1,
|
|
82
|
+
SupermanaBase = 2,
|
|
83
|
+
ManaBase = 3,
|
|
84
|
+
ManaPool = 4,
|
|
85
|
+
MonBase = 5,
|
|
86
86
|
}
|
|
87
87
|
/**
|
|
88
88
|
*/
|
|
89
|
-
export enum
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
89
|
+
export enum ItemModelKind {
|
|
90
|
+
Mon = 0,
|
|
91
|
+
Mana = 1,
|
|
92
|
+
MonWithMana = 2,
|
|
93
|
+
MonWithConsumable = 3,
|
|
94
|
+
Consumable = 4,
|
|
94
95
|
}
|
|
95
96
|
/**
|
|
96
97
|
*/
|
|
@@ -101,12 +102,11 @@ export enum Modifier {
|
|
|
101
102
|
}
|
|
102
103
|
/**
|
|
103
104
|
*/
|
|
104
|
-
export enum
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
Mystic = 4,
|
|
105
|
+
export enum AvailableMoveKind {
|
|
106
|
+
MonMove = 0,
|
|
107
|
+
ManaMove = 1,
|
|
108
|
+
Action = 2,
|
|
109
|
+
Potion = 3,
|
|
110
110
|
}
|
|
111
111
|
/**
|
|
112
112
|
*/
|
|
@@ -533,17 +533,17 @@ export interface InitOutput {
|
|
|
533
533
|
readonly mon_faint: (a: number) => void;
|
|
534
534
|
readonly mon_is_fainted: (a: number) => number;
|
|
535
535
|
readonly mon_new: (a: number, b: number, c: number) => number;
|
|
536
|
+
readonly winner: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number) => void;
|
|
536
537
|
readonly __wbg_get_location_i: (a: number) => number;
|
|
537
538
|
readonly __wbg_get_location_j: (a: number) => number;
|
|
538
539
|
readonly __wbg_location_free: (a: number) => void;
|
|
539
540
|
readonly __wbg_set_location_i: (a: number, b: number) => void;
|
|
540
541
|
readonly __wbg_set_location_j: (a: number, b: number) => void;
|
|
541
542
|
readonly location_new: (a: number, b: number) => number;
|
|
542
|
-
readonly winner: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number) => void;
|
|
543
543
|
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
|
544
544
|
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
|
545
545
|
readonly __wbindgen_export_2: WebAssembly.Table;
|
|
546
|
-
readonly
|
|
546
|
+
readonly _dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hb83fcf0132381e6f: (a: number, b: number) => void;
|
|
547
547
|
readonly __wbindgen_add_to_stack_pointer: (a: number) => number;
|
|
548
548
|
readonly __wbindgen_free: (a: number, b: number, c: number) => void;
|
|
549
549
|
readonly __wbindgen_exn_store: (a: number) => void;
|
package/mons-web.js
CHANGED
|
@@ -147,7 +147,7 @@ function makeMutClosure(arg0, arg1, dtor, f) {
|
|
|
147
147
|
return real;
|
|
148
148
|
}
|
|
149
149
|
function __wbg_adapter_26(arg0, arg1) {
|
|
150
|
-
wasm.
|
|
150
|
+
wasm._dyn_core__ops__function__FnMut_____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__hb83fcf0132381e6f(arg0, arg1);
|
|
151
151
|
}
|
|
152
152
|
|
|
153
153
|
let cachedUint32Memory0 = null;
|
|
@@ -242,28 +242,28 @@ export const EventModelKind = Object.freeze({ MonMove:0,"0":"MonMove",ManaMove:1
|
|
|
242
242
|
export const ManaKind = Object.freeze({ Regular:0,"0":"Regular",Supermana:1,"1":"Supermana", });
|
|
243
243
|
/**
|
|
244
244
|
*/
|
|
245
|
-
export const
|
|
245
|
+
export const Color = Object.freeze({ White:0,"0":"White",Black:1,"1":"Black", });
|
|
246
246
|
/**
|
|
247
247
|
*/
|
|
248
248
|
export const NextInputKind = Object.freeze({ MonMove:0,"0":"MonMove",ManaMove:1,"1":"ManaMove",MysticAction:2,"2":"MysticAction",DemonAction:3,"3":"DemonAction",DemonAdditionalStep:4,"4":"DemonAdditionalStep",SpiritTargetCapture:5,"5":"SpiritTargetCapture",SpiritTargetMove:6,"6":"SpiritTargetMove",SelectConsumable:7,"7":"SelectConsumable",BombAttack:8,"8":"BombAttack", });
|
|
249
249
|
/**
|
|
250
250
|
*/
|
|
251
|
-
export const
|
|
251
|
+
export const MonKind = Object.freeze({ Demon:0,"0":"Demon",Drainer:1,"1":"Drainer",Angel:2,"2":"Angel",Spirit:3,"3":"Spirit",Mystic:4,"4":"Mystic", });
|
|
252
252
|
/**
|
|
253
253
|
*/
|
|
254
|
-
export const
|
|
254
|
+
export const OutputModelKind = Object.freeze({ InvalidInput:0,"0":"InvalidInput",LocationsToStartFrom:1,"1":"LocationsToStartFrom",NextInputOptions:2,"2":"NextInputOptions",Events:3,"3":"Events", });
|
|
255
255
|
/**
|
|
256
256
|
*/
|
|
257
|
-
export const
|
|
257
|
+
export const SquareModelKind = Object.freeze({ Regular:0,"0":"Regular",ConsumableBase:1,"1":"ConsumableBase",SupermanaBase:2,"2":"SupermanaBase",ManaBase:3,"3":"ManaBase",ManaPool:4,"4":"ManaPool",MonBase:5,"5":"MonBase", });
|
|
258
258
|
/**
|
|
259
259
|
*/
|
|
260
|
-
export const
|
|
260
|
+
export const ItemModelKind = Object.freeze({ Mon:0,"0":"Mon",Mana:1,"1":"Mana",MonWithMana:2,"2":"MonWithMana",MonWithConsumable:3,"3":"MonWithConsumable",Consumable:4,"4":"Consumable", });
|
|
261
261
|
/**
|
|
262
262
|
*/
|
|
263
263
|
export const Modifier = Object.freeze({ SelectPotion:0,"0":"SelectPotion",SelectBomb:1,"1":"SelectBomb",Cancel:2,"2":"Cancel", });
|
|
264
264
|
/**
|
|
265
265
|
*/
|
|
266
|
-
export const
|
|
266
|
+
export const AvailableMoveKind = Object.freeze({ MonMove:0,"0":"MonMove",ManaMove:1,"1":"ManaMove",Action:2,"2":"Action",Potion:3,"3":"Potion", });
|
|
267
267
|
/**
|
|
268
268
|
*/
|
|
269
269
|
export const Consumable = Object.freeze({ Potion:0,"0":"Potion",Bomb:1,"1":"Bomb",BombOrPotion:2,"2":"BombOrPotion", });
|
|
@@ -1468,14 +1468,14 @@ function __wbg_get_imports() {
|
|
|
1468
1468
|
const ret = OutputModel.__wrap(arg0);
|
|
1469
1469
|
return addHeapObject(ret);
|
|
1470
1470
|
};
|
|
1471
|
-
imports.wbg.__wbg_location_new = function(arg0) {
|
|
1472
|
-
const ret = Location.__wrap(arg0);
|
|
1473
|
-
return addHeapObject(ret);
|
|
1474
|
-
};
|
|
1475
1471
|
imports.wbg.__wbg_nextinputmodel_new = function(arg0) {
|
|
1476
1472
|
const ret = NextInputModel.__wrap(arg0);
|
|
1477
1473
|
return addHeapObject(ret);
|
|
1478
1474
|
};
|
|
1475
|
+
imports.wbg.__wbg_location_new = function(arg0) {
|
|
1476
|
+
const ret = Location.__wrap(arg0);
|
|
1477
|
+
return addHeapObject(ret);
|
|
1478
|
+
};
|
|
1479
1479
|
imports.wbg.__wbg_eventmodel_new = function(arg0) {
|
|
1480
1480
|
const ret = EventModel.__wrap(arg0);
|
|
1481
1481
|
return addHeapObject(ret);
|
|
@@ -1631,8 +1631,8 @@ function __wbg_get_imports() {
|
|
|
1631
1631
|
imports.wbg.__wbindgen_throw = function(arg0, arg1) {
|
|
1632
1632
|
throw new Error(getStringFromWasm0(arg0, arg1));
|
|
1633
1633
|
};
|
|
1634
|
-
imports.wbg.
|
|
1635
|
-
const ret = makeMutClosure(arg0, arg1,
|
|
1634
|
+
imports.wbg.__wbindgen_closure_wrapper517 = function(arg0, arg1, arg2) {
|
|
1635
|
+
const ret = makeMutClosure(arg0, arg1, 21, __wbg_adapter_26);
|
|
1636
1636
|
return addHeapObject(ret);
|
|
1637
1637
|
};
|
|
1638
1638
|
|
package/mons-web_bg.wasm
CHANGED
|
Binary file
|