169169 <#return (extension?has_content)?then("_" + extension, "") >
170170</#function >
171171
172- <#function mappedMCItemToItemObjectJSON mappedBlock >
172+ <#function mappedMCItemToItemObjectJSON mappedBlock itemKey="item" >
173173 <#if mappedBlock.getUnmappedValue().startsWith("CUSTOM:") >
174174 <#assign customelement = generator.getRegistryNameFromFullName(mappedBlock.getUnmappedValue())!""/ >
175175 <#if customelement?has_content >
176- <#return "\"item \": \"" + "${modid} :" + customelement
176+ <#return "\"" + itemKey + " \": \"" + "${modid} :" + customelement
177177 + transformExtension(mappedBlock)
178178 + "\"">
179179 <#else >
180- <#return "\"item \": \"minecraft:air\"" >
180+ <#return "\"" + itemKey + " \": \"minecraft:air\"" >
181181 </#if >
182182 <#elseif mappedBlock.getUnmappedValue().startsWith("TAG:") >
183183 <#return "\"tag\": \"" + mappedBlock.getUnmappedValue().replace("TAG:", "").replace("mod:", modid + ":")?lower_case + "\"" >
186186 <#if mapped.startsWith("#") >
187187 <#return "\"tag\": \"" + mapped.replace("#", "") + "\"" >
188188 <#elseif mapped.contains(":") >
189- <#return "\"item \": \"" + mapped + "\"" >
189+ <#return "\"" + itemKey + " \": \"" + mapped + "\"" >
190190 <#else >
191- <#return "\"item \": \"minecraft:" + mapped + "\"" >
191+ <#return "\"" + itemKey + " \": \"minecraft:" + mapped + "\"" >
192192 </#if >
193193 </#if >
194194</#function >
318318 <#assign properties += [{"name": "axis", "value": "y"} ] />
319319 </#if >
320320 </#if >
321+ <#list ge.customProperties as prop >
322+ <#assign properties += [{"name": prop.property().getName().replace("CUSTOM:", ""), "value": prop.value()} ] />
323+ </#list >
321324 </#if >
322325 </#if >
323326
356359 </#if >
357360 </#if >
358361 <#return '{ "Name": "minecraft:air" }' >
359- </#function >
362+ </#function >
0 commit comments