Declare Comment - ChenCMD/datapack-helper-plus-JP GitHub Wiki
#declareコメントは、補完, シンボル名の変更, 参照/宣言の検索に使用できるリソースを宣言する方法です。
また、#defineは#declareとまったく同じように動作します。
ゲーム内では宣言コメントを通常のコメントとして扱います。
構文: #declare|#define <type: string> <value: string>

次の表は、リソースの各タイプを宣言または定義する方法です:
| 種類 | 宣言の構文 | 本来の定義方法 |
|---|---|---|
| Advancement | #declare advancement <ID> |
advancements/<ID> |
| Biome | #declare worldgen/biome <ID> |
worldgen/biome/<ID> |
| Block Tag | #declare tag/block <ID> |
tags/blocks/<ID> |
| Bossbar | #declare bossbar <ID> |
bossbar add <ID> |
| Configured Carver | #declare worldgen/configured_carver <ID> |
worldgen/configured_carver/<ID> |
| Configured Feature | #declare worldgen/configured_feature <ID> |
worldgen/configured_feature/<ID> |
| Configured Structure Feature | #declare worldgen/configured_structure_feature <ID> |
worldgen/configured_structure_feature/<ID> |
| Configured Surface Builder | #declare worldgen/configured_surface_builder <ID> |
worldgen/configured_surface_builder/<ID> |
| Dimension | #declare dimension <ID> |
dimension/<ID> |
| Dimension Type | #declare dimension_type <ID> |
dimension_type/<ID> |
| Entity | #declare entity <ID> |
無し |
| Entity Type Tag | #declare tag/entity_type <ID> |
tags/entity_types/<ID> |
| Fluid Tag | #declare tag/fluid <ID> |
tags/fluids/<ID> |
| Function | #declare function <ID> |
functions/<ID> |
| Function Tag | #declare tag/function <ID> |
tags/functions/<ID> |
| Item Tag | #declare tag/item <ID> |
tags/items/<ID> |
| Loot Table | #declare loot_table <ID> |
loot_tables/<ID> |
| Objective | #declare objective <ID> |
scoreboard objectives add <ID> |
| Predicate | #declare predicate <ID> |
predicates/<ID> |
| Processor List | #declare worldgen/processor_list <ID> |
worldgen/processor_list/<ID> |
| Recipe | #declare recipe <ID> |
recipes/<ID> |
| Score Holder | #declare score_holder <ID> |
無し |
| Storage | #declare storage <ID> |
無し |
| Tag | #declare tag <ID> |
無し |
| Team | #declare team <ID> |
team add <ID> |
| Template Pool | #declare worldgen/template_pool <ID> |
worldgen/template_pool/<ID> |
| バージョン | 説明 |
|---|---|
| 1.1.0 |
#defineコメントの追加. |
| 3.0.0 |
#define から #declareに名称を変更#declareのエイリアスとして#defineを追加.全てのリソースタイプを宣言できるように |