From 559fc13e674d81d16b14ec8aa3a6c6e38d4fa453 Mon Sep 17 00:00:00 2001 From: tom-overton Date: Thu, 30 Dec 2021 11:45:46 -0800 Subject: Add file name to ROM diagnostics --- src/com/dabomstew/pkrandom/romhandlers/AbstractGBRomHandler.java | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/com/dabomstew/pkrandom/romhandlers') diff --git a/src/com/dabomstew/pkrandom/romhandlers/AbstractGBRomHandler.java b/src/com/dabomstew/pkrandom/romhandlers/AbstractGBRomHandler.java index ccf8667..d456e4c 100755 --- a/src/com/dabomstew/pkrandom/romhandlers/AbstractGBRomHandler.java +++ b/src/com/dabomstew/pkrandom/romhandlers/AbstractGBRomHandler.java @@ -30,6 +30,8 @@ import java.io.FileInputStream; import java.io.FileOutputStream; import java.io.IOException; import java.io.PrintStream; +import java.nio.file.Path; +import java.nio.file.Paths; import java.util.Random; import com.dabomstew.pkrandom.FileFunctions; @@ -107,6 +109,8 @@ public abstract class AbstractGBRomHandler extends AbstractRomHandler { @Override public void printRomDiagnostics(PrintStream logStream) { + Path p = Paths.get(loadedFN); + logStream.println("File name: " + p.getFileName().toString()); long crc = FileFunctions.getCRC32(originalRom); logStream.println("Original ROM CRC32: " + String.format("%08X", crc)); } -- cgit v1.2.3