Commit 07f720a

Nick Faro committed on
Clamp famitracker notes after calculation
commit 07f720ac18d251f86e2a6ec6c2e6fd1c299e8470 parent 4b7ead0
1 changed files +3−1
Modifiedsrc/clipboardutils.pas +3−1
@@ -108,7 +108,9 @@ function GetFamitrackerPastedCells: TSelection;
108 begin 108 begin
109 case Note.Note of 109 case Note.Note of
110 0, 13, 14, 15: Result.Note := NO_NOTE; 110 0, 13, 14, 15: Result.Note := NO_NOTE;
111 else Result.Note := (C_3 + (Note.Note-1)) + (12*(Note.Octave - 1)); 111 else begin
112 Result.Note := EnsureRange((C_3 + (Note.Note-1)) + (12*(Note.Octave - 1)), LOWEST_NOTE, HIGHEST_NOTE);
113 end;
112 end; 114 end;
113 115
114 if Note.Instrument = 64 then 116 if Note.Instrument = 64 then