Files
Terrarum/src/net/torvald/terrarum/gameactors/PlayerBuilder.kt
Song Minjae 413603de6f fixed wrong package, fixed wrong creation date
Former-commit-id: 8a2a91a5252347b5184f62ec0f7009292fbb01bb
Former-commit-id: b31eaddf7596c8393c9a032e8897ef3f1a8234fd
2016-10-26 00:37:49 +09:00

25 lines
598 B
Kotlin

package net.torvald.terrarum.gameactors
import net.torvald.terrarum.Terrarum
import org.newdawn.slick.SlickException
import java.io.IOException
/**
* Created by minjaesong on 16-02-03.
*/
object PlayerBuilder {
private val JSONPATH = "./assets/raw/"
private val jsonString = String()
fun create(): Actor {
val p: Actor = Player(Terrarum.ingame.world.time.currentTimeAsGameDate)
CreatureRawInjector.inject(p.actorValue, "CreatureHuman.json")
// attach sprite
// do etc.
p.actorValue[AVKey.__PLAYER_QUICKBARSEL] = 0
return p
}
}