https://github.com/dtinth/bms.js
Be-Music Script reading and writing library for JavaScript
https://github.com/dtinth/bms.js
Last synced: 6 months ago
JSON representation
Be-Music Script reading and writing library for JavaScript
- Host: GitHub
- URL: https://github.com/dtinth/bms.js
- Owner: dtinth
- Created: 2012-08-04T16:58:56.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2012-08-04T17:06:04.000Z (over 13 years ago)
- Last Synced: 2025-04-09T06:11:54.394Z (9 months ago)
- Language: JavaScript
- Size: 85.9 KB
- Stars: 8
- Watchers: 4
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
bms.js
======
`BMS.parse(bms string)`
--
Parse BMS data and returns a JavaScript object.
`BMS.stringify(bms object)`
--
Generate BMS data from BMS object.
`BMS.isNote(event object)`
--
Checks if the event object is a note event. (11-29, 51,69)
BMS Object
--
{ "headers": { ... }
, "keysounds": { ... }
, "measureSizes": { "0": 0.5 }
, "events": [ bms events... ]
}
BMS Event Object
--
{ "measure": measure number (5 for #005)
, "position": position in measure (0 through 1)
, "channel": bms channel (see below)
, "value": "ZZ" (number for BPM events, string for others)
}
For BPM events, only use channel=8. BPM events gets normalized during parsing and when stringified will
be converted to hex-bpm or ref-bpm automatically.