Package-level declarations

Types

Link copied to clipboard
interface NPCOp

A global interface for all NPC operations

Link copied to clipboard
data class NPCOpBranch(val condition: (NPCOperationData) -> Boolean, val trueBranch: List<NPCOp>, val falseBranch: List<NPCOp>) : NPCOp

Branches the operation logic into two paths based on predicate result

Link copied to clipboard
data class NPCOperationData(val player: MacrocosmPlayer, val playerPaper: Player, val self: MacrocosmNPC, val selfPaper: Entity)

Context for an NPC dialogue operation

Link copied to clipboard
data class NPCOpExecute(val branch: (NPCOperationData) -> Unit) : NPCOp

Executes provided code

Link copied to clipboard
data class NPCOpGrantGoal(val goal: String) : NPCOp

Grants player a goal

Link copied to clipboard
class NPCOpOpenShop(val id: Identifier) : NPCOp

An operation that opens a shop to player

Link copied to clipboard
data class NPCOpOpenUI(val open: (NPCOperationData) -> GUI<out ForInventory>) : NPCOp

Opens a KSpigot UI for player

Link copied to clipboard
data class NPCOpPlaySound(val sound: Sound, val pitch: Number, val volume: Number) : NPCOp

Plays a sound

Link copied to clipboard
data class NPCOpSay(val message: String) : NPCOp

Says something to player

Link copied to clipboard
data class NPCOpSendMessage(val message: String) : NPCOp

Sends a raw message to player

Link copied to clipboard
data class NPCOpWait(val seconds: Number) : NPCOp

Waits for provided amount of seconds