I'm working on MIDI Events for blockland, I wanted an easier way to have things happen without going back and forth
to see if I timed it right. I'm hoping Torque and Blockland can use MIDI, if not, then I'm screwed. I can't seem to list MIDI Files from a folder or zip file. Help me out here, I have no experience with torque, I'm only learning from addons, but I can make like sounds, prints, easy stuff. Well easy for me
This is how I left it as I posted this.
function MIDI_SongList($MIDI)
{
//
%pattern = "Add-Ons/MIDI_MIDI_Files/*.mid";
$MIDI::numMIDIs = 0;
%file = findFirstFile(%pattern);
while(%file !$= "")
{
$MIDI::Song[$MIDI::numMIDIs] = %file;
$MIDI::numMIDIs++;
%file = findNextFile(%pattern);
}
}
RegisterOutputEvent(fxDTSBrick,"Set_MIDI_pref","int 1 16 1\tint 0 127 60",1);
RegisterOutputEvent(fxDTSBrick,"Play_MIDI_file","list $MIDI" TAB "bool");
//The MIDI Preferences are Channel, then note. The Play MIDI file bool is for
//whether or not the song will be played or stopped.
function MIDI_note_is_on()
{
}
RegisterInputEvent(fxDTSBrick,"MIDI_note_is_on","Self fxDTSBrick");
function MIDI_note_is_off()
{
}
RegisterInputEvent(fxDTSBrick,"MIDI_note_is_off","Self fxDTSBrick");
MIDI note on and off explain them self's, basically everything is explained, I just get can't get the list to work.