|
35 | 35 | } |
36 | 36 | {% else %} |
37 | 37 | {% set prefix = blocks[block]["blockDrop"].split('_')[0] %} |
38 | | - {% set suffix = blocks[block]["blockDrop"].split('_')[1] %} |
| 38 | + {% set suffix = ingredients["9"].split('_')[1:] | join('_') %} |
39 | 39 | {% if (blocks[block]["blockDrop"] not in items) and (blocks[block]["blockDrop"] not in blocks) %} |
40 | 40 | { |
41 | 41 | "pools": [ |
|
90 | 90 | "function": "minecraft:set_components", |
91 | 91 | "components": { |
92 | 92 | "minecraft:item_model": "{{ packNamespace }}:{{ blocks[blocks[block]['blockDrop']]['name'] }}", |
93 | | - "minecraft:custom_name": "{\"italic\": False, \"text\": \"{{ blocks[blocks[block]['blockDrop']]['displayName'] }}\" }", |
| 93 | + "minecraft:custom_name": {"italic": False, "text": "{{ blocks[blocks[block]['blockDrop']]['displayName'] }}" }, |
94 | 94 | "minecraft:entity_data": { |
95 | 95 | "id": "minecraft:item_frame", |
96 | 96 | "Fixed": true, |
|
134 | 134 | "asset_id": "{{ packNamespace }}:{{ prefix }}" |
135 | 135 | }, |
136 | 136 | "minecraft:item_model": "{{ packNamespace }}:{{ prefix }}_{{ suffix }}", |
137 | | - "minecraft:item_name": {"italic":false,"text":"{{ prefix }} {{ suffix }}"}, |
| 137 | + "minecraft:item_name": {"italic":false,"text":"{{ prefix }} {{ suffix.replace('_', ' ').capitalize() }}"}, |
138 | 138 | "minecraft:attribute_modifiers": [ |
139 | 139 | { |
140 | 140 | "id": "armor", |
141 | 141 | "type": "armor", |
142 | 142 | "amount": {{ equipment[prefix]["armor"][suffix] }}, |
143 | | - "operation": "add_value", |
144 | | - "slot": "{{ slot_map[suffix] }}" |
| 143 | + "operation": "add_value"{% if not suffix == "horse_armor" %}, |
| 144 | + "slot": "{{ slot_map[suffix] }}"{% endif %} |
145 | 145 | }, |
146 | 146 | { |
147 | 147 | "id": "armor_toughness", |
148 | 148 | "type": "armor_toughness", |
149 | 149 | "amount": {{ equipment[prefix]["toughness"] }}, |
150 | | - "operation": "add_value", |
151 | | - "slot": "{{ slot_map[suffix] }}" |
| 150 | + "operation": "add_value"{% if not suffix == "horse_armor" %}, |
| 151 | + "slot": "{{ slot_map[suffix] }}"{% endif %} |
152 | 152 | }, |
153 | 153 | { |
154 | 154 | "id": "knockback_resistance", |
155 | 155 | "type": "knockback_resistance", |
156 | 156 | "amount": {{ equipment[prefix]["kb_resistance"] }}, |
157 | | - "operation": "add_value", |
158 | | - "slot": "{{ slot_map[suffix] }}" |
| 157 | + "operation": "add_value"{% if not suffix == "horse_armor" %}, |
| 158 | + "slot": "{{ slot_map[suffix] }}"{% endif %} |
159 | 159 | } |
160 | 160 | ], |
161 | 161 | "minecraft:max_damage": {{ equipment[prefix]["durability"][suffix] }} |
|
0 commit comments