reducing number of warnings on the codebase

This commit is contained in:
minjaesong
2021-08-20 23:28:59 +09:00
parent 69075ad6da
commit bb95444067
24 changed files with 58 additions and 164 deletions

View File

@@ -49,7 +49,7 @@ object SavegameWriter {
private lateinit var playerName: String
operator fun invoke(pnameOverride: String? = null): Boolean {
playerName = pnameOverride ?: "${Terrarum.ingame!!.actorGamer!!.actorValue[AVKey.NAME]}"
playerName = pnameOverride ?: "${Terrarum.ingame!!.actorGamer.actorValue[AVKey.NAME]}"
if (playerName.isEmpty()) playerName = "Test subject ${Math.random().times(0x7FFFFFFF).roundToInt()}"
try {
@@ -71,7 +71,7 @@ object SavegameWriter {
val creationDate = System.currentTimeMillis() / 1000L
val ingame = Terrarum.ingame!!
val gameworld = ingame.world
val player = ingame.actorGamer!!
val player = ingame.actorGamer
val disk = VDUtil.createNewDisk(0x7FFFFFFFFFFFFFFFL, "Tesv-$playerName", charset)
val ROOT = disk.root.entryID