Open Brollyy opened 2 weeks ago
@PKBeam It's been two weeks without any further bug reports for 1.2.7b1, so I don't think I'll need to change anything in this PR anymore. I've also mapped a few songs with 1.2.7b1 without noticing any issues and confirmed with Watsu that he didn't see any issues as well.
133
I'm very sorry for a large PR - while working on the clipboard, I've also noticed several performance issues and smaller bugs with rune images sometimes showing X wrongly, so I've ended up going a bit too far and fixing them here as well.
Changelist
Copy/paste
To better illustrate what these changes are mainly about, I'll provide a few examples of how the new code behaves.
Ctrl+C
to copy the notes into clipboard.Ctrl+V
somewhere else to paste the notes, just as before, but now it works automatically for:AAEJ+IsEvJ8EgLMExMYEiNoEzO0EkIEF1JQFmKgFG7kAAAACALDNXpY3sM1e
), which can then be copied and pasted again into Edda seemlessly. This is the main use-case for the library, to enable easy sharing of patterns on Discord or RagnaCustoms. I also have plans in the near future to create a small Discord bot that will generate and post visualizations of these runestrings, so we can stop talking about patterns in ASCII art 😄When pasting previously copied notes or a runestring, Edda will now have three modes of how the new notes will be added:
1. Align to global beat
This is how the copy/paste worked in Edda until now - you move the global beats of the copied notes by an offset determined by current mouse position and then add them to the map.
Fully inside section with global BPM:
Fully inside section with different BPM:
Partially inside both global BPM and different BPM:
Partially inside different BPM and then global BPM:
Pros:
Cons:
2. Align to first note BPM
This is very similar to the previous mode, but the timing of all the pasted notes is scaled relative to the BPM from which the first copied note came from, and the BPM at the current mouse position. For example, when copying the pattern above into a different section with 120 BPM, the notes will align to the grid, but that won't be the case if the timing change occurs somewhere after the first pasted note.
Fully inside section with global BPM:
Fully inside section with different BPM:
Partially inside both global BPM and different BPM:
Partially inside different BPM and then global BPM:
Pros:
Cons:
3. Align to all notes BPM (default)
While it's more complicated to explain how this mode work in detail, it's designed to remedy the issue from the previous mode, so that the copied pattern "looks" the same on the grid as it "looked" when it was copied.
Fully inside section with global BPM:
Fully inside section with different BPM:
Partially inside both global BPM and different BPM:
Partially inside different BPM and then global BPM:
Pros:
Cons:
Before I've implemented these changes, I've run a poll on Discord channel to see which option would be preferable - this is why the last mode is selected as the new default.
The selected mode can be changed in the settings: