Pular para o conteúdo principal

btcsky_npc_reference_block

NPC Reference Block — npc entry.

Entry Information

PropertyValue
Entry IDbtcsky_npc_reference_block
TypeNpc
ColorOrange
Iconmaterial-symbols:person-pin

Description

NPC Reference Block Entry — allows server creators to define a block location that spawns a 3D entity model (NPC, meteorite, boss, etc.) when triggered by an event or player interaction. This is the clean replacement for hardcoded entity spawning in events. The entity is spawned via TypeWriter's EntityInstance system, supporting BetterModel, BTCMob, MythicMobs, and vanilla entities. Usage: - Place in a page JSON with the desired entity definition and position - Reference from events via Ref<NpcReferenceBlockEntry> - Call spawn() from event code to spawn the entity at the defined location

Fields

FieldTypeDescription
entityRef<out EntityDefinitionEntry>The entity definition to spawn (Entity, BetterModel, BTCMobNPC, MythicMobsNPC)
spawnOffsetPositionThe position where the entity should spawn (offset from island spawn)
dimensionIdStringThe dimension ID where this NPC should appear (e.g., 'overworld', 'nether')
despawnAfterSecondsIntDuration in seconds before the entity despawns (0 = permanent)
visibleToAllBooleanWhether the entity is visible to all players on the island
customNameStringCustom name displayed above the entity (supports MiniMessage)
interactionRadiusDoubleRadius in blocks for player interaction detection
modelScaleDoubleScale multiplier for the entity model (1.0 = normal)

Usage Example

- entry: btcsky_npc_reference_block
name: "NPC Reference Block"
entity: ""
spawnOffset: ""
dimensionId: ""
despawnAfterSeconds: 0
visibleToAll: false
customName: ""
interactionRadius: 0
modelScale: 0