Add JitPack's repository into your pom.xml
first:
<repositories>
<repository>
<id>jitpack.io</id>
<url>https://jitpack.io</url>
</repository>
</repositories>
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
Add this dependency to your <dependencies>
tag:
<dependency>
<groupId>com.github.HyDevelop</groupId>
<artifactId>OsuBeatmapParser</artifactId>
<version>1.1.2.109</version>
</dependency>
dependencies {
implementation 'com.github.HyDevelop:OsuBeatmapParser:1.1.2.109'
}
The dependency would be ready once you reimport.
If you are not using maven or gradle, Import from Other Package Managers
val beatmap = BeatmapReader.parse(File("file_name.osu"))
// or
val beatmap = BeatmapReader.parse(beatmapText)
Beatmap beatmap = BeatmapReader.parse(new File("file_name.osu"));
// or
Beatmap beatmap = BeatmapReader.parse(beatmapText);
File("output.osu").writeText(beatmap.toString())
PrintWriter out = new PrintWriter("output.osu");
out.print(beatmap);
You can manipulate it like an object. Almost every property is parsed (except for color properties that I'm not sure about).
Read some code!
I'm great, how are you?
Basically this means you can do whatever you want with this project but you have to include the license file and I'm not responsible for what you do.
MIT License
Copyright (c) 2020 - HyDEV -
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.