The component ids Entity.getComponent takes.
Enum in @minecraft/server
The component ids Entity.getComponent takes. Basalt backs the ones listed here.
import { EntityComponentTypes } from '@minecraft/server';Example
Section titled “Example”import { EntityComponentTypes } from '@minecraft/server';
const value: EntityComponentTypes = EntityComponentTypes.Health;console.log(value); // "minecraft:health"import { EntityComponentTypes } from '@minecraft/server';
const value = EntityComponentTypes.Health;console.log(value); // "minecraft:health"Values
Section titled “Values”| Name | Value | Description |
|---|---|---|
Health |
"minecraft:health" |
|
Inventory |
"minecraft:inventory" |
|
Equippable |
"minecraft:equippable" |
|
Rideable |
"minecraft:rideable" |
|
Riding |
"minecraft:riding" |
|
Item |
"minecraft:item" |