game load wip

This commit is contained in:
minjaesong
2021-09-03 17:54:10 +09:00
parent 42ea79bcc2
commit 57e4b83649
27 changed files with 542 additions and 462 deletions

View File

@@ -8,6 +8,7 @@ import net.torvald.terrarum.AppLoader.printdbg
import net.torvald.terrarum.blockproperties.Block
import net.torvald.terrarum.blockproperties.BlockCodex
import net.torvald.terrarum.blockproperties.Fluid
import net.torvald.terrarum.gameactors.ActorID
import net.torvald.terrarum.gameactors.WireActor
import net.torvald.terrarum.gameitem.ItemID
import net.torvald.terrarum.realestate.LandUtil
@@ -42,9 +43,6 @@ class GameWorld() : Disposable {
var totalPlayTime: Long = 0
internal set
/** Used to calculate play time */
@Transient open val loadTime: Long = System.currentTimeMillis() / 1000L
//layers
lateinit var layerWall: BlockLayer
lateinit var layerTerrain: BlockLayer
@@ -106,6 +104,8 @@ class GameWorld() : Disposable {
internal var genver = -1
internal var comp = -1
internal val actors = ArrayList<ActorID>() // only filled up on save and load; DO NOT USE THIS
/**
* Create new world
*/