/osu-parser

Parse any osu! related file (in theory. Right now only *.osr (replays) and *.osu (beatmaps) files are supported)

Primary LanguageC++The UnlicenseUnlicense

оsu!рarsеr

Parse any osu! related file (in theory. Right now only *.osr (replays) and *.osu (beatmaps) files are supported)

Features

  • Easy API
  • No compilation required
  • Cross-platform
  • Unlicense

Navigation

Status

  • osr: Tested with valid osu!standard replays
  • osu: Tested (but not thoroughly) with valid osu!standard beatmaps
  • WARNING: In all other cases behavior might be unpredictable

Requirements

  • Has to be linked and compiled with LZMA-SDK

Installation

For Microsoft Visual Studio 2017:

  1. Add path to include/ directory as an additional include directory to the project
  2. Add all *.cpp files from src/ directory as existing source files to the project

Code sample

osr

#include "osu!parser.h"
#include <fstream>

int main()
{
    std::ifstream file("replay.osr", std::ios::binary);
    osuParser::OsrParser p(file);
    p.Parse();
    // p.<parsedValues>
}

(Refer to osr file format documentation for details)

osu

#include "osu!parser.h"
#include <fstream>

int main()
{
    std::ifstream file("beatmap.osu");
    osuParser::OsuParser p(file);
    p.Parse();
    // p.<parsedValues>
}

(Refer to osu file format documentation for details)

Documentation

For detailed markdown description of available methods and fields, see documentation.

TODO

  • Parse .db files
  • Test other game modes for *.osr and *.osu