adding 'kind flag' to the savegame format so the file can be determined if it contains player or world data

This commit is contained in:
minjaesong
2022-12-04 16:09:07 +09:00
parent 400cdd5b3c
commit b2479028af
7 changed files with 62 additions and 16 deletions

View File

@@ -173,7 +173,7 @@ object VDUtil {
val crcMsg =
"CRC failed: stored value is ${entryCRC.toHex()}, but calculated value is ${calculatedCRC.toHex()}\n" +
"at file \"${diskIDtoReadableFilename(diskEntry.entryID)}\" (entry ID ${diskEntry.entryID})"
"at file \"${diskIDtoReadableFilename(diskEntry.entryID, vdisk.saveKind)}\" (entry ID ${diskEntry.entryID})"
if (calculatedCRC != entryCRC) {
@@ -196,7 +196,7 @@ object VDUtil {
}
}
catch (e: ArrayIndexOutOfBoundsException) {
System.err.println("An error occurred while reading a file (entryID: $entryID (${diskIDtoReadableFilename(entryID)}), typeFlag: $entryTypeFlag)")
System.err.println("An error occurred while reading a file (entryID: $entryID (${diskIDtoReadableFilename(entryID, vdisk.saveKind)}), typeFlag: $entryTypeFlag)")
System.err.println("Stack trace:")
e.printStackTrace()
break