new and sane graph traversal; only works for first of the multiple wires tho

This commit is contained in:
minjaesong
2021-08-13 14:39:20 +09:00
parent a6d082fb7d
commit 479dc5c3fb
3 changed files with 56 additions and 100 deletions

View File

@@ -35,11 +35,13 @@ class FixtureLogicSignalEmitter(nameFun: () -> String)
override fun update(delta: Float) {
// set emit
worldBlockPos?.let { (x, y) ->
/*worldBlockPos?.let { (x, y) ->
WireCodex.getAll().filter { it.accepts == "digital_bit" }.forEach { prop ->
world?.setWireEmitStateOf(x, y, prop.id, wireEmission[0]!!)
// only set a state of wire that actually exists on the world
if (world?.getWireGraphOf(x, y, prop.id) != null)
world?.setWireEmitStateOf(x, y, prop.id, wireEmission[0]!!)
}
}
}*/
}
}