Skip to content

on_self_option

fun on_self_option(
option: String,
behaviour: Interaction<Entity>.(clicker: Entity) -> Unit
)
Interaction<Entity>.(clicker: Entity) -> Unit

Entity

Works with: Npc // WorldObject // WorldItem // WorldProjection // Actor

Example
node<WorldObject>()
on_self_option("Climb-up") { clicker ->
clicker.message("You climb up the ladder.")
}
option: String
val target: T