Skip to content

Commit

Permalink
add lua hooks for replay mods and rng
Browse files Browse the repository at this point in the history
  • Loading branch information
poco0317 committed Nov 5, 2022
1 parent 760472e commit e9846b7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/Etterna/Models/HighScore/Replay.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2209,12 +2209,16 @@ class LunaReplay : public Luna<Replay>
DEFINE_METHOD(GetChartKey, GetChartKey())
DEFINE_METHOD(GetScoreKey, GetScoreKey())
DEFINE_METHOD(GetReplayType, GetReplayType())
DEFINE_METHOD(GetRngSeed, GetRngSeed())
DEFINE_METHOD(GetModifiers, GetModifiers());

LunaReplay() {
ADD_METHOD(HasReplayData);
ADD_METHOD(GetChartKey);
ADD_METHOD(GetScoreKey);
ADD_METHOD(GetReplayType);
ADD_METHOD(GetRngSeed);
ADD_METHOD(GetModifiers);

ADD_METHOD(GetOffsetVector);
ADD_METHOD(GetNoteRowVector);
Expand Down
4 changes: 4 additions & 0 deletions src/Etterna/Models/HighScore/Replay.h
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,10 @@ class Replay
void SetSongOffset(float f) { fSongOffset = f; }
auto GetGlobalOffset() const -> float { return fGlobalOffset; }
void SetGlobalOffset(float f) { fGlobalOffset = f; }
auto GetRngSeed() const -> int { return rngSeed; }
void SetRngSeed(int seed) { rngSeed = seed; }
auto GetModifiers() const -> std::string { return mods; }
void SetModifiers(std::string& modstr) { mods = modstr; }

ReplayType GetReplayType() const
{
Expand Down

0 comments on commit e9846b7

Please sign in to comment.