All checks were successful
continuous-integration/drone/push Build is passing
55 lines
1.9 KiB
JavaScript
55 lines
1.9 KiB
JavaScript
// {
|
|
// "variants": {
|
|
// "": { "model": "quark:block/vertical_acacia_planks" }
|
|
// }
|
|
// }
|
|
|
|
ClientEvents.lang('en_us', (event) => {
|
|
global.woodTypes.forEach((wood) => {
|
|
if (wood['id'] in global.quarkExistingVerticalPlanks) return;
|
|
|
|
let item_id = 'vertical_' + wood['id'] + '_planks'
|
|
event.add('block.quark.' + item_id, 'Vertical ' + wood['name'] + ' Planks')
|
|
})
|
|
})
|
|
|
|
ClientEvents.highPriorityAssets((event) => {
|
|
global.woodTypes.forEach((wood) => {
|
|
if (wood['id'] in global.quarkExistingVerticalPlanks) return;
|
|
|
|
let item_id = 'vertical_' + wood['id'] + '_planks'
|
|
|
|
let planks_texture = null
|
|
if ('texture' in wood['planks']) {
|
|
planks_texture = ('mod' in wood['planks'] ? wood['planks']['mod'] : wood['mod']) + ':' + wood['planks']['texture']
|
|
} else {
|
|
planks_texture = ('mod' in wood['planks'] ? wood['planks']['mod'] : wood['mod']) + ':block/' + wood['planks']['id']
|
|
}
|
|
|
|
event.addBlockState('quark:' + item_id, (gen) => {
|
|
gen.variant('', (variant) => {
|
|
variant.model('quark:block/' + item_id)
|
|
})
|
|
})
|
|
|
|
event.addModel('block', 'quark:' + item_id, (gen) => {
|
|
gen.parent('quark:block/vertical_planks')
|
|
gen.texture('all', planks_texture)
|
|
})
|
|
|
|
event.addModel('item', 'quark:' + item_id, (gen) => {
|
|
gen.parent('quark:block/' + item_id)
|
|
})
|
|
})
|
|
|
|
// event.addModel('block', 'embellishcraft:' + stair_id, (gen) => {
|
|
// gen.parent('embellishcraft:block/' + (suspendedStair['isLarge'] ? 'large_' : '') + 'suspended_stairs')
|
|
|
|
// gen.texture('all', suspendedStair['texture'])
|
|
// })
|
|
|
|
// event.addModel('item', 'embellishcraft:' + stair_id, (gen) => {
|
|
// gen.parent('embellishcraft:block/' + stair_id)
|
|
// })
|
|
// })
|
|
}) |