Module:Ups and downs notation: Difference between revisions
CompactStar (talk | contribs) No edit summary |
CompactStar (talk | contribs) No edit summary |
||
| Line 75: | Line 75: | ||
local num_sharps = math.floor((i - last_major_note) / chroma) | local num_sharps = math.floor((i - last_major_note) / chroma) | ||
local num_ups = (i - last_major_note) % chroma | local num_ups = (i - last_major_note) % chroma | ||
if | if chroma == 0 then | ||
num_sharps = 0 | num_sharps = 0 | ||
num_ups = (i - last_major_note) | num_ups = (i - last_major_note) | ||