EverambleGAME API / 1

CONTENT CONTRACT · VERSION 1

craft

Craft a recipe for an actor: ingredients are debited and the result granted atomically.

Signature

{ actor: ActorRef, count: PositiveCount, kind: "craft", recipe: RecipeId }

Fields

NameTypeMeaning
actorActorRefCrafting actor.
Length: 1…256; Pattern: ^[\s\S]+$
countPositiveCountNumber of crafts.
Range: 1…2147483647; Unit: count
kind"craft"Discriminant
recipeRecipeIdCraft recipe.
Length: 1…129; Pattern: ^[a-z][a-z0-9_]{0,31}:[a-z][a-z0-9_]{0,95}$; Reference: recipe

Validated example

{
  "count": 5,
  "item": "core:arrow",
  "kind": "craft"
}