mirror of
https://github.com/freedoom/freedoom.git
synced 2025-09-02 07:25:45 -04:00
genmidi: Output fixed_note as constant value.
Generate output that uses the more readable constants from midi.py instead of just a MIDI note number.
This commit is contained in:
parent
b0253e3176
commit
b6b9cf999e
2 changed files with 13 additions and 1 deletions
|
@ -37,6 +37,7 @@
|
|||
import genmidi
|
||||
import sbi_file
|
||||
import sys
|
||||
import midi
|
||||
|
||||
def print_instr_def(filename, filename2, instr):
|
||||
result = "Instrument(\"%s\"" % filename
|
||||
|
@ -45,7 +46,7 @@ def print_instr_def(filename, filename2, instr):
|
|||
result += (", \"%s\"" % filename2)
|
||||
|
||||
if instr.fixed_note is not None:
|
||||
result += (", note=%i" % instr.fixed_note)
|
||||
result += (", note=%s" % midi.def_for_note(instr.fixed_note))
|
||||
if instr.offset1 != 0:
|
||||
result += (", off1=%i" % instr.offset1)
|
||||
if instr.offset2 != 0:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue