sonolus-bandori-engine 0.6.5
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/LICENSE.txt +21 -0
- package/README.md +73 -0
- package/dist/EngineConfiguration +0 -0
- package/dist/EngineData +0 -0
- package/dist/Resource.d.ts +9 -0
- package/dist/Resource.js +24 -0
- package/dist/archetypes.json +1 -0
- package/dist/convert.d.ts +52 -0
- package/dist/convert.js +269 -0
- package/dist/index.d.ts +32 -0
- package/dist/index.js +47 -0
- package/dist/thumbnail.png +0 -0
- package/package.json +34 -0
package/LICENSE.txt
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2021 NonSpicyBurrito
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# Sonolus Bandori Engine
|
|
2
|
+
|
|
3
|
+
A recreation of BanG Dream! Girls Band Party engine in [Sonolus](https://sonolus.com).
|
|
4
|
+
|
|
5
|
+
## Links
|
|
6
|
+
|
|
7
|
+
- [Sonolus Website](https://sonolus.com)
|
|
8
|
+
- [Sonolus Wiki](https://github.com/NonSpicyBurrito/sonolus-wiki)
|
|
9
|
+
|
|
10
|
+
## Installation
|
|
11
|
+
|
|
12
|
+
```
|
|
13
|
+
npm install sonolus-bandori-engine --save
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Custom Resources
|
|
17
|
+
|
|
18
|
+
Engine ID: `1`
|
|
19
|
+
|
|
20
|
+
### Skin Sprites
|
|
21
|
+
|
|
22
|
+
| ID | Sprite | Bandori Asset Path |
|
|
23
|
+
| --- | ------------- | ------------------------------------------------- |
|
|
24
|
+
| 1 | Stage | `/ingameskin/fieldskin/{name}/bg_line_rhythm.png` |
|
|
25
|
+
| 2 | Judgment Line | `/ingameskin/fieldskin/{name}/game_play_line.png` |
|
|
26
|
+
|
|
27
|
+
### Effect Clips
|
|
28
|
+
|
|
29
|
+
| ID | Sprite | Bandori Asset Path |
|
|
30
|
+
| --- | ------------------------ | ---------------------------------------------- |
|
|
31
|
+
| 1 | Directional Flick Single | `/sound/tapseskin/{name}/directional_fl.mp3` |
|
|
32
|
+
| 2 | Directional Flick Double | `/sound/tapseskin/{name}/directional_fl_2.mp3` |
|
|
33
|
+
| 3 | Directional Flick Triple | `/sound/tapseskin/{name}/directional_fl_3.mp3` |
|
|
34
|
+
|
|
35
|
+
## Documentation
|
|
36
|
+
|
|
37
|
+
### `version`
|
|
38
|
+
|
|
39
|
+
Package version.
|
|
40
|
+
|
|
41
|
+
### `engineInfo`
|
|
42
|
+
|
|
43
|
+
Partial engine information compatible with [sonolus-express](https://github.com/NonSpicyBurrito/sonolus-express).
|
|
44
|
+
|
|
45
|
+
### `engineConfiguration`
|
|
46
|
+
|
|
47
|
+
Engine Configuration.
|
|
48
|
+
|
|
49
|
+
- `engineConfiguration.path`: path to file.
|
|
50
|
+
- `engineConfiguration.buffer`: buffer of file.
|
|
51
|
+
- `engineConfiguration.hash`: hash of file.
|
|
52
|
+
|
|
53
|
+
### `engineData`
|
|
54
|
+
|
|
55
|
+
Engine Data.
|
|
56
|
+
|
|
57
|
+
- `engineData.path`: path to file.
|
|
58
|
+
- `engineData.buffer`: buffer of file.
|
|
59
|
+
- `engineData.hash`: hash of file.
|
|
60
|
+
|
|
61
|
+
### `engineThumbnail`
|
|
62
|
+
|
|
63
|
+
Engine Thumbnail.
|
|
64
|
+
|
|
65
|
+
- `engineThumbnail.path`: path to file.
|
|
66
|
+
- `engineThumbnail.buffer`: buffer of file.
|
|
67
|
+
- `engineThumbnail.hash`: hash of file.
|
|
68
|
+
|
|
69
|
+
### `fromBestdori(chart)`
|
|
70
|
+
|
|
71
|
+
Converts Bestdori chart to Level Data.
|
|
72
|
+
|
|
73
|
+
- `chart`: Bestdori chart.
|
|
Binary file
|
package/dist/EngineData
ADDED
|
Binary file
|
package/dist/Resource.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Resource = void 0;
|
|
4
|
+
const crypto_1 = require("crypto");
|
|
5
|
+
const fs_1 = require("fs");
|
|
6
|
+
const path_1 = require("path");
|
|
7
|
+
class Resource {
|
|
8
|
+
constructor(path) {
|
|
9
|
+
this.path = path_1.resolve(__dirname, path);
|
|
10
|
+
}
|
|
11
|
+
get hash() {
|
|
12
|
+
if (!this._hash) {
|
|
13
|
+
this._hash = crypto_1.createHash('sha1').update(this.buffer).digest('hex');
|
|
14
|
+
}
|
|
15
|
+
return this._hash;
|
|
16
|
+
}
|
|
17
|
+
get buffer() {
|
|
18
|
+
if (!this._buffer) {
|
|
19
|
+
this._buffer = fs_1.readFileSync(this.path);
|
|
20
|
+
}
|
|
21
|
+
return this._buffer;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
exports.Resource = Resource;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"initializationIndex":0,"stageIndex":1,"tapNoteIndex":2,"flickNoteIndex":3,"directionalFlickNoteIndex":4,"slideStartNoteIndex":5,"slideTickNoteIndex":6,"slideEndNoteIndex":7,"slideFlickNoteIndex":8,"straightSliderIndex":9,"curvedSliderIndex":10}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { SLevelData } from 'sonolus.js';
|
|
2
|
+
export declare type ChartObject = SingleObject | DirectionalObject | SlideObject | LongObject | BPMObject | SystemObject;
|
|
3
|
+
declare type ObjectBase = {
|
|
4
|
+
beat: number;
|
|
5
|
+
};
|
|
6
|
+
declare type NoteBase = ObjectBase & {
|
|
7
|
+
lane: number;
|
|
8
|
+
flick?: true;
|
|
9
|
+
skill?: true;
|
|
10
|
+
charge?: true;
|
|
11
|
+
};
|
|
12
|
+
declare type SingleObject = NoteBase & {
|
|
13
|
+
type: 'Single';
|
|
14
|
+
};
|
|
15
|
+
declare type DirectionalObject = NoteBase & {
|
|
16
|
+
type: 'Directional';
|
|
17
|
+
direction: 'Left' | 'Right';
|
|
18
|
+
width: number;
|
|
19
|
+
};
|
|
20
|
+
declare type SlideObject = {
|
|
21
|
+
type: 'Slide';
|
|
22
|
+
connections: Connection[];
|
|
23
|
+
};
|
|
24
|
+
declare type LongObject = {
|
|
25
|
+
type: 'Long';
|
|
26
|
+
connections: Connection[];
|
|
27
|
+
};
|
|
28
|
+
declare type Connection = NoteBase & {
|
|
29
|
+
hidden?: true;
|
|
30
|
+
};
|
|
31
|
+
declare type BPMObject = ObjectBase & {
|
|
32
|
+
type: 'BPM';
|
|
33
|
+
bpm: number;
|
|
34
|
+
};
|
|
35
|
+
declare type SystemObject = ObjectBase & {
|
|
36
|
+
type: 'System';
|
|
37
|
+
data: string;
|
|
38
|
+
};
|
|
39
|
+
export declare function fromBestdori(chart: ChartObject[], archetypes: {
|
|
40
|
+
initializationIndex: number;
|
|
41
|
+
stageIndex: number;
|
|
42
|
+
tapNoteIndex: number;
|
|
43
|
+
flickNoteIndex: number;
|
|
44
|
+
directionalFlickNoteIndex: number;
|
|
45
|
+
slideStartNoteIndex: number;
|
|
46
|
+
slideTickNoteIndex: number;
|
|
47
|
+
slideEndNoteIndex: number;
|
|
48
|
+
slideFlickNoteIndex: number;
|
|
49
|
+
straightSliderIndex: number;
|
|
50
|
+
curvedSliderIndex: number;
|
|
51
|
+
}): SLevelData;
|
|
52
|
+
export {};
|
package/dist/convert.js
ADDED
|
@@ -0,0 +1,269 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.fromBestdori = void 0;
|
|
4
|
+
function fromBestdori(chart, archetypes) {
|
|
5
|
+
const chartObjects = repair(chart);
|
|
6
|
+
const timings = [];
|
|
7
|
+
let timePerBeat = 0;
|
|
8
|
+
let beats = 0;
|
|
9
|
+
let time = 0;
|
|
10
|
+
chartObjects
|
|
11
|
+
.filter((chartObject) => chartObject.type === 'BPM')
|
|
12
|
+
.sort((a, b) => a.beat - b.beat)
|
|
13
|
+
.forEach((bpmObject) => {
|
|
14
|
+
time += (bpmObject.beat - beats) * timePerBeat;
|
|
15
|
+
beats = bpmObject.beat;
|
|
16
|
+
timePerBeat = 60 / bpmObject.bpm;
|
|
17
|
+
timings.unshift({
|
|
18
|
+
beat: beats,
|
|
19
|
+
time,
|
|
20
|
+
timePerBeat,
|
|
21
|
+
});
|
|
22
|
+
});
|
|
23
|
+
const wrappedNoteEntities = [
|
|
24
|
+
{
|
|
25
|
+
entity: {
|
|
26
|
+
archetype: archetypes.initializationIndex,
|
|
27
|
+
},
|
|
28
|
+
time: Number.NEGATIVE_INFINITY,
|
|
29
|
+
lane: 0,
|
|
30
|
+
},
|
|
31
|
+
{
|
|
32
|
+
entity: {
|
|
33
|
+
archetype: archetypes.stageIndex,
|
|
34
|
+
},
|
|
35
|
+
time: Number.NEGATIVE_INFINITY,
|
|
36
|
+
lane: 0,
|
|
37
|
+
},
|
|
38
|
+
];
|
|
39
|
+
const wrappedSliderEntities = [];
|
|
40
|
+
chartObjects.forEach((chartObject) => {
|
|
41
|
+
switch (chartObject.type) {
|
|
42
|
+
case 'Single': {
|
|
43
|
+
const time = beatToTime(chartObject.beat);
|
|
44
|
+
const lane = chartObject.lane - 3;
|
|
45
|
+
wrappedNoteEntities.push({
|
|
46
|
+
entity: {
|
|
47
|
+
archetype: chartObject.flick
|
|
48
|
+
? archetypes.flickNoteIndex
|
|
49
|
+
: archetypes.tapNoteIndex,
|
|
50
|
+
data: {
|
|
51
|
+
index: 1,
|
|
52
|
+
values: [time, lane],
|
|
53
|
+
},
|
|
54
|
+
},
|
|
55
|
+
time,
|
|
56
|
+
lane,
|
|
57
|
+
});
|
|
58
|
+
break;
|
|
59
|
+
}
|
|
60
|
+
case 'Directional': {
|
|
61
|
+
const time = beatToTime(chartObject.beat);
|
|
62
|
+
const lane = chartObject.lane - 3;
|
|
63
|
+
wrappedNoteEntities.push({
|
|
64
|
+
entity: {
|
|
65
|
+
archetype: archetypes.directionalFlickNoteIndex,
|
|
66
|
+
data: {
|
|
67
|
+
index: 1,
|
|
68
|
+
values: [
|
|
69
|
+
time,
|
|
70
|
+
lane,
|
|
71
|
+
chartObject.width - 1,
|
|
72
|
+
chartObject.direction === 'Left' ? 1 : 0,
|
|
73
|
+
],
|
|
74
|
+
},
|
|
75
|
+
},
|
|
76
|
+
time,
|
|
77
|
+
lane,
|
|
78
|
+
});
|
|
79
|
+
break;
|
|
80
|
+
}
|
|
81
|
+
case 'Slide':
|
|
82
|
+
case 'Long': {
|
|
83
|
+
let segments = [];
|
|
84
|
+
const hasHidden = chartObject.connections.some((connection) => connection.hidden);
|
|
85
|
+
const canBeLong = chartObject.connections.length === 2 &&
|
|
86
|
+
chartObject.connections[0].lane ===
|
|
87
|
+
chartObject.connections[1].lane
|
|
88
|
+
? 1
|
|
89
|
+
: 0;
|
|
90
|
+
chartObject.connections.forEach((connection, index) => {
|
|
91
|
+
const time = beatToTime(connection.beat);
|
|
92
|
+
const lane = connection.lane - 3;
|
|
93
|
+
if (connection.hidden) {
|
|
94
|
+
segments.push({
|
|
95
|
+
time,
|
|
96
|
+
lane,
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
else {
|
|
100
|
+
if (index === 0) {
|
|
101
|
+
wrappedNoteEntities.push({
|
|
102
|
+
entity: {
|
|
103
|
+
archetype: archetypes.slideStartNoteIndex,
|
|
104
|
+
data: {
|
|
105
|
+
index: 1,
|
|
106
|
+
values: [time, lane],
|
|
107
|
+
},
|
|
108
|
+
},
|
|
109
|
+
time,
|
|
110
|
+
lane,
|
|
111
|
+
});
|
|
112
|
+
}
|
|
113
|
+
else {
|
|
114
|
+
const head = wrappedNoteEntities[wrappedNoteEntities.length - 1];
|
|
115
|
+
if (index === chartObject.connections.length - 1) {
|
|
116
|
+
wrappedNoteEntities.push({
|
|
117
|
+
entity: {
|
|
118
|
+
archetype: connection.flick
|
|
119
|
+
? archetypes.slideFlickNoteIndex
|
|
120
|
+
: archetypes.slideEndNoteIndex,
|
|
121
|
+
data: {
|
|
122
|
+
index: 0,
|
|
123
|
+
values: [
|
|
124
|
+
0,
|
|
125
|
+
time,
|
|
126
|
+
lane,
|
|
127
|
+
0,
|
|
128
|
+
0,
|
|
129
|
+
canBeLong,
|
|
130
|
+
],
|
|
131
|
+
},
|
|
132
|
+
},
|
|
133
|
+
time,
|
|
134
|
+
lane,
|
|
135
|
+
head,
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
else {
|
|
139
|
+
wrappedNoteEntities.push({
|
|
140
|
+
entity: {
|
|
141
|
+
archetype: archetypes.slideTickNoteIndex,
|
|
142
|
+
data: {
|
|
143
|
+
index: 0,
|
|
144
|
+
values: [0, time, lane],
|
|
145
|
+
},
|
|
146
|
+
},
|
|
147
|
+
time,
|
|
148
|
+
lane,
|
|
149
|
+
head,
|
|
150
|
+
});
|
|
151
|
+
}
|
|
152
|
+
segments.push({
|
|
153
|
+
time,
|
|
154
|
+
lane,
|
|
155
|
+
});
|
|
156
|
+
const tail = wrappedNoteEntities[wrappedNoteEntities.length - 1];
|
|
157
|
+
let prevSegment = {
|
|
158
|
+
time: head.time,
|
|
159
|
+
lane: head.lane,
|
|
160
|
+
};
|
|
161
|
+
segments.forEach((segment, index) => {
|
|
162
|
+
wrappedSliderEntities.push({
|
|
163
|
+
entity: {
|
|
164
|
+
archetype: hasHidden
|
|
165
|
+
? archetypes.curvedSliderIndex
|
|
166
|
+
: archetypes.straightSliderIndex,
|
|
167
|
+
data: {
|
|
168
|
+
index: 0,
|
|
169
|
+
values: [
|
|
170
|
+
0,
|
|
171
|
+
0,
|
|
172
|
+
prevSegment.time,
|
|
173
|
+
segment.time,
|
|
174
|
+
prevSegment.lane,
|
|
175
|
+
segment.lane,
|
|
176
|
+
index === 0 ? 1 : 0,
|
|
177
|
+
],
|
|
178
|
+
},
|
|
179
|
+
},
|
|
180
|
+
head,
|
|
181
|
+
tail,
|
|
182
|
+
});
|
|
183
|
+
prevSegment = segment;
|
|
184
|
+
});
|
|
185
|
+
segments = [];
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
});
|
|
189
|
+
break;
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
});
|
|
193
|
+
return {
|
|
194
|
+
entities: [
|
|
195
|
+
...wrappedNoteEntities
|
|
196
|
+
.sort((a, b) => a.time - b.time || Math.abs(b.lane) - Math.abs(a.lane))
|
|
197
|
+
.map((wrappedNoteEntity) => {
|
|
198
|
+
if (wrappedNoteEntity.head) {
|
|
199
|
+
if (!wrappedNoteEntity.entity.data)
|
|
200
|
+
throw 'Unexpected missing entity data';
|
|
201
|
+
wrappedNoteEntity.entity.data.values[0] =
|
|
202
|
+
wrappedNoteEntities.indexOf(wrappedNoteEntity.head);
|
|
203
|
+
}
|
|
204
|
+
return wrappedNoteEntity.entity;
|
|
205
|
+
}),
|
|
206
|
+
...wrappedSliderEntities.map((wrappedSliderEntity) => {
|
|
207
|
+
if (!wrappedSliderEntity.entity.data)
|
|
208
|
+
throw 'Unexpected missing entity data';
|
|
209
|
+
wrappedSliderEntity.entity.data.values[0] =
|
|
210
|
+
wrappedNoteEntities.indexOf(wrappedSliderEntity.head);
|
|
211
|
+
wrappedSliderEntity.entity.data.values[1] =
|
|
212
|
+
wrappedNoteEntities.indexOf(wrappedSliderEntity.tail);
|
|
213
|
+
return wrappedSliderEntity.entity;
|
|
214
|
+
}),
|
|
215
|
+
],
|
|
216
|
+
};
|
|
217
|
+
function beatToTime(beat) {
|
|
218
|
+
for (const timing of timings) {
|
|
219
|
+
if (beat >= timing.beat) {
|
|
220
|
+
return timing.time + (beat - timing.beat) * timing.timePerBeat;
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
return 0;
|
|
224
|
+
}
|
|
225
|
+
}
|
|
226
|
+
exports.fromBestdori = fromBestdori;
|
|
227
|
+
function repair(chartObjects) {
|
|
228
|
+
chartObjects.forEach((chartObject) => {
|
|
229
|
+
var _a, _b;
|
|
230
|
+
switch (chartObject.type) {
|
|
231
|
+
case 'Long':
|
|
232
|
+
case 'Slide': {
|
|
233
|
+
chartObject.connections.sort((a, b) => a.beat - b.beat);
|
|
234
|
+
const visibleConnections = chartObject.connections.filter((connection) => !connection.hidden);
|
|
235
|
+
switch (visibleConnections.length) {
|
|
236
|
+
case 0:
|
|
237
|
+
remove(chartObject);
|
|
238
|
+
break;
|
|
239
|
+
case 1: {
|
|
240
|
+
const connection = visibleConnections[0];
|
|
241
|
+
replace(chartObject, {
|
|
242
|
+
type: 'Single',
|
|
243
|
+
lane: connection.lane,
|
|
244
|
+
beat: connection.beat,
|
|
245
|
+
flick: connection.flick,
|
|
246
|
+
});
|
|
247
|
+
break;
|
|
248
|
+
}
|
|
249
|
+
default:
|
|
250
|
+
while ((_a = chartObject.connections[0]) === null || _a === void 0 ? void 0 : _a.hidden) {
|
|
251
|
+
chartObject.connections.shift();
|
|
252
|
+
}
|
|
253
|
+
while ((_b = chartObject.connections[chartObject.connections.length - 1]) === null || _b === void 0 ? void 0 : _b.hidden) {
|
|
254
|
+
chartObject.connections.pop();
|
|
255
|
+
}
|
|
256
|
+
break;
|
|
257
|
+
}
|
|
258
|
+
break;
|
|
259
|
+
}
|
|
260
|
+
}
|
|
261
|
+
});
|
|
262
|
+
return chartObjects;
|
|
263
|
+
function replace(o, n) {
|
|
264
|
+
chartObjects.splice(chartObjects.indexOf(o), 1, n);
|
|
265
|
+
}
|
|
266
|
+
function remove(o) {
|
|
267
|
+
chartObjects.splice(chartObjects.indexOf(o), 1);
|
|
268
|
+
}
|
|
269
|
+
}
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { SLevelData } from 'sonolus.js';
|
|
2
|
+
import { ChartObject } from './convert';
|
|
3
|
+
import { Resource } from './Resource';
|
|
4
|
+
export declare const version = "0.6.5";
|
|
5
|
+
export declare const engineInfo: {
|
|
6
|
+
readonly name: "bandori";
|
|
7
|
+
readonly version: 4;
|
|
8
|
+
readonly title: {
|
|
9
|
+
readonly en: "BanG Dream!";
|
|
10
|
+
readonly ja: "バンドリ!";
|
|
11
|
+
readonly ko: "뱅드림!";
|
|
12
|
+
readonly 'zh-hans': "BanG Dream!";
|
|
13
|
+
readonly 'zh-hant': "BanG Dream!";
|
|
14
|
+
};
|
|
15
|
+
readonly subtitle: {
|
|
16
|
+
readonly en: "BanG Dream! Girls Band Party!";
|
|
17
|
+
readonly ja: "バンドリ! ガールズバンドパーティ!";
|
|
18
|
+
readonly ko: "뱅드림! 걸즈 밴드 파티!";
|
|
19
|
+
readonly 'zh-hans': "BanG Dream! 少女乐团派对!";
|
|
20
|
+
readonly 'zh-hant': "BanG Dream! 少女樂團派對";
|
|
21
|
+
};
|
|
22
|
+
readonly author: {
|
|
23
|
+
readonly en: "Burrito";
|
|
24
|
+
};
|
|
25
|
+
readonly description: {
|
|
26
|
+
readonly en: string;
|
|
27
|
+
};
|
|
28
|
+
};
|
|
29
|
+
export declare const engineConfiguration: Resource;
|
|
30
|
+
export declare const engineData: Resource;
|
|
31
|
+
export declare const engineThumbnail: Resource;
|
|
32
|
+
export declare function fromBestdori(chart: ChartObject[]): SLevelData;
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.fromBestdori = exports.engineThumbnail = exports.engineData = exports.engineConfiguration = exports.engineInfo = exports.version = void 0;
|
|
4
|
+
const convert_1 = require("./convert");
|
|
5
|
+
const Resource_1 = require("./Resource");
|
|
6
|
+
// eslint-disable-next-line @typescript-eslint/no-var-requires
|
|
7
|
+
const archetypes = require('./archetypes');
|
|
8
|
+
exports.version = '0.6.5';
|
|
9
|
+
exports.engineInfo = {
|
|
10
|
+
name: 'bandori',
|
|
11
|
+
version: 4,
|
|
12
|
+
title: {
|
|
13
|
+
en: 'BanG Dream!',
|
|
14
|
+
ja: 'バンドリ!',
|
|
15
|
+
ko: '뱅드림!',
|
|
16
|
+
'zh-hans': 'BanG Dream!',
|
|
17
|
+
'zh-hant': 'BanG Dream!',
|
|
18
|
+
},
|
|
19
|
+
subtitle: {
|
|
20
|
+
en: 'BanG Dream! Girls Band Party!',
|
|
21
|
+
ja: 'バンドリ! ガールズバンドパーティ!',
|
|
22
|
+
ko: '뱅드림! 걸즈 밴드 파티!',
|
|
23
|
+
'zh-hans': 'BanG Dream! 少女乐团派对!',
|
|
24
|
+
'zh-hant': 'BanG Dream! 少女樂團派對',
|
|
25
|
+
},
|
|
26
|
+
author: {
|
|
27
|
+
en: 'Burrito',
|
|
28
|
+
},
|
|
29
|
+
description: {
|
|
30
|
+
en: [
|
|
31
|
+
'A recreation of BanG Dream! Girls Band Party engine in Sonolus.',
|
|
32
|
+
'',
|
|
33
|
+
'Version:',
|
|
34
|
+
exports.version,
|
|
35
|
+
'',
|
|
36
|
+
'GitHub Repository:',
|
|
37
|
+
'https://github.com/NonSpicyBurrito/sonolus-bandori-engine',
|
|
38
|
+
].join('\n'),
|
|
39
|
+
},
|
|
40
|
+
};
|
|
41
|
+
exports.engineConfiguration = new Resource_1.Resource('EngineConfiguration');
|
|
42
|
+
exports.engineData = new Resource_1.Resource('EngineData');
|
|
43
|
+
exports.engineThumbnail = new Resource_1.Resource('thumbnail.png');
|
|
44
|
+
function fromBestdori(chart) {
|
|
45
|
+
return convert_1.fromBestdori(chart, archetypes);
|
|
46
|
+
}
|
|
47
|
+
exports.fromBestdori = fromBestdori;
|
|
Binary file
|
package/package.json
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "sonolus-bandori-engine",
|
|
3
|
+
"version": "0.6.5",
|
|
4
|
+
"description": "A recreation of BanG Dream! Girls Band Party engine in Sonolus",
|
|
5
|
+
"author": "NonSpicyBurrito",
|
|
6
|
+
"repository": "github:NonSpicyBurrito/sonolus-bandori-engine",
|
|
7
|
+
"license": "MIT",
|
|
8
|
+
"keywords": [
|
|
9
|
+
"Sonolus"
|
|
10
|
+
],
|
|
11
|
+
"main": "dist",
|
|
12
|
+
"files": [
|
|
13
|
+
"dist"
|
|
14
|
+
],
|
|
15
|
+
"scripts": {
|
|
16
|
+
"lint": "eslint --ext .ts src/",
|
|
17
|
+
"serve": "nodemon",
|
|
18
|
+
"build": "ts-node ./src/build && tsc -p ./tsconfig.lib.json"
|
|
19
|
+
},
|
|
20
|
+
"devDependencies": {
|
|
21
|
+
"@types/fs-extra": "^9.0.12",
|
|
22
|
+
"@typescript-eslint/eslint-plugin": "^4.28.5",
|
|
23
|
+
"@typescript-eslint/parser": "^4.28.5",
|
|
24
|
+
"eslint": "^7.31.0",
|
|
25
|
+
"eslint-config-prettier": "^8.3.0",
|
|
26
|
+
"eslint-plugin-prettier": "^3.4.0",
|
|
27
|
+
"fs-extra": "^10.0.0",
|
|
28
|
+
"nodemon": "^2.0.12",
|
|
29
|
+
"prettier": "^2.3.2",
|
|
30
|
+
"sonolus.js": "^3.1.0",
|
|
31
|
+
"ts-node": "^10.1.0",
|
|
32
|
+
"typescript": "^4.3.5"
|
|
33
|
+
}
|
|
34
|
+
}
|