mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-19 06:54:05 +09:00
game load wip
This commit is contained in:
@@ -10,6 +10,7 @@ import net.torvald.terrarum.gameitem.ItemID
|
||||
import net.torvald.terrarum.gameworld.GameWorld
|
||||
import net.torvald.terrarum.modulebasegame.IngameRenderer
|
||||
import net.torvald.terrarum.modulebasegame.gameactors.ActorHumanoid
|
||||
import net.torvald.terrarum.modulecomputers.virtualcomputer.tvd.VirtualDisk
|
||||
import net.torvald.terrarum.ui.ConsoleWindow
|
||||
import net.torvald.util.SortedArrayList
|
||||
import java.util.concurrent.locks.Lock
|
||||
@@ -20,6 +21,9 @@ import java.util.concurrent.locks.Lock
|
||||
*/
|
||||
open class IngameInstance(val batch: SpriteBatch) : Screen {
|
||||
|
||||
lateinit var savegameArchive: VirtualDisk
|
||||
internal set
|
||||
|
||||
var screenZoom = 1.0f
|
||||
val ZOOM_MAXIMUM = 4.0f
|
||||
val ZOOM_MINIMUM = 1.0f
|
||||
@@ -81,6 +85,9 @@ open class IngameInstance(val batch: SpriteBatch) : Screen {
|
||||
val wallChangeQueue = ArrayList<BlockChangeQueueItem>()
|
||||
val wireChangeQueue = ArrayList<BlockChangeQueueItem>() // if 'old' is set and 'new' is blank, it's a wire cutter
|
||||
|
||||
var loadedTime_t = AppLoader.getTIME_T()
|
||||
protected set
|
||||
|
||||
override fun hide() {
|
||||
}
|
||||
|
||||
@@ -119,6 +126,8 @@ open class IngameInstance(val batch: SpriteBatch) : Screen {
|
||||
printdbg(this, "dispose called by")
|
||||
printStackTrace(this)
|
||||
|
||||
actorContainerActive.forEach { it.dispose() }
|
||||
actorContainerInactive.forEach { it.dispose() }
|
||||
world.dispose()
|
||||
}
|
||||
|
||||
@@ -275,6 +284,7 @@ open class IngameInstance(val batch: SpriteBatch) : Screen {
|
||||
|
||||
|
||||
|
||||
|
||||
data class BlockChangeQueueItem(val old: ItemID, val new: ItemID, val posX: Int, val posY: Int)
|
||||
|
||||
open fun sendNotification(messages: Array<String>) {}
|
||||
|
||||
Reference in New Issue
Block a user