c0de 0.3.0This page in English

Diese Seite ist noch nicht übersetzt. Sie wird auf Englisch angezeigt.

SPAWN_ENTITY ​

Spawns an entity, such as a pig, at a position.

The result is the UUID of the new entity. This needs allowSpawning or an administrator as owner, otherwise PERMISSION_DENIED is raised. An unknown type raises INVALID_ARGUMENT.

Parameters and results

  • position STRUCT c0de/minecraft/POSITION: where the entity appears
  • type STRING: the entity type, e.g. minecraft:pig
  • result result STRING: the UUID of the entity

Example

c0de
CALL c0de/minecraft/SPAWN_ENTITY
    PARAMETER position pen ;
    PARAMETER type "minecraft:pig" ;
    RESULT result pigId