Skip to content

Commit

Permalink
Start Antenna
Browse files Browse the repository at this point in the history
+Modify Keyboard recipes
+Start Radio recipes
TODO: Fix waterlogging for it and the KeyboardBlock
  • Loading branch information
Leafenzo committed Jul 30, 2024
1 parent 97a585a commit 9b08e70
Show file tree
Hide file tree
Showing 24 changed files with 284 additions and 46 deletions.
19 changes: 19 additions & 0 deletions src/main/generated/assets/ltones/blockstates/antenna.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"variants": {
"facing=east": {
"model": "ltones:block/antenna",
"y": 90
},
"facing=north": {
"model": "ltones:block/antenna"
},
"facing=south": {
"model": "ltones:block/antenna",
"y": 180
},
"facing=west": {
"model": "ltones:block/antenna",
"y": 270
}
}
}
1 change: 1 addition & 0 deletions src/main/generated/assets/ltones/lang/en_us.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
"block.ltones.amber_nurr": "Amber Nurr",
"block.ltones.amber_tyel": "Amber Tyel",
"block.ltones.amber_zane": "Amber Zane",
"block.ltones.antenna": "Antenna",
"block.ltones.aurora": "Aurora",
"block.ltones.azur": "Azur",
"block.ltones.azur_cript": "Azur Cript",
Expand Down
3 changes: 3 additions & 0 deletions src/main/generated/assets/ltones/models/item/antenna.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"parent": "ltones:block/antenna"
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
},
"trigger": "minecraft:inventory_changed"
},
"has_stone_button": {
"has_diode": {
"conditions": {
"items": [
{
"items": [
"minecraft:stone_button"
"ltones:diode"
]
}
]
Expand All @@ -35,7 +35,7 @@
"requirements": [
[
"has_conductium",
"has_stone_button",
"has_diode",
"has_the_recipe"
]
],
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"parent": "minecraft:recipes/root",
"criteria": {
"has_conductium": {
"conditions": {
"items": [
{
"items": [
"ltones:conductium"
]
}
]
},
"trigger": "minecraft:inventory_changed"
},
"has_the_recipe": {
"conditions": {
"recipe": "ltones:antenna"
},
"trigger": "minecraft:recipe_unlocked"
}
},
"requirements": [
[
"has_conductium",
"has_the_recipe"
]
],
"rewards": {
"recipes": [
"ltones:antenna"
]
},
"sends_telemetry_event": false
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
},
"trigger": "minecraft:inventory_changed"
},
"has_stone_button": {
"has_diode": {
"conditions": {
"items": [
{
"items": [
"minecraft:stone_button"
"ltones:diode"
]
}
]
Expand All @@ -35,7 +35,7 @@
"requirements": [
[
"has_amalgam",
"has_stone_button",
"has_diode",
"has_the_recipe"
]
],
Expand Down
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
{
"parent": "minecraft:recipes/root",
"criteria": {
"has_kerbesium": {
"has_diode": {
"conditions": {
"items": [
{
"items": [
"ltones:kerbesium"
"ltones:diode"
]
}
]
},
"trigger": "minecraft:inventory_changed"
},
"has_stone_button": {
"has_kerbesium": {
"conditions": {
"items": [
{
"items": [
"minecraft:stone_button"
"ltones:kerbesium"
]
}
]
Expand All @@ -35,7 +35,7 @@
"requirements": [
[
"has_kerbesium",
"has_stone_button",
"has_diode",
"has_the_recipe"
]
],
Expand Down
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
{
"parent": "minecraft:recipes/root",
"criteria": {
"has_polymer": {
"has_diode": {
"conditions": {
"items": [
{
"items": [
"ltones:polymer"
"ltones:diode"
]
}
]
},
"trigger": "minecraft:inventory_changed"
},
"has_stone_button": {
"has_polymer": {
"conditions": {
"items": [
{
"items": [
"minecraft:stone_button"
"ltones:polymer"
]
}
]
Expand All @@ -35,7 +35,7 @@
"requirements": [
[
"has_polymer",
"has_stone_button",
"has_diode",
"has_the_recipe"
]
],
Expand Down
20 changes: 20 additions & 0 deletions src/main/generated/data/ltones/loot_tables/blocks/antenna.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"type": "minecraft:block",
"pools": [
{
"bonus_rolls": 0.0,
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [
{
"type": "minecraft:item",
"name": "ltones:antenna"
}
],
"rolls": 1.0
}
]
}
10 changes: 5 additions & 5 deletions src/main/generated/data/ltones/recipes/aged_keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
"category": "building",
"group": "aged_keyboard",
"key": {
"D": {
"item": "ltones:diode"
},
"F": {
"item": "ltones:conductium"
},
"S": {
"item": "minecraft:stone_button"
}
},
"pattern": [
"SS",
"FF"
"DDD",
"FFF"
],
"result": {
"item": "ltones:aged_keyboard"
Expand Down
18 changes: 18 additions & 0 deletions src/main/generated/data/ltones/recipes/antenna.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"type": "minecraft:crafting_shaped",
"category": "building",
"key": {
"#": {
"item": "ltones:conductium"
}
},
"pattern": [
"# #",
" # ",
" # "
],
"result": {
"item": "ltones:antenna"
},
"show_notification": true
}
10 changes: 5 additions & 5 deletions src/main/generated/data/ltones/recipes/black_keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
"category": "building",
"group": "black_keyboard",
"key": {
"D": {
"item": "ltones:diode"
},
"F": {
"item": "ltones:amalgam"
},
"S": {
"item": "minecraft:stone_button"
}
},
"pattern": [
"SS",
"FF"
"DDD",
"FFF"
],
"result": {
"item": "ltones:black_keyboard"
Expand Down
10 changes: 5 additions & 5 deletions src/main/generated/data/ltones/recipes/gray_keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
"category": "building",
"group": "gray_keyboard",
"key": {
"D": {
"item": "ltones:diode"
},
"F": {
"item": "ltones:kerbesium"
},
"S": {
"item": "minecraft:stone_button"
}
},
"pattern": [
"SS",
"FF"
"DDD",
"FFF"
],
"result": {
"item": "ltones:gray_keyboard"
Expand Down
10 changes: 5 additions & 5 deletions src/main/generated/data/ltones/recipes/keyboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
"category": "building",
"group": "keyboard",
"key": {
"D": {
"item": "ltones:diode"
},
"F": {
"item": "ltones:polymer"
},
"S": {
"item": "minecraft:stone_button"
}
},
"pattern": [
"SS",
"FF"
"DDD",
"FFF"
],
"result": {
"item": "ltones:keyboard"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -369,6 +369,22 @@
"ltones:sol_nuclei",
"ltones:sol_corona",
"ltones:sol",
"ltones:mint_bitt",
"ltones:orange_bitt",
"ltones:purple_bitt",
"ltones:light_blue_bitt",
"ltones:lime_bitt",
"ltones:magenta_bitt",
"ltones:fuchsia_bitt",
"ltones:green_bitt",
"ltones:indigo_bitt",
"ltones:amber_bitt",
"ltones:blue_bitt",
"ltones:cyan_bitt",
"ltones:bitt",
"ltones:yellow_bitt",
"ltones:red_bitt",
"ltones:shell_bitt",
"ltones:ztone",
"ltones:raw_lithium_block",
"ltones:lithium_block",
Expand All @@ -390,6 +406,7 @@
"ltones:keyboard",
"ltones:aged_keyboard",
"ltones:black_keyboard",
"ltones:gray_keyboard"
"ltones:gray_keyboard",
"ltones:antenna"
]
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
"ltones:lithium_block",
"ltones:lithium_ore",
"ltones:deepslate_lithium_ore",
"ltones:endstone_lithium_ore"
"ltones:endstone_lithium_ore",
"ltones:antenna"
]
}
4 changes: 3 additions & 1 deletion src/main/java/net/leafenzo/ltones/block/ModBlocks.java
Original file line number Diff line number Diff line change
Expand Up @@ -796,6 +796,8 @@ public class ModBlocks {
public static final Block AGED_KEYBOARD = registerBlock("aged_keyboard", new KeyboardBlock(FabricBlockSettings.copyOf(KEYBOARD).pistonBehavior(PistonBehavior.DESTROY)));
public static final Block BLACK_KEYBOARD = registerBlock("black_keyboard", new KeyboardBlock(FabricBlockSettings.copyOf(KEYBOARD).pistonBehavior(PistonBehavior.DESTROY)));
public static final Block GRAY_KEYBOARD = registerBlock("gray_keyboard", new KeyboardBlock(FabricBlockSettings.copyOf(KEYBOARD).pistonBehavior(PistonBehavior.DESTROY)));
public static final Block ANTENNA = registerBlock("antenna", new AntennaBlock(FabricBlockSettings.create().solid().mapColor(MapColor.CLEAR).strength(3.0f, 6.0f).sounds(BlockSoundGroup.COPPER).nonOpaque().blockVision(ModBlocks::never).allowsSpawning(ModBlocks::never).pistonBehavior(PistonBehavior.DESTROY).requiresTool()));
static { RENDER_LAYER_CUTOUT.add(ANTENNA); }
//</editor-fold>

//<editor-fold desc ="Blocks - Doors">
Expand Down Expand Up @@ -824,7 +826,7 @@ public static Block registerDoor(String name, Block block) {
//</editor-fold>

//<editor-fold desc ="Blocks - Decals">
private static final Block registerDecalBlock(String name, Block block) {
private static Block registerDecalBlock(String name, Block block) {
Block b = registerBlockWithoutBlockItem(name, block);
DECAL_BLOCKS.add(b);
return b;
Expand Down
Loading

0 comments on commit 9b08e70

Please sign in to comment.