@dicelette/core 1.7.0 → 1.8.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/index.d.mts +28 -19
- package/dist/index.d.ts +28 -19
- package/package.json +54 -55
package/dist/index.d.mts
CHANGED
@@ -78,31 +78,35 @@ interface Modifier {
|
|
78
78
|
sign?: Sign;
|
79
79
|
/**
|
80
80
|
* Value of the modifier
|
81
|
+
* @TJS-type integer
|
81
82
|
*/
|
82
83
|
value: number;
|
83
84
|
}
|
84
85
|
/**
|
85
86
|
* Statistic object template
|
86
87
|
*/
|
87
|
-
type Statistic =
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
88
|
+
type Statistic = Record<
|
89
|
+
/**
|
90
|
+
* The name of the statistic
|
91
|
+
* @TJS-type string
|
92
|
+
*/
|
93
|
+
string, {
|
94
|
+
/**
|
95
|
+
* The value of the statistic that can take the stats
|
96
|
+
* @TJS-type integer
|
97
|
+
*/
|
98
|
+
max?: number;
|
99
|
+
/**
|
100
|
+
* The minimal value of the statistic that can take the stats
|
101
|
+
* @TJS-type integer
|
102
|
+
*/
|
103
|
+
min?: number;
|
104
|
+
/**
|
105
|
+
* The combinaison that can be made with ANOTHER statistic
|
106
|
+
* Automatically disable the max/min value
|
107
|
+
*/
|
108
|
+
combinaison?: string;
|
109
|
+
}>;
|
106
110
|
/**
|
107
111
|
* @example
|
108
112
|
* diceType: 1d20+$>=20
|
@@ -174,6 +178,11 @@ interface CustomCritical {
|
|
174
178
|
* If "true", the comparison will be made on the natural dice result, without any modifier, including the statistics bonus if any.
|
175
179
|
*/
|
176
180
|
onNaturalDice?: boolean;
|
181
|
+
/**
|
182
|
+
* Allow to use the custom critical on dbD command (damage)
|
183
|
+
* @default false
|
184
|
+
*/
|
185
|
+
affectSkill?: boolean;
|
177
186
|
}
|
178
187
|
|
179
188
|
/**
|
package/dist/index.d.ts
CHANGED
@@ -78,31 +78,35 @@ interface Modifier {
|
|
78
78
|
sign?: Sign;
|
79
79
|
/**
|
80
80
|
* Value of the modifier
|
81
|
+
* @TJS-type integer
|
81
82
|
*/
|
82
83
|
value: number;
|
83
84
|
}
|
84
85
|
/**
|
85
86
|
* Statistic object template
|
86
87
|
*/
|
87
|
-
type Statistic =
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
88
|
+
type Statistic = Record<
|
89
|
+
/**
|
90
|
+
* The name of the statistic
|
91
|
+
* @TJS-type string
|
92
|
+
*/
|
93
|
+
string, {
|
94
|
+
/**
|
95
|
+
* The value of the statistic that can take the stats
|
96
|
+
* @TJS-type integer
|
97
|
+
*/
|
98
|
+
max?: number;
|
99
|
+
/**
|
100
|
+
* The minimal value of the statistic that can take the stats
|
101
|
+
* @TJS-type integer
|
102
|
+
*/
|
103
|
+
min?: number;
|
104
|
+
/**
|
105
|
+
* The combinaison that can be made with ANOTHER statistic
|
106
|
+
* Automatically disable the max/min value
|
107
|
+
*/
|
108
|
+
combinaison?: string;
|
109
|
+
}>;
|
106
110
|
/**
|
107
111
|
* @example
|
108
112
|
* diceType: 1d20+$>=20
|
@@ -174,6 +178,11 @@ interface CustomCritical {
|
|
174
178
|
* If "true", the comparison will be made on the natural dice result, without any modifier, including the statistics bonus if any.
|
175
179
|
*/
|
176
180
|
onNaturalDice?: boolean;
|
181
|
+
/**
|
182
|
+
* Allow to use the custom critical on dbD command (damage)
|
183
|
+
* @default false
|
184
|
+
*/
|
185
|
+
affectSkill?: boolean;
|
177
186
|
}
|
178
187
|
|
179
188
|
/**
|
package/package.json
CHANGED
@@ -1,56 +1,55 @@
|
|
1
1
|
{
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
}
|
2
|
+
"name": "@dicelette/core",
|
3
|
+
"version": "1.8.0",
|
4
|
+
"description": "Core library for the Dicelette Discord bot",
|
5
|
+
"repository": {
|
6
|
+
"type": "git",
|
7
|
+
"url": "git+https://github.com/Dicelette/core.git"
|
8
|
+
},
|
9
|
+
"type": "commonjs",
|
10
|
+
"main": "./dist/index.js",
|
11
|
+
"module": "./dist/index.mjs",
|
12
|
+
"types": "./dist/index.d.ts",
|
13
|
+
"files": [
|
14
|
+
"dist"
|
15
|
+
],
|
16
|
+
"scripts": {
|
17
|
+
"test": "vitest",
|
18
|
+
"build": "tsup",
|
19
|
+
"prerelease": "npm run build",
|
20
|
+
"lint": "biome format --write src",
|
21
|
+
"tsc": "tsc --noEmit --skipLibCheck",
|
22
|
+
"release": "commit-and-tag-version",
|
23
|
+
"postrelease": "git push --follow-tags origin main && pnpm publish"
|
24
|
+
},
|
25
|
+
"keywords": [
|
26
|
+
"discord",
|
27
|
+
"roll",
|
28
|
+
"library",
|
29
|
+
"bot",
|
30
|
+
"typescript"
|
31
|
+
],
|
32
|
+
"author": "Mara-Li",
|
33
|
+
"license": "GPL-3.0-only",
|
34
|
+
"dependencies": {
|
35
|
+
"@dice-roller/rpg-dice-roller": "^5.5.0",
|
36
|
+
"mathjs": "^14.0.0",
|
37
|
+
"moment": "^2.30.1",
|
38
|
+
"random-js": "^2.1.0",
|
39
|
+
"remove-accents": "^0.5.0",
|
40
|
+
"ts-dedent": "^2.2.0",
|
41
|
+
"uniformize": "^2.2.0",
|
42
|
+
"vite-tsconfig-paths": "^5.1.3",
|
43
|
+
"zod": "^3.23.8"
|
44
|
+
},
|
45
|
+
"devDependencies": {
|
46
|
+
"@biomejs/biome": "1.9.4",
|
47
|
+
"@types/bun": "^1.1.14",
|
48
|
+
"commit-and-tag-version": "^12.5.0",
|
49
|
+
"tslib": "^2.8.1",
|
50
|
+
"tsup": "^8.3.5",
|
51
|
+
"typescript": "^5.7.2",
|
52
|
+
"typescript-json-schema": "^0.65.1",
|
53
|
+
"zod-to-json-schema": "^3.23.5"
|
54
|
+
}
|
55
|
+
}
|