mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-09 18:14:06 +09:00
savegame cracker: fixing a mistake that space chars would not tokenise the command input
This commit is contained in:
@@ -140,6 +140,9 @@ class SavegameCracker(
|
|||||||
sendout()
|
sendout()
|
||||||
mode = 39
|
mode = 39
|
||||||
}
|
}
|
||||||
|
else if (c == ' ') {
|
||||||
|
sendout()
|
||||||
|
}
|
||||||
else
|
else
|
||||||
sb.append(c)
|
sb.append(c)
|
||||||
}
|
}
|
||||||
@@ -228,6 +231,8 @@ class SavegameCracker(
|
|||||||
val id0 = args[1].toLong(10)
|
val id0 = args[1].toLong(10)
|
||||||
val id1 = args[2].toLong(10)
|
val id1 = args[2].toLong(10)
|
||||||
|
|
||||||
|
if (it.entries.containsKey(id1)) throw IllegalArgumentException("Entry ID $id1 already exists")
|
||||||
|
|
||||||
val entry = it.entries.remove(id0)!!
|
val entry = it.entries.remove(id0)!!
|
||||||
entry.entryID = id1
|
entry.entryID = id1
|
||||||
it.entries[id1] = entry
|
it.entries[id1] = entry
|
||||||
|
|||||||
Reference in New Issue
Block a user