Directed graph implementation which may be useful for creating large machines more quickly. The Dungeon sample demonstrates a use case of this module.
sealed class Energy {
object Kinetic : Energy()
object Potential : Energy()
}
sealed class EnergyTransition {
object Store : EnergyTransition()
object Release : EnergyTransition()
}
DirectedGraph(
mapOf(
Potential to mapOf(Release to Kinetic),
Kinetic to mapOf(Store to Potential)
))
Includes directed graphs
compile "com.ToxicBakery.kfinstatemachine:graph:2.+"