Ok that didn't work
This commit is contained in:
parent
119e0ede61
commit
141eb6e997
@ -4236,11 +4236,6 @@ file = "mods/library-ferret-forge.pw.toml"
|
|||||||
hash = "207ea5c3ad00aee495de4d614c504d443c141068a2ddf0554f5a7829923cfeec"
|
hash = "207ea5c3ad00aee495de4d614c504d443c141068a2ddf0554f5a7829923cfeec"
|
||||||
metafile = true
|
metafile = true
|
||||||
|
|
||||||
[[files]]
|
|
||||||
file = "mods/longer-login-times.pw.toml"
|
|
||||||
hash = "70c75a1ba649ba3a2b7141febc85f748f7c800ac93ed3ef900b1f04a7e6395c2"
|
|
||||||
metafile = true
|
|
||||||
|
|
||||||
[[files]]
|
[[files]]
|
||||||
file = "mods/loot-beams.pw.toml"
|
file = "mods/loot-beams.pw.toml"
|
||||||
hash = "154db7b13596de00401df478f001ad5f476ee01fbd00809617359119275c6412"
|
hash = "154db7b13596de00401df478f001ad5f476ee01fbd00809617359119275c6412"
|
||||||
|
|||||||
@ -2,16 +2,8 @@ BlockEvents.rightClicked('ags_day_counter:calendar', event => {
|
|||||||
if (event.hand != 'off_hand') return;
|
if (event.hand != 'off_hand') return;
|
||||||
|
|
||||||
let playTime = Math.round(event.player.stats.get(Stats.PLAY_TIME) / 24000.0)
|
let playTime = Math.round(event.player.stats.get(Stats.PLAY_TIME) / 24000.0)
|
||||||
let hordeDay = 15 - (playTime % 15);
|
|
||||||
let serverDays = parseInt(event.level.dayTime() / 24000.0);
|
let serverDays = parseInt(event.level.dayTime() / 24000.0);
|
||||||
event.player.tell(Component.of('Today is day ').append(Component.green(serverDays)).append('.'))
|
event.player.tell(Component.of('Today is day ').append(Component.green(serverDays)).append('.'))
|
||||||
event.player.tell(Component.of('You have played ').append(Component.green(playTime)).append(' in-game days.'))
|
event.player.tell(Component.of('You have played ').append(Component.green(playTime)).append(' in-game days.'))
|
||||||
if (hordeDay == 15) {
|
|
||||||
hordeDay = 0;
|
|
||||||
event.player.tell(Component.of('The next horde wave is coming in ').append(Component.red(hordeDay)).append(' days.'))
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
event.player.tell(Component.of('The next horde wave is coming in ').append(Component.yellow(hordeDay)).append(' days.'))
|
|
||||||
}
|
|
||||||
return
|
return
|
||||||
});
|
});
|
||||||
@ -3,46 +3,46 @@ ServerEvents.recipes((event) => {
|
|||||||
let planks_item = ('mod' in wood['planks'] ? wood['planks']['mod'] : wood['mod']) + ':' + wood['planks']['id']
|
let planks_item = ('mod' in wood['planks'] ? wood['planks']['mod'] : wood['mod']) + ':' + wood['planks']['id']
|
||||||
let item_id = 'quark:vertical_' + wood['id'] + '_planks'
|
let item_id = 'quark:vertical_' + wood['id'] + '_planks'
|
||||||
|
|
||||||
if (!(wood['id'] in global.quarkExistingVerticalPlanks)) {
|
// if (!(wood['id'] in global.quarkExistingVerticalPlanks)) {
|
||||||
event.shaped(
|
// event.shaped(
|
||||||
Item.of(item_id, 1),
|
// Item.of(item_id, 1),
|
||||||
[
|
// [
|
||||||
'P ',
|
// 'P ',
|
||||||
'P ',
|
// 'P ',
|
||||||
'P '
|
// 'P '
|
||||||
],
|
// ],
|
||||||
{
|
// {
|
||||||
'P': { 'item': wood['planks']['id'] }
|
// 'P': { 'item': planks_item }
|
||||||
}
|
// }
|
||||||
).id(item_id)
|
// ).id(item_id)
|
||||||
}
|
// }
|
||||||
|
|
||||||
if (!(wood['mod'] in ['minecraft', 'twilightforest'])) {
|
// if (!(wood['mod'] in ['minecraft', 'twilightforest'])) {
|
||||||
event.shaped(
|
// event.shaped(
|
||||||
'minecraft:chest',
|
// 'minecraft:chest',
|
||||||
[
|
// [
|
||||||
'PPP',
|
// 'PPP',
|
||||||
'P P',
|
// 'P P',
|
||||||
'PPP'
|
// 'PPP'
|
||||||
],
|
// ],
|
||||||
{
|
// {
|
||||||
'P': { 'item': wood['planks']['id'] }
|
// 'P': { 'item': planks_item }
|
||||||
}
|
// }
|
||||||
)
|
// )
|
||||||
|
|
||||||
event.shaped(
|
// event.shaped(
|
||||||
'minecraft:ladder',
|
// 'minecraft:ladder',
|
||||||
[
|
// [
|
||||||
'S S',
|
// 'S S',
|
||||||
'SPS',
|
// 'SPS',
|
||||||
'S S'
|
// 'S S'
|
||||||
],
|
// ],
|
||||||
{
|
// {
|
||||||
'P': planks_item,
|
// 'P': planks_item,
|
||||||
'S': { 'tag': 'forge:rods/wooden' }
|
// 'S': { 'tag': 'forge:rods/wooden' }
|
||||||
}
|
// }
|
||||||
)
|
// )
|
||||||
}
|
// }
|
||||||
|
|
||||||
if (Platform.isLoaded('create')) {
|
if (Platform.isLoaded('create')) {
|
||||||
event.custom({
|
event.custom({
|
||||||
@ -53,7 +53,7 @@ ServerEvents.recipes((event) => {
|
|||||||
'results': [
|
'results': [
|
||||||
{
|
{
|
||||||
'item': item_id,
|
'item': item_id,
|
||||||
'count': 1
|
'count': 2
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
'processingTime': 50
|
'processingTime': 50
|
||||||
|
|||||||
16
kubejs/server_scripts/skapa.js
Normal file
16
kubejs/server_scripts/skapa.js
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
ServerEvents.recipes((event) => {
|
||||||
|
event
|
||||||
|
.shaped(
|
||||||
|
Item.of('skapa:sturdy_metal_block', 1),
|
||||||
|
[
|
||||||
|
'DID',
|
||||||
|
'IBI',
|
||||||
|
'DID'
|
||||||
|
],
|
||||||
|
{
|
||||||
|
'B': { 'item': 'minecraft:iron_block' },
|
||||||
|
'I': { 'tag': 'forge:ingots/iron' },
|
||||||
|
'D': { 'item': 'minecraft:black_dye' }
|
||||||
|
}
|
||||||
|
)
|
||||||
|
})
|
||||||
@ -1,22 +1,32 @@
|
|||||||
// priority: 100000000
|
// priority: 100000000
|
||||||
|
|
||||||
const $BlockItem = Java.loadClass('net.minecraft.world.item.BlockItem')
|
// const $Boat = Java.loadClass('net.minecraft.world.entity.vehicle.Boat');
|
||||||
const $Block = Java.loadClass('net.minecraft.world.level.block.Block')
|
// const $BoatItem = Java.loadClass('net.minecraft.world.item.BoatItem');
|
||||||
const $Blocks = Java.loadClass('net.minecraft.world.level.block.Blocks')
|
const $BlockItem = Java.loadClass('net.minecraft.world.item.BlockItem');
|
||||||
|
const $Block = Java.loadClass('net.minecraft.world.level.block.Block');
|
||||||
|
const $Blocks = Java.loadClass('net.minecraft.world.level.block.Blocks');
|
||||||
const $BlockSetType = Java.loadClass('net.minecraft.world.level.block.state.properties.BlockSetType');
|
const $BlockSetType = Java.loadClass('net.minecraft.world.level.block.state.properties.BlockSetType');
|
||||||
const $BlockStandardDrawers = Java.loadClass('com.jaquadro.minecraft.storagedrawers.block.BlockStandardDrawers')
|
const $BlockStandardDrawers = Java.loadClass('com.jaquadro.minecraft.storagedrawers.block.BlockStandardDrawers');
|
||||||
const $BlockTrim = Java.loadClass('com.jaquadro.minecraft.storagedrawers.block.BlockTrim')
|
const $BlockTrim = Java.loadClass('com.jaquadro.minecraft.storagedrawers.block.BlockTrim');
|
||||||
const $DoorBlock = Java.loadClass('net.minecraft.world.level.block.DoorBlock')
|
const $DoorBlock = Java.loadClass('net.minecraft.world.level.block.DoorBlock');
|
||||||
const $Fluids = Java.loadClass("net.minecraft.world.level.material.Fluids")
|
const $Fluids = Java.loadClass("net.minecraft.world.level.material.Fluids");
|
||||||
const $ItemDrawers = Java.loadClass('com.jaquadro.minecraft.storagedrawers.item.ItemDrawers')
|
const $ItemDrawers = Java.loadClass('com.jaquadro.minecraft.storagedrawers.item.ItemDrawers');
|
||||||
const $IProperties = Java.loadClass('net.minecraft.world.item.Item$Properties')
|
const $IProperties = Java.loadClass('net.minecraft.world.item.Item$Properties');
|
||||||
const $MetalLadderBlock = Java.loadClass('com.simibubi.create.content.decoration.MetalLadderBlock')
|
const $MetalLadderBlock = Java.loadClass('com.simibubi.create.content.decoration.MetalLadderBlock');
|
||||||
const $Properties = Java.loadClass('net.minecraft.world.level.block.state.BlockBehaviour$Properties')
|
const $Properties = Java.loadClass('net.minecraft.world.level.block.state.BlockBehaviour$Properties');
|
||||||
const $RecipeSchema = Java.loadClass('dev.latvian.mods.kubejs.recipe.schema.RecipeSchema');
|
const $RecipeSchema = Java.loadClass('dev.latvian.mods.kubejs.recipe.schema.RecipeSchema');
|
||||||
const $NoteBlockInstrument = Java.loadClass('net.minecraft.world.level.block.state.properties.NoteBlockInstrument')
|
const $NoteBlockInstrument = Java.loadClass('net.minecraft.world.level.block.state.properties.NoteBlockInstrument');
|
||||||
const $RotatedPillarBlock = Java.loadClass('net.minecraft.world.level.block.RotatedPillarBlock')
|
const $RotatedPillarBlock = Java.loadClass('net.minecraft.world.level.block.RotatedPillarBlock');
|
||||||
|
const $SignBlock = Java.loadClass('net.minecraft.world.level.block.SignBlock');
|
||||||
const $SoundType = Java.loadClass('net.minecraft.world.level.block.SoundType');
|
const $SoundType = Java.loadClass('net.minecraft.world.level.block.SoundType');
|
||||||
const $SoundEvents = Java.loadClass('net.minecraft.sounds.SoundEvents');
|
const $SoundEvents = Java.loadClass('net.minecraft.sounds.SoundEvents');
|
||||||
|
const $TrapdoorBlock = Java.loadClass('net.minecraft.world.level.block.TrapDoorBlock');
|
||||||
|
const $WoodType = Java.loadClass('net.minecraft.world.level.block.state.properties.WoodType');
|
||||||
|
|
||||||
|
const $Moonlight = {
|
||||||
|
'BlockSetAPI': Java.loadClass('net.mehvahdjukaar.moonlight.api.set.BlockSetAPI'),
|
||||||
|
'WoodType': Java.loadClass('net.mehvahdjukaar.moonlight.api.set.wood.WoodType')
|
||||||
|
}
|
||||||
|
|
||||||
global.woodTypes = [
|
global.woodTypes = [
|
||||||
{ 'id': 'acacia', 'name': 'Acacia', 'mod': 'minecraft', 'planks': { 'id': 'acacia_planks' } },
|
{ 'id': 'acacia', 'name': 'Acacia', 'mod': 'minecraft', 'planks': { 'id': 'acacia_planks' } },
|
||||||
|
|||||||
@ -1,11 +1,16 @@
|
|||||||
const createDdWoodTypes = [
|
const createDD = {
|
||||||
{ 'id': 'rose', 'name': 'Rose', 'mapColor': 'terracotta_red' },
|
'blocks': {},
|
||||||
{ 'id': 'rubber', 'name': 'Rubber', 'mapColor': 'terracotta_cyan' },
|
'items': {},
|
||||||
{ 'id': 'spirit', 'name': 'Spirit', 'mapColor': 'terracotta_purple' },
|
'blockSetTypes': {},
|
||||||
{ 'id': 'smoked', 'name': 'Smoked', 'mapColor': 'terracotta_brown' }
|
'woodTypes': [
|
||||||
]
|
{ 'id': 'rose', 'name': 'Rose', 'mapColor': 'terracotta_red', 'woodType': $WoodType.MANGROVE, /* 'boatType': $Boat.Type.MANGROVE */ },
|
||||||
|
{ 'id': 'rubber', 'name': 'Rubber', 'mapColor': 'terracotta_cyan', 'woodType': $WoodType.ACACIA, /* 'boatType': $Boat.Type.ACACIA */ },
|
||||||
|
{ 'id': 'spirit', 'name': 'Spirit', 'mapColor': 'terracotta_purple', 'woodType': $WoodType.WARPED, /* 'boatType': $Boat.Type.WARPED */ },
|
||||||
|
{ 'id': 'smoked', 'name': 'Smoked', 'mapColor': 'terracotta_brown', 'woodType': $WoodType.SPRUCE, /* 'boatType': $Boat.Type.SPRUCE */ }
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
createDdWoodTypes.forEach((wood) => {
|
createDD.woodTypes.forEach((wood) => {
|
||||||
global.woodTypes.push({
|
global.woodTypes.push({
|
||||||
'id': wood['id'],
|
'id': wood['id'],
|
||||||
'name': wood['name'],
|
'name': wood['name'],
|
||||||
@ -14,51 +19,58 @@ createDdWoodTypes.forEach((wood) => {
|
|||||||
'id': wood['id'] + '_planks'
|
'id': wood['id'] + '_planks'
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
// public static final Supplier<BlockSetType> SPIRIT_SET_TYPE =
|
||||||
|
// () -> new BlockSetType("spirit", true, SoundType.WOOD, SoundEvents.WOODEN_DOOR_CLOSE,
|
||||||
|
// SoundEvents.WOODEN_DOOR_OPEN, SoundEvents.WOODEN_TRAPDOOR_CLOSE, SoundEvents.WOODEN_TRAPDOOR_OPEN,
|
||||||
|
// SoundEvents.WOODEN_PRESSURE_PLATE_CLICK_OFF, SoundEvents.WOODEN_PRESSURE_PLATE_CLICK_ON,
|
||||||
|
// SoundEvents.WOODEN_BUTTON_CLICK_OFF, SoundEvents.WOODEN_BUTTON_CLICK_ON);
|
||||||
|
createDD.blockSetTypes[wood['id']] = new $BlockSetType(
|
||||||
|
wood['id'],
|
||||||
|
true,
|
||||||
|
$SoundType.WOOD,
|
||||||
|
$SoundEvents.WOODEN_DOOR_CLOSE,
|
||||||
|
$SoundEvents.WOODEN_DOOR_OPEN,
|
||||||
|
$SoundEvents.WOODEN_TRAPDOOR_CLOSE,
|
||||||
|
$SoundEvents.WOODEN_TRAPDOOR_OPEN,
|
||||||
|
$SoundEvents.WOODEN_PRESSURE_PLATE_CLICK_OFF,
|
||||||
|
$SoundEvents.WOODEN_PRESSURE_PLATE_CLICK_ON,
|
||||||
|
$SoundEvents.WOODEN_BUTTON_CLICK_OFF,
|
||||||
|
$SoundEvents.WOODEN_BUTTON_CLICK_ON
|
||||||
|
)
|
||||||
|
|
||||||
|
$Moonlight.BlockSetAPI.addBlockTypeFinder(
|
||||||
|
$Moonlight.WoodType.class,
|
||||||
|
$Moonlight.WoodType.Finder.simple('create_dd', wood['id'], wood['id'] + '_planks', wood['id'] + '_log')
|
||||||
|
)
|
||||||
})
|
})
|
||||||
|
|
||||||
// const createDdWoodItems = [
|
|
||||||
// // { 'id': 'boat', 'name': 'Boat', 'cls': '' },
|
|
||||||
// { 'id': 'button', 'name': 'Button', 'cls': 'ButtonBlock' , 'base': () => { return $Blocks.OAK_BUTTON } },
|
|
||||||
// { 'id': 'door', 'name': 'Door', 'cls': 'DoorBlock' , 'base': () => { return $Blocks.OAK_DOOR } },
|
|
||||||
// { 'id': 'fence', 'name': 'Fence', 'cls': 'FenceBlock' , 'base': () => { return $Blocks.OAK_FENCE } },
|
|
||||||
// { 'id': 'fence_gate', 'name': 'Fence Gate', 'cls': 'FenceGateBlock' , 'base': () => { return $Blocks.OAK_FENCE_GATE } },
|
|
||||||
// { 'id': 'log', 'name': 'Log', 'cls': 'RotatedPillarBlock' , 'base': () => { return $Blocks.OAK_LOG } },
|
|
||||||
// { 'id': 'planks', 'name': 'Planks', 'cls': 'Block' , 'base': () => { return $Blocks.OAK_PLANKS } },
|
|
||||||
// { 'id': 'pressure_plate', 'name': 'Pressure Plate', 'cls': 'PressurePlateBlock' , 'base': () => { return $Blocks.OAK_PRESSURE_PLATE } },
|
|
||||||
// { 'id': 'sign', 'name': 'Sign', 'cls': 'SignBlock' , 'base': () => { return $Blocks.OAK_SIGN } },
|
|
||||||
// { 'id': 'slab', 'name': 'Slab', 'cls': 'SlabBlock' , 'base': () => { return $Blocks.OAK_SLAB } },
|
|
||||||
// { 'id': 'stairs', 'name': 'Stairs', 'cls': 'StairBlock' , 'base': () => { return $Blocks.OAK_STAIRS } },
|
|
||||||
// { 'id': 'trapdoor', 'name': 'Trapdoor', 'cls': 'TrapDoorBlock' , 'base': () => { return $Blocks.OAK_TRAPDOOR } },
|
|
||||||
// { 'id': 'wood', 'name': 'Wood', 'cls': 'RotatedPillarBlock' , 'base': () => { return $Blocks.OAK_WOOD } }
|
|
||||||
// ]
|
|
||||||
|
|
||||||
let createDdBlocks = {}
|
|
||||||
let createDdItems = {}
|
|
||||||
let createDdWoodsets = {}
|
|
||||||
|
|
||||||
// createDdWoodTypes.forEach((wood) => {
|
|
||||||
// // public static final Supplier<BlockSetType> SPIRIT_SET_TYPE =
|
|
||||||
// // () -> new BlockSetType("spirit", true, SoundType.WOOD, SoundEvents.WOODEN_DOOR_CLOSE,
|
|
||||||
// // SoundEvents.WOODEN_DOOR_OPEN, SoundEvents.WOODEN_TRAPDOOR_CLOSE, SoundEvents.WOODEN_TRAPDOOR_OPEN,
|
|
||||||
// // SoundEvents.WOODEN_PRESSURE_PLATE_CLICK_OFF, SoundEvents.WOODEN_PRESSURE_PLATE_CLICK_ON,
|
|
||||||
// // SoundEvents.WOODEN_BUTTON_CLICK_OFF, SoundEvents.WOODEN_BUTTON_CLICK_ON);
|
|
||||||
// createDdWoodsets = new $BlockSetType(wood['id'], $SoundType.WOOD, $SoundEvents.WOODEN_DOOR_CLOSE,
|
|
||||||
// $SoundEvents.WOODEN_DOOR_OPEN, $SoundEvents.WOODEN_TRAPDOOR_CLOSE, $SoundEvents.WOODEN_TRAPDOOR_OPEN,
|
|
||||||
// $SoundEvents.WOODEN_PRESSURE_PLATE_CLICK_OFF, $SoundEvents.WOODEN_PRESSURE_PLATE_CLICK_ON,
|
|
||||||
// $SoundEvents.WOODEN_BUTTON_CLICK_OFF, $SoundEvents.WOODEN_BUTTON_CLICK_ON)
|
|
||||||
// })
|
|
||||||
|
|
||||||
// TODO: Make them flammable
|
// TODO: Make them flammable
|
||||||
// TODO: Map colors
|
// TODO: Map colors
|
||||||
StartupEvents.registry('block', (event) => {
|
StartupEvents.registry('block', (event) => {
|
||||||
createDdWoodTypes.forEach((wood) => {
|
createDdWoodTypes.forEach((wood) => {
|
||||||
let item_id = null
|
let item_id = null
|
||||||
|
|
||||||
// Boat
|
|
||||||
// Button
|
// Button
|
||||||
|
item_id = 'create_dd:' + wood['id'] + '_button'
|
||||||
|
createDdBlocks[item_id] = event.create(item_id, 'button')
|
||||||
|
.behavior(createDdBlockSetTypes[item_id])
|
||||||
// Door
|
// Door
|
||||||
|
item_id = 'create_dd:' + wood['id'] + '_door'
|
||||||
|
createDdBlocks[item_id] = event.createCustom(
|
||||||
|
item_id,
|
||||||
|
() => new $DoorBlock(
|
||||||
|
$Properties.copy($Blocks.OAK_DOOR),
|
||||||
|
createDdBlockSetTypes[wood['id']]
|
||||||
|
)
|
||||||
|
)
|
||||||
// Fence
|
// Fence
|
||||||
|
item_id = 'create_dd:' + wood['id'] + '_fence'
|
||||||
|
createDdBlocks[item_id] = event.create(item_id, 'fence')
|
||||||
// Fence Gate
|
// Fence Gate
|
||||||
|
item_id = 'create_dd:' + wood['id'] + '_fence_gate'
|
||||||
|
createDdBlocks[item_id] = event.create(item_id, 'fence_gate')
|
||||||
|
.behavior(wood['woodType'])
|
||||||
// Log
|
// Log
|
||||||
item_id = 'create_dd:' + wood['id'] + '_log'
|
item_id = 'create_dd:' + wood['id'] + '_log'
|
||||||
createDdBlocks[item_id] = event.createCustom(item_id, () => new $RotatedPillarBlock($Properties.copy($Blocks.OAK_LOG)))
|
createDdBlocks[item_id] = event.createCustom(item_id, () => new $RotatedPillarBlock($Properties.copy($Blocks.OAK_LOG)))
|
||||||
@ -66,18 +78,33 @@ StartupEvents.registry('block', (event) => {
|
|||||||
item_id = 'create_dd:' + wood['id'] + '_planks'
|
item_id = 'create_dd:' + wood['id'] + '_planks'
|
||||||
createDdBlocks[item_id] = event.createCustom(item_id, () => new $Block($Properties.copy($Blocks.OAK_PLANKS)))
|
createDdBlocks[item_id] = event.createCustom(item_id, () => new $Block($Properties.copy($Blocks.OAK_PLANKS)))
|
||||||
// Pressure Plate
|
// Pressure Plate
|
||||||
|
item_id = 'create_dd:' + wood['id'] + '_pressure_plate'
|
||||||
|
createDdBlocks[item_id] = event.create(item_id, 'pressure_plate')
|
||||||
|
.behavior(createDdBlockSetTypes[item_id])
|
||||||
// Sign
|
// Sign
|
||||||
|
item_id = 'create_dd:' + wood['id'] + '_sign'
|
||||||
|
createDdBlocks[item_id] = event.createCustom(item_id, () => new $SignBlock($Properties.copy($Blocks.OAK_SIGN), wood['woodType']))
|
||||||
// Slab
|
// Slab
|
||||||
item_id = 'create_dd:' + wood['id'] + '_slab'
|
item_id = 'create_dd:' + wood['id'] + '_slab'
|
||||||
createDdBlocks[item_id] = event.create(item_id, 'slab')
|
createDdBlocks[item_id] = event.create(item_id, 'slab')
|
||||||
// Stairs
|
// Stairs
|
||||||
|
item_id = 'create_dd:' + wood['id'] + '_stairs'
|
||||||
|
createDdBlocks[item_id] = event.create(item_id, 'stairs')
|
||||||
// Stripped Log
|
// Stripped Log
|
||||||
item_id = 'create_dd:stripped_' + wood['id'] + '_log'
|
item_id = 'create_dd:stripped_' + wood['id'] + '_log'
|
||||||
createDdBlocks[item_id] = event.createCustom(item_id, () => new $RotatedPillarBlock($Properties.copy($Blocks.OAK_LOG)))
|
createDdBlocks[item_id] = event.createCustom(item_id, () => new $RotatedPillarBlock($Properties.copy($Blocks.OAK_LOG)))
|
||||||
// StrippedWood
|
// Stripped Wood
|
||||||
item_id = 'create_dd:stripped_' + wood['id'] + '_wood'
|
item_id = 'create_dd:stripped_' + wood['id'] + '_wood'
|
||||||
createDdBlocks[item_id] = event.createCustom(item_id, () => new $RotatedPillarBlock($Properties.copy($Blocks.OAK_WOOD)))
|
createDdBlocks[item_id] = event.createCustom(item_id, () => new $RotatedPillarBlock($Properties.copy($Blocks.OAK_WOOD)))
|
||||||
// Trapdoor
|
// Trapdoor
|
||||||
|
item_id = 'create_dd:' + wood['id'] + '_door'
|
||||||
|
createDdBlocks[item_id] = event.createCustom(
|
||||||
|
item_id,
|
||||||
|
() => new $TrapDoorBlock(
|
||||||
|
$Properties.copy($Blocks.OAK_TRAPDOOR),
|
||||||
|
createDdBlockSetTypes[wood['id']]
|
||||||
|
)
|
||||||
|
)
|
||||||
// Wood
|
// Wood
|
||||||
item_id = 'create_dd:' + wood['id'] + '_wood'
|
item_id = 'create_dd:' + wood['id'] + '_wood'
|
||||||
createDdBlocks[item_id] = event.createCustom(item_id, () => new $RotatedPillarBlock($Properties.copy($Blocks.OAK_WOOD)))
|
createDdBlocks[item_id] = event.createCustom(item_id, () => new $RotatedPillarBlock($Properties.copy($Blocks.OAK_WOOD)))
|
||||||
@ -85,16 +112,32 @@ StartupEvents.registry('block', (event) => {
|
|||||||
})
|
})
|
||||||
})
|
})
|
||||||
|
|
||||||
StartupEvents.registry('item', event => {
|
// StartupEvents.registry('entity_type', event => {
|
||||||
createDdWoodTypes.forEach((wood) => {
|
// createDdWoodTypes.forEach((wood) => {
|
||||||
['log', 'planks', 'wood'].forEach((type) => {
|
// // Boat
|
||||||
let item_id = 'create_dd:' + wood['id'] + '_' + type
|
// event.create('create_dd:' + wood['id'] + '_boat', 'minecraft:boat')
|
||||||
|
// })
|
||||||
|
// })
|
||||||
|
|
||||||
if (item_id in createDdBlocks) {
|
StartupEvents.registry('item', event => {
|
||||||
createDdItems[item_id] = event.createCustom(item_id, () => new $BlockItem(createDdBlocks[item_id].get(), new $IProperties()))
|
Object.keys(createDdBlocks).forEach((block_id) => {
|
||||||
} else {
|
createDdItems[block_id] = event.createCustom(block_id, () => new $BlockItem(createDdBlocks[block_id].get(), new $Properties()))
|
||||||
console.log('Not creating item for ' + item_id + ' as block doesn\'t exist')
|
|
||||||
}
|
|
||||||
})
|
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
||||||
|
// createDdWoodTypes.forEach((wood) => {
|
||||||
|
// // Boat
|
||||||
|
// // public static final RegistryObject<Item> PEWEN_BOAT = DEF_REG.register(
|
||||||
|
// // "pewen_boat",
|
||||||
|
// // () -> new CaveBoatItem(false, AlexsCavesBoat.Type.PEWEN, new Item.Properties().stacksTo(1)));
|
||||||
|
// ['false', 'true'].forEach((hasChest) => {
|
||||||
|
// event.createCustom('create_dd:' + wood['id'] + (hasChest ? '_chest' : '') + '_boat', () => new $BoatItem(
|
||||||
|
// hasChest,
|
||||||
|
|
||||||
|
// ))
|
||||||
|
// })
|
||||||
|
// // public static final RegistryObject<Item> PEWEN_CHEST_BOAT = DEF_REG.register(
|
||||||
|
// // "pewen_chest_boat",
|
||||||
|
// // () -> new CaveBoatItem(true, AlexsCavesBoat.Type.PEWEN, new Item.Properties().stacksTo(1)));
|
||||||
|
// })
|
||||||
})
|
})
|
||||||
@ -30,16 +30,6 @@ ItemEvents.modification(event => {
|
|||||||
let stock = nbt.getDouble('tagStock') * 10.0
|
let stock = nbt.getDouble('tagStock') * 10.0
|
||||||
let amount = fluid.getAmount()
|
let amount = fluid.getAmount()
|
||||||
|
|
||||||
if (fluid.hasTag(`create_sa:jetpack_fuel`) && tank['type'] == 'fuel') {
|
|
||||||
// TODO: Strong and weak fuels
|
|
||||||
|
|
||||||
/* if (fluid.hasTag(`create_sa:weak_jetpack_fuel`)) {
|
|
||||||
amount /= 2
|
|
||||||
} else if (fluid.hasTag(`create_sa:strong_jetpack_fuel`)) {
|
|
||||||
amount *= 2
|
|
||||||
} */
|
|
||||||
}
|
|
||||||
|
|
||||||
let filled = Math.min(amount, tank['capacity'] - stock)
|
let filled = Math.min(amount, tank['capacity'] - stock)
|
||||||
if (!simulate) {
|
if (!simulate) {
|
||||||
nbt.putDouble('tagStock', (stock + filled) / 10.0)
|
nbt.putDouble('tagStock', (stock + filled) / 10.0)
|
||||||
|
|||||||
@ -15,21 +15,21 @@ global.quarkExistingVerticalPlanks = [
|
|||||||
global.verticalPlanks = {}
|
global.verticalPlanks = {}
|
||||||
|
|
||||||
if (Platform.isLoaded('quark')) {
|
if (Platform.isLoaded('quark')) {
|
||||||
StartupEvents.registry('block', event => {
|
// StartupEvents.registry('block', event => {
|
||||||
global.woodTypes.forEach((wood) => {
|
// global.woodTypes.forEach((wood) => {
|
||||||
if (wood['id'] in global.quarkExistingVerticalPlanks) return;
|
// if (wood['id'] in global.quarkExistingVerticalPlanks) return;
|
||||||
|
|
||||||
let item_id = 'quark:vertical_' + wood['id'] + '_planks'
|
// let item_id = 'quark:vertical_' + wood['id'] + '_planks'
|
||||||
global.verticalPlanks[item_id] = event.createCustom(item_id, () => new $Block($Properties.copy($Blocks.OAK_PLANKS)))
|
// global.verticalPlanks[item_id] = event.createCustom(item_id, () => new $Block($Properties.copy($Blocks.OAK_PLANKS)))
|
||||||
})
|
// })
|
||||||
})
|
// })
|
||||||
|
|
||||||
StartupEvents.registry('item', event => {
|
// StartupEvents.registry('item', event => {
|
||||||
global.woodTypes.forEach((wood) => {
|
// global.woodTypes.forEach((wood) => {
|
||||||
if (wood['id'] in global.quarkExistingVerticalPlanks) return;
|
// if (wood['id'] in global.quarkExistingVerticalPlanks) return;
|
||||||
|
|
||||||
let item_id = 'quark:vertical_' + wood['id'] + '_planks'
|
// let item_id = 'quark:vertical_' + wood['id'] + '_planks'
|
||||||
event.createCustom(item_id, () => new $BlockItem(global.verticalPlanks[item_id].get(), new $IProperties()))
|
// event.createCustom(item_id, () => new $BlockItem(global.verticalPlanks[item_id].get(), new $IProperties()))
|
||||||
})
|
// })
|
||||||
})
|
// })
|
||||||
}
|
}
|
||||||
11
kubejs/startup_scripts/skapa.js
Normal file
11
kubejs/startup_scripts/skapa.js
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
StartupEvents.registry('block', (event) => {
|
||||||
|
event.create('skapa:sturdy_metal_block')
|
||||||
|
.displayName('Sturdy Metal Block')
|
||||||
|
.hardness(30.0)
|
||||||
|
.soundType('anvil')
|
||||||
|
.tagBlock('minecraft:mineable/pickaxe')
|
||||||
|
.tagBlock('minecraft:needs_iron_tool')
|
||||||
|
.requiresTool(true)
|
||||||
|
.lightLevel(0)
|
||||||
|
.textureAll('minecraft:block/smithing_table_top')
|
||||||
|
})
|
||||||
@ -1,17 +0,0 @@
|
|||||||
name = "Longer Login Times"
|
|
||||||
filename = "longerlogintimes-1.0.0-forge-mc1.20.jar"
|
|
||||||
side = "both"
|
|
||||||
|
|
||||||
[option]
|
|
||||||
optional = true
|
|
||||||
default = false
|
|
||||||
|
|
||||||
[download]
|
|
||||||
hash-format = "sha1"
|
|
||||||
hash = "708e7f8f1dc2955c0331b5fb028fa97720762df3"
|
|
||||||
mode = "metadata:curseforge"
|
|
||||||
|
|
||||||
[update]
|
|
||||||
[update.curseforge]
|
|
||||||
file-id = 4594800
|
|
||||||
project-id = 566374
|
|
||||||
@ -6,7 +6,7 @@ pack-format = "packwiz:1.1.0"
|
|||||||
[index]
|
[index]
|
||||||
file = "index.toml"
|
file = "index.toml"
|
||||||
hash-format = "sha256"
|
hash-format = "sha256"
|
||||||
hash = "cbb1a03d362084558376b1ec41cb4889b85188d844453abdbd6cf7edaecd9258"
|
hash = "9e0b667ef73f388812e66a4cd50582e47f048f5fdee910bb051cacfa61140ef2"
|
||||||
|
|
||||||
[versions]
|
[versions]
|
||||||
forge = "47.3.5"
|
forge = "47.3.5"
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user