mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-12 19:44:05 +09:00
still working on the new savegame scheme
main game works fine, saving/loading will not be possible
This commit is contained in:
@@ -250,6 +250,7 @@ removefile:
|
||||
}
|
||||
}
|
||||
|
||||
override fun getEntry(id: EntryID) = requestFile(id)
|
||||
override fun getFile(id: EntryID) = requestFile(id)?.contents as? EntryFile
|
||||
|
||||
/**
|
||||
|
||||
@@ -4,5 +4,6 @@ package net.torvald.terrarum.tvda
|
||||
* Created by minjaesong on 2021-10-07.
|
||||
*/
|
||||
interface SimpleFileSystem {
|
||||
fun getEntry(id: EntryID): DiskEntry?
|
||||
fun getFile(id: EntryID): EntryFile?
|
||||
}
|
||||
@@ -143,6 +143,7 @@ class VirtualDisk(
|
||||
extraInfoBytes = footer.toByteArray()
|
||||
}
|
||||
|
||||
override fun getEntry(id: EntryID) = entries[id]
|
||||
override fun getFile(id: EntryID) = try { VDUtil.getAsNormalFile(this, id) } catch (e: NullPointerException) { null }
|
||||
|
||||
private fun serializeEntriesOnly(): ByteArray64 {
|
||||
|
||||
Reference in New Issue
Block a user