donnaken15 / FastGH3

Minimalist Guitar Hero 3 mod with one click play and numerous gameplay fixes and additions
https://donnaken15.com/FastGH3
Other
24 stars 1 forks source link

MID2CHARTTTTTT #4

Closed donnaken15 closed 1 year ago

donnaken15 commented 2 years ago

I DON'T UNDERSTAND THIS!

I DON'T HAVE THIS HAPPEN TO ME BUT SOMEHOW IT DOES FOR OTHERS System.FormatException: Not a MIDI file - header chunk missing at NAudio.Midi.MidiFile..ctor(String filename, Boolean strictChecking) at mid2chart.MidReader.ReadMidi(String path, Boolean unforceNAudioStrictMode) at mid2chart.Program.Main(String[] args) and something about command 0xB0

LocalH commented 2 years ago

Workaround is to delete mid2chart.log before feeding a .mid to fastgh3.exe. I wouldn't delete it after conversion and before launching the game, but perhaps it's worth deleting it if it's there before conversion.

donnaken15 commented 2 years ago

I forgot that, when I wanted to get around mid2chart not outputting to the launcher for some reason, I wanted to delete the log first and then let it log whenever it freaks out about whatever stupid thing it can't convert

But at the same time, it not converting because the log exists before doesn't make sense, unless I'm missing something, but I just File.WriteAllText the exception it spits out

donnaken15 commented 2 years ago

Was that log error thing with the "chunk missing" or "command B0"

LocalH commented 2 years ago

both, IIRC. But it would do one for a while then suddenly change to the other. I'll try to catch the next time I see a .log file appear before I launch another song, so I don't overwrite it, in case the contents are helpful.

donnaken15 commented 2 years ago

Regardless, the launcher will print what's in the .log whenever the mid2chart throws, and it would print either of the same thing anyway.

Post-writing: Wait... I think I just realized what I did.

donnaken15 commented 2 years ago

Regardless, the launcher will print what's in the .log whenever the mid2chart throws, and it would print either of the same thing anyway.

Post-writing: Wait... I think I just realized what I did.

a little patch to deal with this I commented out code that deleted the log first before running mid2chart for some reason https://github.com/donnaken15/FastGH3/commit/25d707060c6d886e6f85e0b96261ade38b722202