Add height and direction params to npc_spawn

This commit is contained in:
Jesse
2017-05-31 21:35:47 -04:00
committed by Gary Tierney
parent 7ecc2e3158
commit 8d00dcc7c8
+2 -4
View File
@@ -1,6 +1,4 @@
import org.apollo.cache.def.NpcDefinition
import org.apollo.game.model.*
import org.apollo.game.model.entity.Npc
data class Spawn(val id: Int?, val name: String, val position: Position, val facing: Direction,
val spawnAnimation: Animation? = null,
@@ -10,6 +8,6 @@ object Spawns {
val list = mutableListOf<Spawn>()
}
fun npc_spawn(name: String, x: Int, y: Int, id: Int? = null) {
Spawns.list.add(Spawn(id, name, Position(x, y), Direction.NORTH))
fun npc_spawn(name: String, x: Int, y: Int, z: Int = 0, id: Int? = null, facing: Direction = Direction.NORTH) {
Spawns.list.add(Spawn(id, name, Position(x, y, z), facing))
}