gui for load savegame

This commit is contained in:
minjaesong
2023-06-28 16:10:15 +09:00
parent 1745bb16db
commit bb017fa9b7
6 changed files with 46 additions and 31 deletions

View File

@@ -14,7 +14,7 @@ import kotlin.io.path.Path
class SavegameCollection(files0: List<DiskSkimmer>) {
/** Sorted in reverse by the last modified time of the files, index zero being the most recent */
val files = files0.sortedByDescending { it.getLastModifiedTime() }
val files = files0.sortedByDescending { it.getLastModifiedTime().shl(1) or it.diskFile.extension.matches(Regex("^[abc]\$")).toLong() }
/** Sorted in reverse by the last modified time of the files, index zero being the most recent */
val autoSaves = files.filter { it.diskFile.extension.matches(Regex("[a-z]")) }
/** Sorted in reverse by the last modified time of the files, index zero being the most recent */