Entity Documentation - minecraft:teleport
minecraft:teleport
defines an entity's teleporting behavior.
Parameters
Name | Default Value | Type | Description |
---|---|---|---|
dark_teleport_chance | 0.01 | Decimal | Modifies the chance that the entity will teleport if the entity is in darkness |
light_teleport_chance | 0.01 | Decimal | Modifies the chance that the entity will teleport if the entity is in daylight |
max_random_teleport_time | 20 | Decimal | Maximum amount of time in seconds between random teleports |
min_random_teleport_time | 0 | Decimal | Minimum amount of time in seconds between random teleports |
random_teleport_cube | [32, 16, 32] | Vector [a, b, c] | Entity will teleport to a random position within the area defined by this cube |
random_teleports | True | Boolean | If true, the entity will teleport randomly |
target_distance | 16 | Decimal | Maximum distance the entity will teleport when chasing a target |
target_teleport_chance | 1 | Decimal | The chance that the entity will teleport between 0.0 and 1.0. 1.0 means 100% |
Example
"minecraft:teleport":{
"dark_teleport_chance": 0.01,
"light_teleport_chance": 0.01,
"max_random_teleport_time": 20,
"min_random_teleport_time": 0,
"random_teleport_cube": [32, 16, 32],
"random_teleports": true,
"target_distance": 16,
"target_teleport_chance": 1
}
Vanilla entities examples
enderman
"minecraft:teleport": {
"random_teleports": true,
"max_random_teleport_time": 30,
"random_teleport_cube": [ 64, 32, 64 ],
"target_distance": 16,
"target_teleport_chance": 0.05,
"light_teleport_chance": 0.05
}
Vanilla entities using minecraft:teleport
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈