mirror of
https://github.com/curioustorvald/Terrarum.git
synced 2026-06-18 14:34:04 +09:00
bunch of codes:
- Test InputStream() on VirtualComputer (blocking/unblocking using simple semaphore) -- no more dirty lua impl of io.read - Typealias Kotlin 1.1 - Primitive box drawing on VideoCard - Removing unnecessary fonts Former-commit-id: cece88af3a3430678e685856eec78b4a9d598b4f Former-commit-id: 22eed3a7beb9b4cb34636cbab2ff0e94989bdb31
This commit is contained in:
@@ -47,10 +47,10 @@ class LuaAIWrapper(private val scriptPath: String) : ActorAI {
|
||||
|
||||
override fun update(delta: Int) {
|
||||
// run "update()" function in the script
|
||||
luag.get("update").call(delta.toLuaValue())
|
||||
luag.get("update").call(delta.toLua())
|
||||
}
|
||||
|
||||
var currentExecutionThread = Thread()
|
||||
lateinit var currentExecutionThread: Thread
|
||||
var threadRun = false
|
||||
|
||||
fun runCommand(reader: Reader, filename: String) {
|
||||
@@ -109,5 +109,5 @@ class LuaAIWrapper(private val scriptPath: String) : ActorAI {
|
||||
}
|
||||
}
|
||||
|
||||
fun Int.toLuaValue(): LuaValue = LuaInteger.valueOf(this)
|
||||
fun Int.toLua(): LuaValue = LuaInteger.valueOf(this)
|
||||
}
|
||||
Reference in New Issue
Block a user