Skip to content

Commit 36c62d0

Browse files
committed
NoteFieldPreview steps loaded from lua will follow style track remapping
it seems this only matters for beat which has a scratch lane and for some odd reason we decided to put column 8 on the first column, shifting everything right by 1. this implies that all single7 charts are actually for p2 which seems really really wrong or maybe our notesloader is wrong. didnt check that. anyways this is proper behavior, whatever is going on with that is probably not
1 parent 744ae0e commit 36c62d0

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

src/Etterna/Actor/Gameplay/NoteFieldPreview.cpp

+8
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,14 @@ NoteFieldPreview::LoadNoteData(Steps* pSteps, bool bTransform)
194194
nd->GetNumTracks() != style->m_iColsPerPlayer)
195195
GAMESTATE->SetCompatibleStylesForPlayers();
196196

197+
// This says it transforms the NoteData but really all it does:
198+
// Map NoteData to the Style it is for (usually for beat or something?)
199+
if (nd != nullptr && style != nullptr) {
200+
NoteData ndo;
201+
style->GetTransformedNoteDataForStyle(PLAYER_1, *nd, ndo);
202+
*nd = ndo;
203+
}
204+
197205
// Transform NoteData incoming (this being only here is because only lua uses it)
198206
// (for now)
199207
if (nd != nullptr && bTransform) {

src/Etterna/Actor/Gameplay/NoteFieldPreview.h

+2
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@ class NoteFieldPreview : public NoteField
1111
void LoadFromNode(const XNode* pNode) override;
1212
void Update(float fDeltaTime) override;
1313
void DrawPrimitives() override;
14+
// THIS DOESNT TRANSFORM NOTEDATA!!! DO IT YOURSELF!!!!
1415
void LoadNoteData(NoteData* pNoteData);
16+
// This transforms NoteData to style and will follow PlayerOptions if wanted
1517
void LoadNoteData(Steps* pSteps, bool bTransform = false);
1618
void LoadDummyNoteData();
1719
void UpdateDrawDistance(int aftertargetspixels, int beforetargetspixels);

0 commit comments

Comments
 (0)