Switch it up

- Added tripwire to #movable_empty_collider
- Netherite armor can now be upgraded to Netherite diving gear
- Stockpile Switch -> Threshold Switch
- Content Observer -> Smart Observer
- Smart observer and threshold switch can now be oriented to face blocks above or below them
- Smart observer will now also emit redstone when the block in front of it matches its filter
- Gui touch-ups
This commit is contained in:
simibubi 2023-04-29 15:53:07 +02:00
parent e0fcc96bb2
commit 1b54827feb
114 changed files with 1208 additions and 594 deletions

View file

@ -55,7 +55,7 @@ d01a750e6e8214ca8481e40aa69cedeb5c7210f8 assets/create/blockstates/cart_assemble
4947c261310445fa55b92038326ac82967d192dd assets/create/blockstates/clockwork_bearing.json
1f33834c685e3243882acfe20183fe64dfa872be assets/create/blockstates/clutch.json
e5e3757e99c139d67b2a70288466d8a74d818841 assets/create/blockstates/cogwheel.json
36f54136a7756c97f71bc6b47ef4e8e575e72879 assets/create/blockstates/content_observer.json
e4efa0811219796fedb9277151a4d99831688914 assets/create/blockstates/content_observer.json
7ecbf72c0557d97514aadc5a794bd8720c2fc48b assets/create/blockstates/contraption_controls.json
7d11142092c89ccba3e74e0a3bdd0ccb446d63b5 assets/create/blockstates/controller_rail.json
80d71365995d4c2a61dd1c15e99cae18551af6e8 assets/create/blockstates/controls.json
@ -513,7 +513,7 @@ d62b7908119fa4f51715a186d0882b388bb25cab assets/create/blockstates/spruce_window
442d959d019088d9dbe04c530f5fcabbbb65819f assets/create/blockstates/steam_whistle_extension.json
5d7385d28a23dcfc95a221d36d82337908582726 assets/create/blockstates/sticker.json
3d93eabbb327aecc526beae9c62283f1d43eb710 assets/create/blockstates/sticky_mechanical_piston.json
f385988cb6fa9c48b5d59a6942ec50ed2b60c8bf assets/create/blockstates/stockpile_switch.json
4a007c7e2ac1dac5e838c86a46dd3dbdedb1a607 assets/create/blockstates/stockpile_switch.json
e815bfd854c2653f10828bb11950f7fb991d7efc assets/create/blockstates/stressometer.json
8b0c2c7ac72529565b3339aa8df7565858100afa assets/create/blockstates/tiled_glass.json
a2454400b1cf9889f70aebdc89c52a1be25f543c assets/create/blockstates/tiled_glass_pane.json
@ -578,8 +578,8 @@ bf2b0310500213ff853c748c236eb5d01f61658e assets/create/blockstates/yellow_toolbo
5616dda664dd106d576848124fc0fc1de18d0fd3 assets/create/blockstates/yellow_valve_handle.json
7f39521b211441f5c3e06d60c5978cebe16cacfb assets/create/blockstates/zinc_block.json
b7181bcd8182b2f17088e5aa881f374c9c65470c assets/create/blockstates/zinc_ore.json
ce9a5edbf3f6d35c11ce3894efb89d012a3e643b assets/create/lang/en_ud.json
e19381716210baa2b86cd113017ab3ded998376f assets/create/lang/en_us.json
a4e6b545d4b9fac623de034ab8d063b2c621742c assets/create/lang/en_ud.json
aac2ef619ff4e427e50aa8d2e635c311f1780b6f assets/create/lang/en_us.json
487a511a01b2a4531fb672f917922312db78f958 assets/create/models/block/acacia_window.json
b48060cba1a382f373a05bf0039054053eccf076 assets/create/models/block/acacia_window_pane_noside.json
3066db1bf03cffa1a9c7fbacf47ae586632f4eb3 assets/create/models/block/acacia_window_pane_noside_alt.json
@ -1546,13 +1546,6 @@ b18fd30c44895bc993db27b6516addd2ad75fe55 assets/create/models/block/steam_whistl
7820c8787d56b3f9beb283512a01ac8fc44dfc57 assets/create/models/block/steam_whistle/block_medium_wall_powered.json
d144085e04718356d8b1fec7a4f46650b943e180 assets/create/models/block/steam_whistle/block_small_floor_powered.json
1fae9dd3da45f35b63ea9282d24723b2794869d0 assets/create/models/block/steam_whistle/block_small_wall_powered.json
3bda065e24a71b82b92b9c805790ba6d1791ef6a assets/create/models/block/stockpile_switch_0.json
335d6bc2b19d3cdbc9ed8b344142e2e3aa397994 assets/create/models/block/stockpile_switch_1.json
655d5cd249291a550bb3508c97f5a7a3606a7848 assets/create/models/block/stockpile_switch_2.json
cd8242a881e78831f6573c1fef99f9941ecf6ef7 assets/create/models/block/stockpile_switch_3.json
ad1950ba333cb2095c0dba5c0c020517acbfeb28 assets/create/models/block/stockpile_switch_4.json
ba22751c2d11fbe0ee03d90d408250edb4148080 assets/create/models/block/stockpile_switch_5.json
d6a49bf3c26ab83de70190db5f8a9c6dca85df52 assets/create/models/block/stockpile_switch_6.json
050ba6ad19c79ca0c7e5a2876981f47b54c1dad1 assets/create/models/block/tiled_glass.json
105f953f708c78f95de5db5def20c6ff0d1af4c9 assets/create/models/block/tiled_glass_pane_noside.json
d257b024117a6003196c1feb85e759a3e1c180f7 assets/create/models/block/tiled_glass_pane_noside_alt.json
@ -2202,7 +2195,7 @@ f3ec8df2ee1690353ae1ec687b822d0fd962160e assets/create/models/item/spruce_window
ba37dbd2da76713468312b2fe66a3706ffb2ae3e assets/create/models/item/steam_whistle.json
bb546e5342c6d1a6b4040cf7ccdd2f10c6f79965 assets/create/models/item/sticker.json
891abc24593d53d282773eca5534065056d89b4c assets/create/models/item/sticky_mechanical_piston.json
bbb5773adc23128c70174bfc531af936e6e063e3 assets/create/models/item/stockpile_switch.json
23b90f68439de1f60cb9d307e1c40c2549746c8f assets/create/models/item/stockpile_switch.json
bab8f78c319b2a79ed55c5d2a94b521ddaa44996 assets/create/models/item/stressometer.json
6a8f7af1715484d1e7aa4aa548db921f90899cb2 assets/create/models/item/sturdy_sheet.json
67cbfc1413ad5201f462c618a8fc6265edb3b8ad assets/create/models/item/super_glue.json
@ -2275,6 +2268,24 @@ be7a2d59d43083d7f2427193dcb9d68004224dd3 assets/create/models/item/white_valve_h
866fbb0ce2878a73e0440d1caf6534c8bd7c384f assets/create/models/item/zinc_ingot.json
a80fb25a0b655e76be986b5b49fcb0f03461a1ab assets/create/models/item/zinc_nugget.json
b1689617190c05ef34bd18456b0c7ae09bb3210f assets/create/models/item/zinc_ore.json
2f53104ec02684b16107e0f435cdd038d4183260 assets/create/models/threshold_switch/block_ceiling_0.json
e6732c3e32699550a238773e575ba826b5cb9d46 assets/create/models/threshold_switch/block_ceiling_1.json
6fa36705a93d5bf1c5e1887ee9a3c14c59f1889a assets/create/models/threshold_switch/block_ceiling_2.json
935c1bd1779d56d65b38cd6dc59d6d0eedf78fbe assets/create/models/threshold_switch/block_ceiling_3.json
c66ab242ccdad92aec72668a828a97b72581ce37 assets/create/models/threshold_switch/block_ceiling_4.json
6abc787ff6ac758938e29d15c60b37823e427378 assets/create/models/threshold_switch/block_ceiling_5.json
e6f0ec2a5956c383b3ebc1420c3ac546a774db11 assets/create/models/threshold_switch/block_floor_0.json
6f0ec6f68ae405fb88f2fca08825df3c7bd46464 assets/create/models/threshold_switch/block_floor_1.json
e997fc367ffc354b89dc01a44cdf350f9a34345c assets/create/models/threshold_switch/block_floor_2.json
14ca62bd8a15495d5ca3e0994a118fa9f01f8574 assets/create/models/threshold_switch/block_floor_3.json
46289bd92ce7f21d9f0d8b806e7e93ba5f11d47f assets/create/models/threshold_switch/block_floor_4.json
12438e288860e84895e3f296cb3e82389d1be3e4 assets/create/models/threshold_switch/block_floor_5.json
fb29b0323fcbaf96bef197db89a6943626091998 assets/create/models/threshold_switch/block_wall_0.json
9ff3206513232878964219efefc613bc683893db assets/create/models/threshold_switch/block_wall_1.json
e66e4cbab3bd9c8338b032adba7a689e96d5b185 assets/create/models/threshold_switch/block_wall_2.json
32cfe5661b8bf9886e7282c088d731883c38f1ec assets/create/models/threshold_switch/block_wall_3.json
37b2f0f29bda5eadc84a147887ce7ba9fc0ef2d1 assets/create/models/threshold_switch/block_wall_4.json
533746594ff508be13438cc3f297aa71dc48cec5 assets/create/models/threshold_switch/block_wall_5.json
de7cdf8d734a067af32883e9d86a10e0542a0f5b assets/create/sounds.json
7048adc6db09a949173a824b26569ade94081d3e data/create/advancements/andesite_alloy.json
595a47eb334ca5110fe30134d4aec87b97e53f42 data/create/advancements/andesite_casing.json
@ -2390,8 +2401,11 @@ fa2e18298f7710465d9b0798a69288e846c646fd data/create/advancements/recipes/create
048a24b84c19c47802c5aed069001925eedd087d data/create/advancements/recipes/create.base/crafting/appliances/filter_clear.json
a9b163744b1c494d07ec256d0367884f9601176d data/create/advancements/recipes/create.base/crafting/appliances/linked_controller.json
ab1e704db4a41a8d2cba357942f95c411a80a0c8 data/create/advancements/recipes/create.base/crafting/appliances/netherite_backtank.json
98bfe4af094326e6d82bc9d779830056ca65e827 data/create/advancements/recipes/create.base/crafting/appliances/netherite_backtank_from_netherite.json
f714a7fa70ed9e9b0c145d466357cd1ef4de184b data/create/advancements/recipes/create.base/crafting/appliances/netherite_diving_boots.json
7a9ad7923d3cd805da8696530fc59745b9607e26 data/create/advancements/recipes/create.base/crafting/appliances/netherite_diving_boots_from_netherite.json
99efa64a74ad29cf3b6cc565eabdd9b7e7e0cc40 data/create/advancements/recipes/create.base/crafting/appliances/netherite_diving_helmet.json
f06e0d8259e447d27494105566d306f17ec88daa data/create/advancements/recipes/create.base/crafting/appliances/netherite_diving_helmet_from_netherite.json
4f591309b0d47e2940f60e0e43f65fdf250b0dfa data/create/advancements/recipes/create.base/crafting/appliances/schedule_clear.json
c4769d7ac9c537eb4409b02883e89d0930514a8b data/create/advancements/recipes/create.base/crafting/appliances/tree_fertilizer.json
bb138bedd2aec741fa54b6b52be384fdbd741249 data/create/advancements/recipes/create.base/crafting/curiosities/brown_toolbox.json
@ -2459,7 +2473,7 @@ f4e8fd79cb27e0677460f5c260b106338f2a48cc data/create/advancements/recipes/create
a9f2c8a0b0b322741575ef833a461006ef2f0421 data/create/advancements/recipes/create.base/crafting/kinetics/item_drain.json
2ccfaf572456e8642a0070ea6928a082f98c63af data/create/advancements/recipes/create.base/crafting/kinetics/item_vault.json
73433a5cd400ed392796a4e543f15c42dd499fe8 data/create/advancements/recipes/create.base/crafting/kinetics/large_cogwheel.json
1c9e9888ccc51ddf76b9df0c186e74efaefb1256 data/create/advancements/recipes/create.base/crafting/kinetics/large_cogwheelfrom_little.json
dce186637ad5dacdbe352fb8a711df8e8687ccdc data/create/advancements/recipes/create.base/crafting/kinetics/large_cogwheel_from_little.json
5a1df5831fe5d2e2a6cbedcbc67216dd566e7fa0 data/create/advancements/recipes/create.base/crafting/kinetics/large_water_wheel.json
eb007bb079bbe6b6aaad2ca90f5af84261e3f8ea data/create/advancements/recipes/create.base/crafting/kinetics/light_blue_seat.json
571da50fbf5f2fcd3363b3dab91e7233e0ebffa0 data/create/advancements/recipes/create.base/crafting/kinetics/light_blue_seat_from_other_seat.json
@ -2556,8 +2570,7 @@ f05bbae1e39eabb51dffa0babecf07f5de2cee3d data/create/advancements/recipes/create
3443156df3d50b283be20d466797075064ddd59d data/create/advancements/recipes/create.base/crafting/logistics/andesite_tunnel.json
66dbb3486c5d38d309dd480e3f2ab0eb5ff9e559 data/create/advancements/recipes/create.base/crafting/logistics/brass_funnel.json
2127c0f1d822cc88a24d98ebb9eead9de5837ffe data/create/advancements/recipes/create.base/crafting/logistics/brass_tunnel.json
6ee9a16973001dcce16afc4c085f6dc3abbc344a data/create/advancements/recipes/create.base/crafting/logistics/content_observer.json
e20925f3c67f4a7b4acbbd61f8375efe09416edc data/create/advancements/recipes/create.base/crafting/logistics/content_observerfrom_conversion.json
34ca78bb33f7832d4953d1287533fd067fbc5227 data/create/advancements/recipes/create.base/crafting/logistics/content_observer.json
cf8418ddb94198b900c6b8a281e59cee404b1b63 data/create/advancements/recipes/create.base/crafting/logistics/display_link.json
b9b0a8bfff61a89149d4fcadf679f753385212d0 data/create/advancements/recipes/create.base/crafting/logistics/powered_latch.json
9951f2d35f7444c98c022142119b18b1289ca734 data/create/advancements/recipes/create.base/crafting/logistics/powered_toggle_latch.json
@ -2565,7 +2578,7 @@ b9b0a8bfff61a89149d4fcadf679f753385212d0 data/create/advancements/recipes/create
76d4c5f04d0a3e6817127a828594388b18f210c4 data/create/advancements/recipes/create.base/crafting/logistics/pulse_repeater.json
0020b5c5cc6301c576d392ace447235de3e1b70c data/create/advancements/recipes/create.base/crafting/logistics/redstone_contact.json
4bb511d1407ad4e21a53f7d67daa3b0de9b6c01e data/create/advancements/recipes/create.base/crafting/logistics/redstone_link.json
5da3e404c9195ee68c25e91a4fd29ab21a8e9316 data/create/advancements/recipes/create.base/crafting/logistics/stockpile_switchfrom_conversion.json
675c980c5b9088233b8d777fa03aba4c44650c4e data/create/advancements/recipes/create.base/crafting/logistics/stockpile_switch.json
8e137e9ad4870708d4c015400f91d78cb37b4a92 data/create/advancements/recipes/create.base/crafting/materials/andesite_alloy.json
fccf9862a45c8847a45b301b191aef3e138fa1d4 data/create/advancements/recipes/create.base/crafting/materials/andesite_alloy_from_block.json
6ad84f6f8b4ef85e67ebcc68c5326a22b59bc81a data/create/advancements/recipes/create.base/crafting/materials/andesite_alloy_from_zinc.json
@ -3871,8 +3884,11 @@ edf96556bb2357f54fd398fe573641afa15239b2 data/create/recipes/crafting/appliances
96feda6a0556a73851a41c6b7b7be1e8d9d5a028 data/create/recipes/crafting/appliances/filter_clear.json
75cdbd88973a8ca943ebe890153b01a344b96b01 data/create/recipes/crafting/appliances/linked_controller.json
9ef7bae26db471741096abd2b02f738202913994 data/create/recipes/crafting/appliances/netherite_backtank.json
2e3649e36c433b520cd7cb020fa40df35dfa83e9 data/create/recipes/crafting/appliances/netherite_backtank_from_netherite.json
e84952517f02a7c1ba10f12e2e0e32b94f720e58 data/create/recipes/crafting/appliances/netherite_diving_boots.json
3af37967d6ef033389955f212a0c3976a8b11e1c data/create/recipes/crafting/appliances/netherite_diving_boots_from_netherite.json
664421c08143e4eb60332f53da17f70b4be83e74 data/create/recipes/crafting/appliances/netherite_diving_helmet.json
538b9154155ec7f8c1e63ff4c201eeb90936e013 data/create/recipes/crafting/appliances/netherite_diving_helmet_from_netherite.json
9c40eb131b4e8161654e00f47b654abf5ed75804 data/create/recipes/crafting/appliances/schedule_clear.json
7b5f863dda3d05a79cb85943a178eba0bd8a7dc7 data/create/recipes/crafting/appliances/slime_ball.json
b159ba84428eee6ef6e23df1766f2a18f2c8a63e data/create/recipes/crafting/appliances/tree_fertilizer.json
@ -3968,7 +3984,7 @@ fe806e84a575e83da4709e1d48426bda1b6421d1 data/create/recipes/crafting/kinetics/h
f4fbb11ef55f3431bd387f3f6f258513bfbc8011 data/create/recipes/crafting/kinetics/item_drain.json
8f7110447f039f80a6f5b1d854bc760c3d77da82 data/create/recipes/crafting/kinetics/item_vault.json
7f105694e02d4ce69a02740edfa4a0d0bc4f4eac data/create/recipes/crafting/kinetics/large_cogwheel.json
197c174c28f294b23ae6496b7a31c35e7e8b4771 data/create/recipes/crafting/kinetics/large_cogwheelfrom_little.json
197c174c28f294b23ae6496b7a31c35e7e8b4771 data/create/recipes/crafting/kinetics/large_cogwheel_from_little.json
5609b12dde7127965c70da2760038c456ba3cfd6 data/create/recipes/crafting/kinetics/large_water_wheel.json
0397b107ab380cd23390c96f298971a70e9bceef data/create/recipes/crafting/kinetics/light_blue_seat.json
aa06f0594e1b2d31aa41bace309ed95a16529498 data/create/recipes/crafting/kinetics/light_blue_seat_from_other_seat.json
@ -4066,8 +4082,7 @@ cdef45f9fe02b031648b7b4dd4786b838f7ad105 data/create/recipes/crafting/logistics/
660e824ab6042c145f02ffcfe95a34c38f113e19 data/create/recipes/crafting/logistics/andesite_tunnel.json
262879a029ed80e2068a4de26a6117e8847069e3 data/create/recipes/crafting/logistics/brass_funnel.json
2ae06df0357c494b53db0ddf9655c60ef2022d0b data/create/recipes/crafting/logistics/brass_tunnel.json
ce2228d3cbec4b770ba95a3940c36dfe156ebc1b data/create/recipes/crafting/logistics/content_observer.json
22d18bf94275f8e4153da4f03c657b7eaa766716 data/create/recipes/crafting/logistics/content_observerfrom_conversion.json
91cdf493edb22c012969642427dcf5c11d2f5500 data/create/recipes/crafting/logistics/content_observer.json
abef83d640e02a715854ec4f7a90aa1fab8f4f5f data/create/recipes/crafting/logistics/display_link.json
a32ac53848862837f3044ff9c81ed62c1134fe4f data/create/recipes/crafting/logistics/powered_latch.json
660eb73bcc66c1528cbd4d4204ad6b771f4bd721 data/create/recipes/crafting/logistics/powered_toggle_latch.json
@ -4075,7 +4090,7 @@ a32ac53848862837f3044ff9c81ed62c1134fe4f data/create/recipes/crafting/logistics/
9f079a853c128f68f15277448bbf72dfbc212f26 data/create/recipes/crafting/logistics/pulse_repeater.json
739f0d8b7f98a5639ed37f7fb8ce474d5e6ba0c6 data/create/recipes/crafting/logistics/redstone_contact.json
8de2f5220d719feeaeab99cb526e890cdc97340d data/create/recipes/crafting/logistics/redstone_link.json
7dd23fbdd0fbd5471ed78108e6171e43db9b75f3 data/create/recipes/crafting/logistics/stockpile_switchfrom_conversion.json
cbef498e433c05b7989946ef02fcc47aa02d8a9c data/create/recipes/crafting/logistics/stockpile_switch.json
0dc99b8a8c68d6a9250c3a1167ffb565be9622ec data/create/recipes/crafting/materials/andesite_alloy.json
2bc954f42ddc6ecc9e1bbbc5ad03e3946ddaf368 data/create/recipes/crafting/materials/andesite_alloy_block.json
9531694c30fd06ff34ae081ab64b8cba192cb9c4 data/create/recipes/crafting/materials/andesite_alloy_from_block.json
@ -5286,7 +5301,7 @@ d99d5c67bdffff60789a19bd51a5c5267c75e0a4 data/create/tags/blocks/casing.json
bc203f09dd7f48965d146d0bd035fb904cb75e7d data/create/tags/blocks/copycat_allow.json
d4a3b66f4b763b9a2dcdea74b7273f0ae85cb335 data/create/tags/blocks/copycat_deny.json
73c2c85233075d2854d209b71ff2160308a7919c data/create/tags/blocks/fan_transparent.json
ee6d2b53d81f2bed492662b6c06f46c4f2b9ef9b data/create/tags/blocks/movable_empty_collider.json
5445d23a146003f0aa8de86643c4315d4afd4ef6 data/create/tags/blocks/movable_empty_collider.json
6e5d3b2123fbb00e7f439c091623619502551bca data/create/tags/blocks/non_movable.json
10781e8cfcbb3486327aace3aa00e437fb44b331 data/create/tags/blocks/ore_override_stone.json
760adb521c2e475a6414f97291f46c02d294fa74 data/create/tags/blocks/passive_boiler_heaters.json

View file

@ -1,34 +1,110 @@
{
"variants": {
"facing=north,powered=false": {
"facing=north,powered=false,target=floor": {
"model": "create:block/content_observer/block",
"x": 90
},
"facing=south,powered=false,target=floor": {
"model": "create:block/content_observer/block",
"x": 90,
"y": 180
},
"facing=west,powered=false,target=floor": {
"model": "create:block/content_observer/block",
"x": 90,
"y": 270
},
"facing=east,powered=false,target=floor": {
"model": "create:block/content_observer/block",
"x": 90,
"y": 90
},
"facing=north,powered=true,target=floor": {
"model": "create:block/content_observer/block_powered",
"x": 90
},
"facing=south,powered=true,target=floor": {
"model": "create:block/content_observer/block_powered",
"x": 90,
"y": 180
},
"facing=west,powered=true,target=floor": {
"model": "create:block/content_observer/block_powered",
"x": 90,
"y": 270
},
"facing=east,powered=true,target=floor": {
"model": "create:block/content_observer/block_powered",
"x": 90,
"y": 90
},
"facing=north,powered=false,target=wall": {
"model": "create:block/content_observer/block"
},
"facing=south,powered=false": {
"facing=south,powered=false,target=wall": {
"model": "create:block/content_observer/block",
"y": 180
},
"facing=west,powered=false": {
"facing=west,powered=false,target=wall": {
"model": "create:block/content_observer/block",
"y": 270
},
"facing=east,powered=false": {
"facing=east,powered=false,target=wall": {
"model": "create:block/content_observer/block",
"y": 90
},
"facing=north,powered=true": {
"facing=north,powered=true,target=wall": {
"model": "create:block/content_observer/block_powered"
},
"facing=south,powered=true": {
"facing=south,powered=true,target=wall": {
"model": "create:block/content_observer/block_powered",
"y": 180
},
"facing=west,powered=true": {
"facing=west,powered=true,target=wall": {
"model": "create:block/content_observer/block_powered",
"y": 270
},
"facing=east,powered=true": {
"facing=east,powered=true,target=wall": {
"model": "create:block/content_observer/block_powered",
"y": 90
},
"facing=north,powered=false,target=ceiling": {
"model": "create:block/content_observer/block",
"x": 270
},
"facing=south,powered=false,target=ceiling": {
"model": "create:block/content_observer/block",
"x": 270,
"y": 180
},
"facing=west,powered=false,target=ceiling": {
"model": "create:block/content_observer/block",
"x": 270,
"y": 270
},
"facing=east,powered=false,target=ceiling": {
"model": "create:block/content_observer/block",
"x": 270,
"y": 90
},
"facing=north,powered=true,target=ceiling": {
"model": "create:block/content_observer/block_powered",
"x": 270
},
"facing=south,powered=true,target=ceiling": {
"model": "create:block/content_observer/block_powered",
"x": 270,
"y": 180
},
"facing=west,powered=true,target=ceiling": {
"model": "create:block/content_observer/block_powered",
"x": 270,
"y": 270
},
"facing=east,powered=true,target=ceiling": {
"model": "create:block/content_observer/block_powered",
"x": 270,
"y": 90
}
}
}

View file

@ -1,108 +1,273 @@
{
"variants": {
"facing=north,indicator=0": {
"model": "create:block/stockpile_switch_0"
"facing=north,level=0,target=floor": {
"model": "create:threshold_switch/block_floor_0"
},
"facing=south,indicator=0": {
"model": "create:block/stockpile_switch_0",
"facing=south,level=0,target=floor": {
"model": "create:threshold_switch/block_floor_0",
"y": 180
},
"facing=west,indicator=0": {
"model": "create:block/stockpile_switch_0",
"facing=west,level=0,target=floor": {
"model": "create:threshold_switch/block_floor_0",
"y": 270
},
"facing=east,indicator=0": {
"model": "create:block/stockpile_switch_0",
"facing=east,level=0,target=floor": {
"model": "create:threshold_switch/block_floor_0",
"y": 90
},
"facing=north,indicator=1": {
"model": "create:block/stockpile_switch_1"
"facing=north,level=1,target=floor": {
"model": "create:threshold_switch/block_floor_1"
},
"facing=south,indicator=1": {
"model": "create:block/stockpile_switch_1",
"facing=south,level=1,target=floor": {
"model": "create:threshold_switch/block_floor_1",
"y": 180
},
"facing=west,indicator=1": {
"model": "create:block/stockpile_switch_1",
"facing=west,level=1,target=floor": {
"model": "create:threshold_switch/block_floor_1",
"y": 270
},
"facing=east,indicator=1": {
"model": "create:block/stockpile_switch_1",
"facing=east,level=1,target=floor": {
"model": "create:threshold_switch/block_floor_1",
"y": 90
},
"facing=north,indicator=2": {
"model": "create:block/stockpile_switch_2"
"facing=north,level=2,target=floor": {
"model": "create:threshold_switch/block_floor_2"
},
"facing=south,indicator=2": {
"model": "create:block/stockpile_switch_2",
"facing=south,level=2,target=floor": {
"model": "create:threshold_switch/block_floor_2",
"y": 180
},
"facing=west,indicator=2": {
"model": "create:block/stockpile_switch_2",
"facing=west,level=2,target=floor": {
"model": "create:threshold_switch/block_floor_2",
"y": 270
},
"facing=east,indicator=2": {
"model": "create:block/stockpile_switch_2",
"facing=east,level=2,target=floor": {
"model": "create:threshold_switch/block_floor_2",
"y": 90
},
"facing=north,indicator=3": {
"model": "create:block/stockpile_switch_3"
"facing=north,level=3,target=floor": {
"model": "create:threshold_switch/block_floor_3"
},
"facing=south,indicator=3": {
"model": "create:block/stockpile_switch_3",
"facing=south,level=3,target=floor": {
"model": "create:threshold_switch/block_floor_3",
"y": 180
},
"facing=west,indicator=3": {
"model": "create:block/stockpile_switch_3",
"facing=west,level=3,target=floor": {
"model": "create:threshold_switch/block_floor_3",
"y": 270
},
"facing=east,indicator=3": {
"model": "create:block/stockpile_switch_3",
"facing=east,level=3,target=floor": {
"model": "create:threshold_switch/block_floor_3",
"y": 90
},
"facing=north,indicator=4": {
"model": "create:block/stockpile_switch_4"
"facing=north,level=4,target=floor": {
"model": "create:threshold_switch/block_floor_4"
},
"facing=south,indicator=4": {
"model": "create:block/stockpile_switch_4",
"facing=south,level=4,target=floor": {
"model": "create:threshold_switch/block_floor_4",
"y": 180
},
"facing=west,indicator=4": {
"model": "create:block/stockpile_switch_4",
"facing=west,level=4,target=floor": {
"model": "create:threshold_switch/block_floor_4",
"y": 270
},
"facing=east,indicator=4": {
"model": "create:block/stockpile_switch_4",
"facing=east,level=4,target=floor": {
"model": "create:threshold_switch/block_floor_4",
"y": 90
},
"facing=north,indicator=5": {
"model": "create:block/stockpile_switch_5"
"facing=north,level=5,target=floor": {
"model": "create:threshold_switch/block_floor_5"
},
"facing=south,indicator=5": {
"model": "create:block/stockpile_switch_5",
"facing=south,level=5,target=floor": {
"model": "create:threshold_switch/block_floor_5",
"y": 180
},
"facing=west,indicator=5": {
"model": "create:block/stockpile_switch_5",
"facing=west,level=5,target=floor": {
"model": "create:threshold_switch/block_floor_5",
"y": 270
},
"facing=east,indicator=5": {
"model": "create:block/stockpile_switch_5",
"facing=east,level=5,target=floor": {
"model": "create:threshold_switch/block_floor_5",
"y": 90
},
"facing=north,indicator=6": {
"model": "create:block/stockpile_switch_6"
"facing=north,level=0,target=wall": {
"model": "create:threshold_switch/block_wall_0"
},
"facing=south,indicator=6": {
"model": "create:block/stockpile_switch_6",
"facing=south,level=0,target=wall": {
"model": "create:threshold_switch/block_wall_0",
"y": 180
},
"facing=west,indicator=6": {
"model": "create:block/stockpile_switch_6",
"facing=west,level=0,target=wall": {
"model": "create:threshold_switch/block_wall_0",
"y": 270
},
"facing=east,indicator=6": {
"model": "create:block/stockpile_switch_6",
"facing=east,level=0,target=wall": {
"model": "create:threshold_switch/block_wall_0",
"y": 90
},
"facing=north,level=1,target=wall": {
"model": "create:threshold_switch/block_wall_1"
},
"facing=south,level=1,target=wall": {
"model": "create:threshold_switch/block_wall_1",
"y": 180
},
"facing=west,level=1,target=wall": {
"model": "create:threshold_switch/block_wall_1",
"y": 270
},
"facing=east,level=1,target=wall": {
"model": "create:threshold_switch/block_wall_1",
"y": 90
},
"facing=north,level=2,target=wall": {
"model": "create:threshold_switch/block_wall_2"
},
"facing=south,level=2,target=wall": {
"model": "create:threshold_switch/block_wall_2",
"y": 180
},
"facing=west,level=2,target=wall": {
"model": "create:threshold_switch/block_wall_2",
"y": 270
},
"facing=east,level=2,target=wall": {
"model": "create:threshold_switch/block_wall_2",
"y": 90
},
"facing=north,level=3,target=wall": {
"model": "create:threshold_switch/block_wall_3"
},
"facing=south,level=3,target=wall": {
"model": "create:threshold_switch/block_wall_3",
"y": 180
},
"facing=west,level=3,target=wall": {
"model": "create:threshold_switch/block_wall_3",
"y": 270
},
"facing=east,level=3,target=wall": {
"model": "create:threshold_switch/block_wall_3",
"y": 90
},
"facing=north,level=4,target=wall": {
"model": "create:threshold_switch/block_wall_4"
},
"facing=south,level=4,target=wall": {
"model": "create:threshold_switch/block_wall_4",
"y": 180
},
"facing=west,level=4,target=wall": {
"model": "create:threshold_switch/block_wall_4",
"y": 270
},
"facing=east,level=4,target=wall": {
"model": "create:threshold_switch/block_wall_4",
"y": 90
},
"facing=north,level=5,target=wall": {
"model": "create:threshold_switch/block_wall_5"
},
"facing=south,level=5,target=wall": {
"model": "create:threshold_switch/block_wall_5",
"y": 180
},
"facing=west,level=5,target=wall": {
"model": "create:threshold_switch/block_wall_5",
"y": 270
},
"facing=east,level=5,target=wall": {
"model": "create:threshold_switch/block_wall_5",
"y": 90
},
"facing=north,level=0,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_0"
},
"facing=south,level=0,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_0",
"y": 180
},
"facing=west,level=0,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_0",
"y": 270
},
"facing=east,level=0,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_0",
"y": 90
},
"facing=north,level=1,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_1"
},
"facing=south,level=1,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_1",
"y": 180
},
"facing=west,level=1,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_1",
"y": 270
},
"facing=east,level=1,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_1",
"y": 90
},
"facing=north,level=2,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_2"
},
"facing=south,level=2,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_2",
"y": 180
},
"facing=west,level=2,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_2",
"y": 270
},
"facing=east,level=2,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_2",
"y": 90
},
"facing=north,level=3,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_3"
},
"facing=south,level=3,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_3",
"y": 180
},
"facing=west,level=3,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_3",
"y": 270
},
"facing=east,level=3,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_3",
"y": 90
},
"facing=north,level=4,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_4"
},
"facing=south,level=4,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_4",
"y": 180
},
"facing=west,level=4,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_4",
"y": 270
},
"facing=east,level=4,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_4",
"y": 90
},
"facing=north,level=5,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_5"
},
"facing=south,level=5,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_5",
"y": 180
},
"facing=west,level=5,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_5",
"y": 270
},
"facing=east,level=5,target=ceiling": {
"model": "create:threshold_switch/block_ceiling_5",
"y": 90
}
}

View file

@ -56,7 +56,7 @@
"block.create.clockwork_bearing": "bu\u0131\u0279\u0250\u01DD\u15FA \u029E\u0279o\u028D\u029E\u0254o\u05DF\u0186",
"block.create.clutch": "\u0265\u0254\u0287n\u05DF\u0186",
"block.create.cogwheel": "\u05DF\u01DD\u01DD\u0265\u028Dbo\u0186",
"block.create.content_observer": "\u0279\u01DD\u028C\u0279\u01DDsqO \u0287u\u01DD\u0287uo\u0186",
"block.create.content_observer": "\u0279\u01DD\u028C\u0279\u01DDsqO \u0287\u0279\u0250\u026FS",
"block.create.contraption_controls": "s\u05DFo\u0279\u0287uo\u0186 uo\u0131\u0287d\u0250\u0279\u0287uo\u0186",
"block.create.controller_rail": "\u05DF\u0131\u0250\u1D1A \u0279\u01DD\u05DF\u05DFo\u0279\u0287uo\u0186",
"block.create.controls": "s\u05DFo\u0279\u0287uo\u0186 u\u0131\u0250\u0279\u27D8",
@ -514,7 +514,7 @@
"block.create.steam_whistle_extension": "uo\u0131su\u01DD\u0287x\u018E \u01DD\u05DF\u0287s\u0131\u0265M \u026F\u0250\u01DD\u0287S",
"block.create.sticker": "\u0279\u01DD\u029E\u0254\u0131\u0287S",
"block.create.sticky_mechanical_piston": "uo\u0287s\u0131\u0500 \u05DF\u0250\u0254\u0131u\u0250\u0265\u0254\u01DDW \u028E\u029E\u0254\u0131\u0287S",
"block.create.stockpile_switch": "\u0265\u0254\u0287\u0131\u028DS \u01DD\u05DF\u0131d\u029E\u0254o\u0287S",
"block.create.stockpile_switch": "\u0265\u0254\u0287\u0131\u028DS p\u05DFo\u0265s\u01DD\u0279\u0265\u27D8",
"block.create.stressometer": "\u0279\u01DD\u0287\u01DD\u026Foss\u01DD\u0279\u0287S",
"block.create.tiled_glass": "ss\u0250\u05DF\u2141 p\u01DD\u05DF\u0131\u27D8",
"block.create.tiled_glass_pane": "\u01DDu\u0250\u0500 ss\u0250\u05DF\u2141 p\u01DD\u05DF\u0131\u27D8",

View file

@ -59,7 +59,7 @@
"block.create.clockwork_bearing": "Clockwork Bearing",
"block.create.clutch": "Clutch",
"block.create.cogwheel": "Cogwheel",
"block.create.content_observer": "Content Observer",
"block.create.content_observer": "Smart Observer",
"block.create.contraption_controls": "Contraption Controls",
"block.create.controller_rail": "Controller Rail",
"block.create.controls": "Train Controls",
@ -517,7 +517,7 @@
"block.create.steam_whistle_extension": "Steam Whistle Extension",
"block.create.sticker": "Sticker",
"block.create.sticky_mechanical_piston": "Sticky Mechanical Piston",
"block.create.stockpile_switch": "Stockpile Switch",
"block.create.stockpile_switch": "Threshold Switch",
"block.create.stressometer": "Stressometer",
"block.create.tiled_glass": "Tiled Glass",
"block.create.tiled_glass_pane": "Tiled Glass Pane",
@ -1143,10 +1143,10 @@
"create.gui.contraptions.network_overstressed": "It appears that this contraption is _overstressed_. Add more sources or _slow_ _down_ the components with a high _stress_ _impact_.",
"create.gui.adjustable_crate.title": "Adjustable Crate",
"create.gui.adjustable_crate.storageSpace": "Storage Space",
"create.gui.stockpile_switch.title": "Stockpile Switch",
"create.gui.stockpile_switch.invert_signal": "Invert Signal",
"create.gui.stockpile_switch.move_to_lower_at": "Move to lower lane at %1$s%%",
"create.gui.stockpile_switch.move_to_upper_at": "Move to upper lane at %1$s%%",
"create.gui.threshold_switch.title": "Threshold Switch",
"create.gui.threshold_switch.invert_signal": "Invert Signal",
"create.gui.threshold_switch.move_to_lower_at": "Move to lower lane at %1$s%%",
"create.gui.threshold_switch.move_to_upper_at": "Move to upper lane at %1$s%%",
"create.gui.sequenced_gearshift.title": "Sequenced Gearshift",
"create.gui.sequenced_gearshift.instruction": "Instruction",
"create.gui.sequenced_gearshift.instruction.turn_angle.descriptive": "Turn by angle",

View file

@ -1,6 +0,0 @@
{
"parent": "create:block/stockpile_switch",
"textures": {
"indicator": "create:block/indicator/0"
}
}

View file

@ -1,6 +0,0 @@
{
"parent": "create:block/stockpile_switch",
"textures": {
"indicator": "create:block/indicator/1"
}
}

View file

@ -1,6 +0,0 @@
{
"parent": "create:block/stockpile_switch",
"textures": {
"indicator": "create:block/indicator/2"
}
}

View file

@ -1,6 +0,0 @@
{
"parent": "create:block/stockpile_switch",
"textures": {
"indicator": "create:block/indicator/3"
}
}

View file

@ -1,6 +0,0 @@
{
"parent": "create:block/stockpile_switch",
"textures": {
"indicator": "create:block/indicator/4"
}
}

View file

@ -1,6 +0,0 @@
{
"parent": "create:block/stockpile_switch",
"textures": {
"indicator": "create:block/indicator/5"
}
}

View file

@ -1,6 +0,0 @@
{
"parent": "create:block/stockpile_switch",
"textures": {
"indicator": "create:block/indicator/6"
}
}

View file

@ -1,3 +1,3 @@
{
"parent": "create:block/stockpile_switch"
"parent": "create:block/threshold_switch/block_wall"
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_ceiling",
"textures": {
"level": "create:block/threshold_switch/level_0"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_ceiling",
"textures": {
"level": "create:block/threshold_switch/level_1"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_ceiling",
"textures": {
"level": "create:block/threshold_switch/level_2"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_ceiling",
"textures": {
"level": "create:block/threshold_switch/level_3"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_ceiling",
"textures": {
"level": "create:block/threshold_switch/level_4"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_ceiling",
"textures": {
"level": "create:block/threshold_switch/level_5"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_floor",
"textures": {
"level": "create:block/threshold_switch/level_0"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_floor",
"textures": {
"level": "create:block/threshold_switch/level_1"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_floor",
"textures": {
"level": "create:block/threshold_switch/level_2"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_floor",
"textures": {
"level": "create:block/threshold_switch/level_3"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_floor",
"textures": {
"level": "create:block/threshold_switch/level_4"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_floor",
"textures": {
"level": "create:block/threshold_switch/level_5"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_wall",
"textures": {
"level": "create:block/threshold_switch/level_0"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_wall",
"textures": {
"level": "create:block/threshold_switch/level_1"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_wall",
"textures": {
"level": "create:block/threshold_switch/level_2"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_wall",
"textures": {
"level": "create:block/threshold_switch/level_3"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_wall",
"textures": {
"level": "create:block/threshold_switch/level_4"
}
}

View file

@ -0,0 +1,6 @@
{
"parent": "create:block/threshold_switch/block_wall",
"textures": {
"level": "create:block/threshold_switch/level_5"
}
}

View file

@ -2,7 +2,7 @@
"parent": "minecraft:recipes/root",
"rewards": {
"recipes": [
"create:crafting/logistics/stockpile_switchfrom_conversion"
"create:crafting/appliances/netherite_backtank_from_netherite"
]
},
"criteria": {
@ -12,7 +12,7 @@
"items": [
{
"items": [
"create:content_observer"
"minecraft:netherite_chestplate"
]
}
]
@ -21,7 +21,7 @@
"has_the_recipe": {
"trigger": "minecraft:recipe_unlocked",
"conditions": {
"recipe": "create:crafting/logistics/stockpile_switchfrom_conversion"
"recipe": "create:crafting/appliances/netherite_backtank_from_netherite"
}
}
},

View file

@ -0,0 +1,34 @@
{
"parent": "minecraft:recipes/root",
"rewards": {
"recipes": [
"create:crafting/appliances/netherite_diving_boots_from_netherite"
]
},
"criteria": {
"has_item": {
"trigger": "minecraft:inventory_changed",
"conditions": {
"items": [
{
"items": [
"minecraft:netherite_boots"
]
}
]
}
},
"has_the_recipe": {
"trigger": "minecraft:recipe_unlocked",
"conditions": {
"recipe": "create:crafting/appliances/netherite_diving_boots_from_netherite"
}
}
},
"requirements": [
[
"has_item",
"has_the_recipe"
]
]
}

View file

@ -0,0 +1,34 @@
{
"parent": "minecraft:recipes/root",
"rewards": {
"recipes": [
"create:crafting/appliances/netherite_diving_helmet_from_netherite"
]
},
"criteria": {
"has_item": {
"trigger": "minecraft:inventory_changed",
"conditions": {
"items": [
{
"items": [
"minecraft:netherite_helmet"
]
}
]
}
},
"has_the_recipe": {
"trigger": "minecraft:recipe_unlocked",
"conditions": {
"recipe": "create:crafting/appliances/netherite_diving_helmet_from_netherite"
}
}
},
"requirements": [
[
"has_item",
"has_the_recipe"
]
]
}

View file

@ -2,7 +2,7 @@
"parent": "minecraft:recipes/root",
"rewards": {
"recipes": [
"create:crafting/kinetics/large_cogwheelfrom_little"
"create:crafting/kinetics/large_cogwheel_from_little"
]
},
"criteria": {
@ -21,7 +21,7 @@
"has_the_recipe": {
"trigger": "minecraft:recipe_unlocked",
"conditions": {
"recipe": "create:crafting/kinetics/large_cogwheelfrom_little"
"recipe": "create:crafting/kinetics/large_cogwheel_from_little"
}
}
},

View file

@ -12,7 +12,7 @@
"items": [
{
"items": [
"create:belt_connector"
"create:brass_casing"
]
}
]

View file

@ -2,7 +2,7 @@
"parent": "minecraft:recipes/root",
"rewards": {
"recipes": [
"create:crafting/logistics/content_observerfrom_conversion"
"create:crafting/logistics/stockpile_switch"
]
},
"criteria": {
@ -12,7 +12,7 @@
"items": [
{
"items": [
"create:stockpile_switch"
"create:brass_casing"
]
}
]
@ -21,7 +21,7 @@
"has_the_recipe": {
"trigger": "minecraft:recipe_unlocked",
"conditions": {
"recipe": "create:crafting/logistics/content_observerfrom_conversion"
"recipe": "create:crafting/logistics/stockpile_switch"
}
}
},

View file

@ -0,0 +1,12 @@
{
"type": "minecraft:smithing",
"base": {
"item": "minecraft:netherite_chestplate"
},
"addition": {
"item": "create:copper_backtank"
},
"result": {
"item": "create:netherite_backtank"
}
}

View file

@ -0,0 +1,12 @@
{
"type": "minecraft:smithing",
"base": {
"item": "minecraft:netherite_boots"
},
"addition": {
"item": "create:copper_diving_boots"
},
"result": {
"item": "create:netherite_diving_boots"
}
}

View file

@ -0,0 +1,12 @@
{
"type": "minecraft:smithing",
"base": {
"item": "minecraft:netherite_helmet"
},
"addition": {
"item": "create:copper_diving_helmet"
},
"result": {
"item": "create:netherite_diving_helmet"
}
}

View file

@ -1,9 +1,9 @@
{
"type": "minecraft:crafting_shaped",
"pattern": [
"I",
"R",
"B",
"R"
"I"
],
"key": {
"B": {
@ -13,7 +13,7 @@
"item": "create:electron_tube"
},
"I": {
"item": "minecraft:comparator"
"item": "minecraft:observer"
}
},
"result": {

View file

@ -1,11 +0,0 @@
{
"type": "minecraft:crafting_shapeless",
"ingredients": [
{
"item": "create:stockpile_switch"
}
],
"result": {
"item": "create:content_observer"
}
}

View file

@ -0,0 +1,22 @@
{
"type": "minecraft:crafting_shaped",
"pattern": [
"R",
"B",
"I"
],
"key": {
"B": {
"item": "create:brass_casing"
},
"R": {
"item": "create:electron_tube"
},
"I": {
"item": "minecraft:comparator"
}
},
"result": {
"item": "create:stockpile_switch"
}
}

View file

@ -1,11 +0,0 @@
{
"type": "minecraft:crafting_shapeless",
"ingredients": [
{
"item": "create:content_observer"
}
],
"result": {
"item": "create:stockpile_switch"
}
}

View file

@ -3,6 +3,8 @@
"values": [
"minecraft:cobweb",
"minecraft:powder_snow",
"minecraft:tripwire",
"minecraft:tripwire_hook",
"#minecraft:fence_gates"
]
}

View file

@ -186,11 +186,11 @@ import com.simibubi.create.content.logistics.block.mechanicalArm.ArmRenderer;
import com.simibubi.create.content.logistics.block.redstone.AnalogLeverBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.AnalogLeverInstance;
import com.simibubi.create.content.logistics.block.redstone.AnalogLeverRenderer;
import com.simibubi.create.content.logistics.block.redstone.ContentObserverBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.NixieTubeBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.NixieTubeRenderer;
import com.simibubi.create.content.logistics.block.redstone.RedstoneLinkBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.StockpileSwitchBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.SmartObserverBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.ThresholdSwitchBlockEntity;
import com.simibubi.create.content.logistics.block.vault.ItemVaultBlockEntity;
import com.simibubi.create.content.logistics.item.LecternControllerBlockEntity;
import com.simibubi.create.content.logistics.item.LecternControllerRenderer;
@ -742,9 +742,9 @@ public class AllBlockEntityTypes {
.renderer(() -> DisplayLinkRenderer::new)
.register();
public static final BlockEntityEntry<StockpileSwitchBlockEntity> STOCKPILE_SWITCH = REGISTRATE
.blockEntity("stockpile_switch", StockpileSwitchBlockEntity::new)
.validBlocks(AllBlocks.STOCKPILE_SWITCH)
public static final BlockEntityEntry<ThresholdSwitchBlockEntity> THRESHOLD_SWITCH = REGISTRATE
.blockEntity("stockpile_switch", ThresholdSwitchBlockEntity::new)
.validBlocks(AllBlocks.THRESHOLD_SWITCH)
.renderer(() -> SmartBlockEntityRenderer::new)
.register();
@ -775,9 +775,9 @@ public class AllBlockEntityTypes {
.renderer(() -> FunnelRenderer::new)
.register();
public static final BlockEntityEntry<ContentObserverBlockEntity> CONTENT_OBSERVER = REGISTRATE
.blockEntity("content_observer", ContentObserverBlockEntity::new)
.validBlocks(AllBlocks.CONTENT_OBSERVER)
public static final BlockEntityEntry<SmartObserverBlockEntity> SMART_OBSERVER = REGISTRATE
.blockEntity("content_observer", SmartObserverBlockEntity::new)
.validBlocks(AllBlocks.SMART_OBSERVER)
.renderer(() -> SmartBlockEntityRenderer::new)
.register();

View file

@ -215,7 +215,6 @@ import com.simibubi.create.content.logistics.block.mechanicalArm.ArmBlock;
import com.simibubi.create.content.logistics.block.mechanicalArm.ArmItem;
import com.simibubi.create.content.logistics.block.redstone.AnalogLeverBlock;
import com.simibubi.create.content.logistics.block.redstone.ContactMovementBehaviour;
import com.simibubi.create.content.logistics.block.redstone.ContentObserverBlock;
import com.simibubi.create.content.logistics.block.redstone.NixieTubeBlock;
import com.simibubi.create.content.logistics.block.redstone.NixieTubeGenerator;
import com.simibubi.create.content.logistics.block.redstone.RedstoneContactBlock;
@ -223,7 +222,10 @@ import com.simibubi.create.content.logistics.block.redstone.RedstoneContactItem;
import com.simibubi.create.content.logistics.block.redstone.RedstoneLinkBlock;
import com.simibubi.create.content.logistics.block.redstone.RedstoneLinkGenerator;
import com.simibubi.create.content.logistics.block.redstone.RoseQuartzLampBlock;
import com.simibubi.create.content.logistics.block.redstone.StockpileSwitchBlock;
import com.simibubi.create.content.logistics.block.redstone.SmartObserverBlock;
import com.simibubi.create.content.logistics.block.redstone.SmartObserverGenerator;
import com.simibubi.create.content.logistics.block.redstone.ThresholdSwitchBlock;
import com.simibubi.create.content.logistics.block.redstone.ThresholdSwitchGenerator;
import com.simibubi.create.content.logistics.block.vault.ItemVaultBlock;
import com.simibubi.create.content.logistics.block.vault.ItemVaultCTBehaviour;
import com.simibubi.create.content.logistics.block.vault.ItemVaultItem;
@ -1814,29 +1816,33 @@ public class AllBlocks {
.onRegister(connectedTextures(BrassTunnelCTBehaviour::new))
.register();
public static final BlockEntry<ContentObserverBlock> CONTENT_OBSERVER =
REGISTRATE.block("content_observer", ContentObserverBlock::new)
public static final BlockEntry<SmartObserverBlock> SMART_OBSERVER =
REGISTRATE.block("content_observer", SmartObserverBlock::new)
.initialProperties(SharedProperties::stone)
.properties(p -> p.color(MaterialColor.TERRACOTTA_BROWN))
.properties(p -> p.noOcclusion())
.transform(axeOrPickaxe())
.blockstate((c, p) -> p.horizontalBlock(c.get(), AssetLookup.forPowered(c, p)))
.blockstate(new SmartObserverGenerator()::generate)
.onRegister(assignDataBehaviour(new ItemCountDisplaySource(), "count_items"))
.onRegister(assignDataBehaviour(new ItemListDisplaySource(), "list_items"))
.onRegister(assignDataBehaviour(new FluidAmountDisplaySource(), "count_fluids"))
.onRegister(assignDataBehaviour(new FluidListDisplaySource(), "list_fluids"))
.lang("Smart Observer")
.item()
.transform(customItemModel("_", "block"))
.register();
public static final BlockEntry<StockpileSwitchBlock> STOCKPILE_SWITCH =
REGISTRATE.block("stockpile_switch", StockpileSwitchBlock::new)
public static final BlockEntry<ThresholdSwitchBlock> THRESHOLD_SWITCH =
REGISTRATE.block("stockpile_switch", ThresholdSwitchBlock::new)
.initialProperties(SharedProperties::stone)
.properties(p -> p.color(MaterialColor.TERRACOTTA_BROWN))
.properties(p -> p.noOcclusion())
.transform(axeOrPickaxe())
.blockstate((c, p) -> p.horizontalBlock(c.get(),
AssetLookup.withIndicator(c, p, $ -> AssetLookup.standardModel(c, p), StockpileSwitchBlock.INDICATOR)))
.blockstate(new ThresholdSwitchGenerator()::generate)
.onRegister(assignDataBehaviour(new FillLevelDisplaySource(), "fill_level"))
.simpleItem()
.lang("Threshold Switch")
.item()
.transform(customItemModel("threshold_switch", "block_wall"))
.register();
public static final BlockEntry<CreativeCrateBlock> CREATIVE_CRATE =

View file

@ -13,7 +13,7 @@ import com.simibubi.create.content.contraptions.components.structureMovement.Blo
import com.simibubi.create.content.contraptions.components.structureMovement.ContraptionCollider;
import com.simibubi.create.content.contraptions.components.structureMovement.ControlledContraptionEntity;
import com.simibubi.create.content.contraptions.components.structureMovement.piston.LinearActuatorBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.StockpileSwitchObservable;
import com.simibubi.create.content.logistics.block.redstone.ThresholdSwitchObservable;
import com.simibubi.create.foundation.advancement.AllAdvancements;
import com.simibubi.create.foundation.blockEntity.BlockEntityBehaviour;
import com.simibubi.create.foundation.blockEntity.behaviour.CenteredSideValueBoxTransform;
@ -35,7 +35,7 @@ import net.minecraft.world.level.material.Fluids;
import net.minecraft.world.phys.AABB;
import net.minecraft.world.phys.Vec3;
public class PulleyBlockEntity extends LinearActuatorBlockEntity implements StockpileSwitchObservable {
public class PulleyBlockEntity extends LinearActuatorBlockEntity implements ThresholdSwitchObservable {
protected int initialOffset;
private float prevAnimatedOffset;

View file

@ -65,7 +65,7 @@ public class SequencedGearshiftScreen extends AbstractSimiScreen {
public void initInputsOfRow(int row, int backgroundX, int backgroundY) {
int x = backgroundX + 30;
int y = backgroundY + 18;
int y = backgroundY + 20;
int rowHeight = 22;
Vector<ScrollInput> rowInputs = inputs.get(row);
@ -138,25 +138,25 @@ public class SequencedGearshiftScreen extends AbstractSimiScreen {
AllGuiTextures toDraw = AllGuiTextures.SEQUENCER_EMPTY;
int yOffset = toDraw.height * row;
if (row >= instructions.size()) {
toDraw.render(ms, x, y + 14 + yOffset, this);
toDraw.render(ms, x, y + 16 + yOffset, this);
continue;
}
Instruction instruction = instructions.get(row);
SequencerInstructions def = instruction.instruction;
def.background.render(ms, x, y + 14 + yOffset, this);
def.background.render(ms, x, y + 16 + yOffset, this);
label(ms, 36, yOffset - 3, Lang.translateDirect(def.translationKey));
label(ms, 36, yOffset - 1, Lang.translateDirect(def.translationKey));
if (def.hasValueParameter) {
String text = def.formatValue(instruction.value);
int stringWidth = font.width(text);
label(ms, 90 + (12 - stringWidth / 2), yOffset - 3, Components.literal(text));
label(ms, 90 + (12 - stringWidth / 2), yOffset - 1, Components.literal(text));
}
if (def.hasSpeedParameter)
label(ms, 127, yOffset - 3, instruction.speedModifier.label);
label(ms, 127, yOffset - 1, instruction.speedModifier.label);
}
drawCenteredString(ms, font, title, x + (background.width - 8) / 2, y + 3, 0xFFFFFF);
font.draw(ms, title, x + (background.width - 8) / 2 - font.width(title) / 2, y + 4, 0x592424);
GuiGameElement.of(renderedItem)
.<GuiGameElement.GuiRenderBuilder>at(x + background.width + 6, y + background.height - 56, -200)

View file

@ -122,7 +122,7 @@ public class SymmetryWandScreen extends AbstractSimiScreen {
int y = guiTop;
background.render(ms, x, y, this);
font.draw(ms, wand.getHoverName(), x + 11, y + 4, 0x6B3802);
font.draw(ms, wand.getHoverName(), x + 11, y + 4, 0x592424);
renderBlock(ms, x, y);
GuiGameElement.of(wand)

View file

@ -81,7 +81,7 @@ public class ToolboxScreen extends AbstractSimiContainerScreen<ToolboxMenu> {
int y = topPos;
BG.render(ms, x, y, this);
font.draw(ms, title, x + 15, y + 4, 0x442000);
font.draw(ms, title, x + 15, y + 4, 0x592424);
int invX = leftPos;
int invY = topPos + imageHeight - PLAYER.height;

View file

@ -255,7 +255,7 @@ public class DisplayLinkScreen extends AbstractSimiScreen {
background.render(ms, x, y, this);
MutableComponent header = Lang.translateDirect("display_link.title");
font.draw(ms, header, x + background.width / 2 - font.width(header) / 2, y + 4, 0x442000);
font.draw(ms, header, x + background.width / 2 - font.width(header) / 2, y + 4, 0x592424);
if (sources.isEmpty())
font.drawShadow(ms, Lang.translateDirect("display_link.no_source"), x + 65, y + 30, 0xD3D3D3);

View file

@ -1,7 +1,7 @@
package com.simibubi.create.content.logistics.block.display.source;
import com.simibubi.create.content.logistics.block.display.DisplayLinkContext;
import com.simibubi.create.content.logistics.block.redstone.StockpileSwitchBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.ThresholdSwitchBlockEntity;
import com.simibubi.create.foundation.gui.ModularGuiLineBuilder;
import com.simibubi.create.foundation.utility.Lang;
@ -14,7 +14,7 @@ public class FillLevelDisplaySource extends PercentOrProgressBarDisplaySource {
@Override
protected Float getProgress(DisplayLinkContext context) {
BlockEntity be = context.getSourceBlockEntity();
if (!(be instanceof StockpileSwitchBlockEntity sste))
if (!(be instanceof ThresholdSwitchBlockEntity sste))
return null;
return sste.currentLevel;
}

View file

@ -2,7 +2,7 @@ package com.simibubi.create.content.logistics.block.display.source;
import com.simibubi.create.content.logistics.block.display.DisplayLinkContext;
import com.simibubi.create.content.logistics.block.display.target.DisplayTargetStats;
import com.simibubi.create.content.logistics.block.redstone.ContentObserverBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.SmartObserverBlockEntity;
import com.simibubi.create.foundation.blockEntity.behaviour.filtering.FilteringBehaviour;
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.TankManipulationBehaviour;
import com.simibubi.create.foundation.utility.Components;
@ -18,7 +18,7 @@ public class FluidAmountDisplaySource extends SingleLineDisplaySource {
@Override
protected MutableComponent provideLine(DisplayLinkContext context, DisplayTargetStats stats) {
BlockEntity sourceBE = context.getSourceBlockEntity();
if (!(sourceBE instanceof ContentObserverBlockEntity cobe))
if (!(sourceBE instanceof SmartObserverBlockEntity cobe))
return EMPTY_LINE;
TankManipulationBehaviour tankManipulationBehaviour = cobe.getBehaviour(TankManipulationBehaviour.OBSERVE);

View file

@ -9,7 +9,7 @@ import java.util.stream.Stream;
import org.apache.commons.lang3.mutable.MutableInt;
import com.simibubi.create.content.logistics.block.display.DisplayLinkContext;
import com.simibubi.create.content.logistics.block.redstone.ContentObserverBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.SmartObserverBlockEntity;
import com.simibubi.create.content.logistics.trains.management.display.FlapDisplayBlockEntity;
import com.simibubi.create.content.logistics.trains.management.display.FlapDisplayLayout;
import com.simibubi.create.content.logistics.trains.management.display.FlapDisplaySection;
@ -32,7 +32,7 @@ public class FluidListDisplaySource extends ValueListDisplaySource {
@Override
protected Stream<IntAttached<MutableComponent>> provideEntries(DisplayLinkContext context, int maxRows) {
BlockEntity sourceBE = context.getSourceBlockEntity();
if (!(sourceBE instanceof ContentObserverBlockEntity cobe))
if (!(sourceBE instanceof SmartObserverBlockEntity cobe))
return Stream.empty();
TankManipulationBehaviour tankManipulationBehaviour = cobe.getBehaviour(TankManipulationBehaviour.OBSERVE);

View file

@ -2,7 +2,7 @@ package com.simibubi.create.content.logistics.block.display.source;
import com.simibubi.create.content.logistics.block.display.DisplayLinkContext;
import com.simibubi.create.content.logistics.block.display.target.DisplayTargetStats;
import com.simibubi.create.content.logistics.block.redstone.ContentObserverBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.SmartObserverBlockEntity;
import com.simibubi.create.foundation.blockEntity.behaviour.filtering.FilteringBehaviour;
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.InvManipulationBehaviour;
import com.simibubi.create.foundation.utility.Components;
@ -17,7 +17,7 @@ public class ItemCountDisplaySource extends NumericSingleLineDisplaySource {
@Override
protected MutableComponent provideLine(DisplayLinkContext context, DisplayTargetStats stats) {
BlockEntity sourceBE = context.getSourceBlockEntity();
if (!(sourceBE instanceof ContentObserverBlockEntity cobe))
if (!(sourceBE instanceof SmartObserverBlockEntity cobe))
return ZERO.copy();
InvManipulationBehaviour invManipulationBehaviour = cobe.getBehaviour(InvManipulationBehaviour.TYPE);

View file

@ -3,7 +3,7 @@ package com.simibubi.create.content.logistics.block.display.source;
import java.util.stream.Stream;
import com.simibubi.create.content.logistics.block.display.DisplayLinkContext;
import com.simibubi.create.content.logistics.block.redstone.ContentObserverBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.SmartObserverBlockEntity;
import com.simibubi.create.foundation.blockEntity.behaviour.filtering.FilteringBehaviour;
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.InvManipulationBehaviour;
import com.simibubi.create.foundation.item.CountedItemStackList;
@ -18,7 +18,7 @@ public class ItemListDisplaySource extends ValueListDisplaySource {
@Override
protected Stream<IntAttached<MutableComponent>> provideEntries(DisplayLinkContext context, int maxRows) {
BlockEntity sourceBE = context.getSourceBlockEntity();
if (!(sourceBE instanceof ContentObserverBlockEntity cobe))
if (!(sourceBE instanceof SmartObserverBlockEntity cobe))
return Stream.empty();
InvManipulationBehaviour invManipulationBehaviour = cobe.getBehaviour(InvManipulationBehaviour.TYPE);

View file

@ -343,7 +343,7 @@ public class FunnelBlockEntity extends SmartBlockEntity implements IHaveHovering
}
public void onTransfer(ItemStack stack) {
AllBlocks.CONTENT_OBSERVER.get()
AllBlocks.SMART_OBSERVER.get()
.onFunnelTransfer(level, worldPosition, stack);
award(AllAdvancements.FUNNEL);
}

View file

@ -0,0 +1,98 @@
package com.simibubi.create.content.logistics.block.redstone;
import javax.annotation.Nullable;
import com.simibubi.create.content.contraptions.components.structureMovement.ITransformableBlock;
import com.simibubi.create.content.contraptions.components.structureMovement.StructureTransform;
import com.simibubi.create.content.contraptions.wrench.IWrenchable;
import net.minecraft.core.Direction;
import net.minecraft.core.Direction.Axis;
import net.minecraft.core.Direction.AxisDirection;
import net.minecraft.world.item.context.BlockPlaceContext;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.HorizontalDirectionalBlock;
import net.minecraft.world.level.block.state.BlockState;
import net.minecraft.world.level.block.state.StateDefinition.Builder;
import net.minecraft.world.level.block.state.properties.AttachFace;
import net.minecraft.world.level.block.state.properties.EnumProperty;
public class DirectedDirectionalBlock extends HorizontalDirectionalBlock implements IWrenchable, ITransformableBlock {
public static final EnumProperty<AttachFace> TARGET = EnumProperty.create("target", AttachFace.class);
public DirectedDirectionalBlock(Properties pProperties) {
super(pProperties);
registerDefaultState(defaultBlockState().setValue(TARGET, AttachFace.WALL));
}
@Override
protected void createBlockStateDefinition(Builder<Block, BlockState> pBuilder) {
super.createBlockStateDefinition(pBuilder.add(TARGET, FACING));
}
@Nullable
public BlockState getStateForPlacement(BlockPlaceContext pContext) {
for (Direction direction : pContext.getNearestLookingDirections()) {
BlockState blockstate;
if (direction.getAxis() == Direction.Axis.Y) {
blockstate = this.defaultBlockState()
.setValue(TARGET, direction == Direction.UP ? AttachFace.CEILING : AttachFace.FLOOR)
.setValue(FACING, pContext.getHorizontalDirection());
} else {
blockstate = this.defaultBlockState()
.setValue(TARGET, AttachFace.WALL)
.setValue(FACING, direction.getOpposite());
}
return blockstate;
}
return null;
}
protected static Direction getTargetDirection(BlockState pState) {
switch ((AttachFace) pState.getValue(TARGET)) {
case CEILING:
return Direction.UP;
case FLOOR:
return Direction.DOWN;
default:
return pState.getValue(FACING);
}
}
@Override
public BlockState getRotatedBlockState(BlockState originalState, Direction targetedFace) {
if (targetedFace.getAxis() == Axis.Y)
return IWrenchable.super.getRotatedBlockState(originalState, targetedFace);
Direction targetDirection = getTargetDirection(originalState);
Direction newFacing = targetDirection.getClockWise(targetedFace.getAxis());
if (targetedFace.getAxisDirection() == AxisDirection.NEGATIVE)
newFacing = newFacing.getOpposite();
if (newFacing.getAxis() == Axis.Y)
return originalState.setValue(TARGET, newFacing == Direction.UP ? AttachFace.CEILING : AttachFace.FLOOR);
return originalState.setValue(TARGET, AttachFace.WALL)
.setValue(FACING, newFacing);
}
@Override
@SuppressWarnings("deprecation")
public BlockState transform(BlockState state, StructureTransform transform) {
if (transform.mirror != null)
state = mirror(state, transform.mirror);
if (transform.rotationAxis == Direction.Axis.Y)
return rotate(state, transform.rotation);
Direction targetDirection = getTargetDirection(state);
Direction newFacing = transform.rotateFacing(targetDirection);
if (newFacing.getAxis() == Axis.Y)
return state.setValue(TARGET, newFacing == Direction.UP ? AttachFace.CEILING : AttachFace.FLOOR);
return state.setValue(TARGET, AttachFace.WALL)
.setValue(FACING, newFacing);
}
}

View file

@ -6,24 +6,54 @@ import com.simibubi.create.foundation.blockEntity.behaviour.ValueBoxTransform;
import com.simibubi.create.foundation.utility.AngleHelper;
import com.simibubi.create.foundation.utility.VecHelper;
import net.minecraft.world.level.block.HorizontalDirectionalBlock;
import net.minecraft.core.Direction;
import net.minecraft.core.Direction.Axis;
import net.minecraft.world.level.block.state.BlockState;
import net.minecraft.world.phys.Vec3;
public class FilteredDetectorFilterSlot extends ValueBoxTransform {
Vec3 position = VecHelper.voxelSpace(8f, 15.5f, 11f);
public class FilteredDetectorFilterSlot extends ValueBoxTransform.Sided {
private boolean hasSlotAtBottom;
public FilteredDetectorFilterSlot(boolean hasSlotAtBottom) {
this.hasSlotAtBottom = hasSlotAtBottom;
}
@Override
protected Vec3 getLocalOffset(BlockState state) {
return rotateHorizontally(state, position);
protected boolean isSideActive(BlockState state, Direction direction) {
Direction targetDirection = DirectedDirectionalBlock.getTargetDirection(state);
if (direction == targetDirection)
return false;
if (targetDirection.getOpposite() == direction)
return true;
if (targetDirection.getAxis() != Axis.Y)
return direction == Direction.UP || direction == Direction.DOWN && hasSlotAtBottom;
if (targetDirection == Direction.UP)
direction = direction.getOpposite();
if (!hasSlotAtBottom)
return direction == state.getValue(DirectedDirectionalBlock.FACING);
return direction.getAxis() == state.getValue(DirectedDirectionalBlock.FACING)
.getClockWise()
.getAxis();
}
@Override
protected void rotate(BlockState state, PoseStack ms) {
float yRot = AngleHelper.horizontalAngle(state.getValue(HorizontalDirectionalBlock.FACING)) + 180;
super.rotate(state, ms);
Direction facing = state.getValue(DirectedDirectionalBlock.FACING);
if (facing.getAxis() == Axis.Y)
return;
if (getSide() != Direction.UP)
return;
TransformStack.cast(ms)
.rotateY(yRot)
.rotateX(90);
.rotateZ(-AngleHelper.horizontalAngle(facing) + 180);
}
@Override
protected Vec3 getSouthLocation() {
return VecHelper.voxelSpace(8f, 8f, 15.5f);
}
}

View file

@ -4,9 +4,7 @@ import java.util.Random;
import com.simibubi.create.AllBlockEntityTypes;
import com.simibubi.create.AllBlocks;
import com.simibubi.create.AllShapes;
import com.simibubi.create.content.contraptions.fluids.FluidTransportBehaviour;
import com.simibubi.create.content.contraptions.wrench.IWrenchable;
import com.simibubi.create.content.logistics.block.funnel.FunnelBlockEntity;
import com.simibubi.create.foundation.block.IBE;
import com.simibubi.create.foundation.blockEntity.BlockEntityBehaviour;
@ -17,46 +15,38 @@ import com.simibubi.create.foundation.utility.Iterate;
import net.minecraft.core.BlockPos;
import net.minecraft.core.Direction;
import net.minecraft.core.Direction.Axis;
import net.minecraft.server.level.ServerLevel;
import net.minecraft.world.item.ItemStack;
import net.minecraft.world.item.context.BlockPlaceContext;
import net.minecraft.world.level.BlockGetter;
import net.minecraft.world.level.Level;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.HorizontalDirectionalBlock;
import net.minecraft.world.level.block.entity.BlockEntity;
import net.minecraft.world.level.block.entity.BlockEntityType;
import net.minecraft.world.level.block.state.BlockState;
import net.minecraft.world.level.block.state.StateDefinition.Builder;
import net.minecraft.world.level.block.state.properties.AttachFace;
import net.minecraft.world.level.block.state.properties.BlockStateProperties;
import net.minecraft.world.level.block.state.properties.BooleanProperty;
import net.minecraft.world.phys.shapes.CollisionContext;
import net.minecraft.world.phys.shapes.VoxelShape;
import net.minecraftforge.common.capabilities.Capability;
import net.minecraftforge.fluids.capability.CapabilityFluidHandler;
import net.minecraftforge.fluids.capability.IFluidHandler;
import net.minecraftforge.items.CapabilityItemHandler;
import net.minecraftforge.items.IItemHandler;
public class ContentObserverBlock extends HorizontalDirectionalBlock implements IBE<ContentObserverBlockEntity>, IWrenchable {
public class SmartObserverBlock extends DirectedDirectionalBlock implements IBE<SmartObserverBlockEntity> {
public static final BooleanProperty POWERED = BlockStateProperties.POWERED;
public ContentObserverBlock(Properties properties) {
public SmartObserverBlock(Properties properties) {
super(properties);
registerDefaultState(defaultBlockState().setValue(POWERED, false));
}
@Override
public VoxelShape getShape(BlockState state, BlockGetter p_220053_2_, BlockPos p_220053_3_,
CollisionContext p_220053_4_) {
return AllShapes.CONTENT_OBSERVER.get(state.getValue(FACING));
}
@Override
protected void createBlockStateDefinition(Builder<Block, BlockState> builder) {
builder.add(POWERED, FACING);
super.createBlockStateDefinition(builder);
super.createBlockStateDefinition(builder.add(POWERED));
}
@Override
@ -66,7 +56,7 @@ public class ContentObserverBlock extends HorizontalDirectionalBlock implements
Capability<IFluidHandler> fluidCap = CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY;
Direction preferredFacing = null;
for (Direction face : Iterate.horizontalDirections) {
for (Direction face : context.getNearestLookingDirections()) {
BlockPos offsetPos = context.getClickedPos()
.relative(face);
Level world = context.getLevel();
@ -86,19 +76,23 @@ public class ContentObserverBlock extends HorizontalDirectionalBlock implements
canDetect = true;
if (canDetect) {
if (preferredFacing != null) {
preferredFacing = null;
break;
}
preferredFacing = face;
break;
}
}
if (preferredFacing != null)
return state.setValue(FACING, preferredFacing);
return state.setValue(FACING, context.getHorizontalDirection()
.getOpposite());
if (preferredFacing == null) {
Direction facing = context.getNearestLookingDirection();
preferredFacing = context.getPlayer() != null && context.getPlayer()
.isSteppingCarefully() ? facing : facing.getOpposite();
}
if (preferredFacing.getAxis() == Axis.Y) {
state = state.setValue(TARGET, preferredFacing == Direction.UP ? AttachFace.CEILING : AttachFace.FLOOR);
preferredFacing = context.getHorizontalDirection();
}
return state.setValue(FACING, preferredFacing);
}
@Override
@ -141,7 +135,7 @@ public class ContentObserverBlock extends HorizontalDirectionalBlock implements
for (Direction direction : Iterate.horizontalDirections) {
BlockPos detectorPos = funnelPos.relative(direction);
BlockState detectorState = world.getBlockState(detectorPos);
if (!AllBlocks.CONTENT_OBSERVER.has(detectorState))
if (!AllBlocks.SMART_OBSERVER.has(detectorState))
continue;
if (detectorState.getValue(FACING) != direction.getOpposite())
continue;
@ -157,13 +151,13 @@ public class ContentObserverBlock extends HorizontalDirectionalBlock implements
}
@Override
public Class<ContentObserverBlockEntity> getBlockEntityClass() {
return ContentObserverBlockEntity.class;
public Class<SmartObserverBlockEntity> getBlockEntityClass() {
return SmartObserverBlockEntity.class;
}
@Override
public BlockEntityType<? extends ContentObserverBlockEntity> getBlockEntityType() {
return AllBlockEntityTypes.CONTENT_OBSERVER.get();
public BlockEntityType<? extends SmartObserverBlockEntity> getBlockEntityType() {
return AllBlockEntityTypes.SMART_OBSERVER.get();
}
}

View file

@ -12,15 +12,18 @@ import com.simibubi.create.foundation.blockEntity.behaviour.filtering.FilteringB
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.CapManipulationBehaviourBase.InterfaceProvider;
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.InvManipulationBehaviour;
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.TankManipulationBehaviour;
import com.simibubi.create.foundation.utility.BlockFace;
import com.simibubi.create.foundation.utility.Iterate;
import net.minecraft.core.BlockPos;
import net.minecraft.core.Direction;
import net.minecraft.nbt.CompoundTag;
import net.minecraft.world.item.ItemStack;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.entity.BlockEntityType;
import net.minecraft.world.level.block.state.BlockState;
public class ContentObserverBlockEntity extends SmartBlockEntity {
public class SmartObserverBlockEntity extends SmartBlockEntity {
private static final int DEFAULT_DELAY = 6;
private FilteringBehaviour filtering;
@ -28,17 +31,18 @@ public class ContentObserverBlockEntity extends SmartBlockEntity {
private TankManipulationBehaviour observedTank;
public int turnOffTicks = 0;
public ContentObserverBlockEntity(BlockEntityType<?> type, BlockPos pos, BlockState state) {
public SmartObserverBlockEntity(BlockEntityType<?> type, BlockPos pos, BlockState state) {
super(type, pos, state);
setLazyTickRate(20);
}
@Override
public void addBehaviours(List<BlockEntityBehaviour> behaviours) {
filtering = new FilteringBehaviour(this, new FilteredDetectorFilterSlot());
behaviours.add(filtering);
behaviours.add(filtering = new FilteringBehaviour(this, new FilteredDetectorFilterSlot(false)));
InterfaceProvider towardBlockFacing =
(w, p, s) -> new BlockFace(p, DirectedDirectionalBlock.getTargetDirection(s));
InterfaceProvider towardBlockFacing = InterfaceProvider.towardBlockFacing();
behaviours.add(observedInventory = new InvManipulationBehaviour(this, towardBlockFacing).bypassSidedness());
behaviours.add(observedTank = new TankManipulationBehaviour(this, towardBlockFacing).bypassSidedness());
}
@ -56,8 +60,15 @@ public class ContentObserverBlockEntity extends SmartBlockEntity {
if (!isActive())
return;
Direction facing = state.getValue(ContentObserverBlock.FACING);
BlockPos targetPos = worldPosition.relative(facing);
BlockPos targetPos = worldPosition.relative(SmartObserverBlock.getTargetDirection(state));
Block block = level.getBlockState(targetPos)
.getBlock();
if (!filtering.getFilter()
.isEmpty() && block.asItem() != null && filtering.test(new ItemStack(block))) {
activate(3);
return;
}
// Detect items on belt
TransportedItemStackHandlerBehaviour behaviour =
@ -110,9 +121,9 @@ public class ContentObserverBlockEntity extends SmartBlockEntity {
public void activate(int ticks) {
BlockState state = getBlockState();
turnOffTicks = ticks;
if (state.getValue(ContentObserverBlock.POWERED))
if (state.getValue(SmartObserverBlock.POWERED))
return;
level.setBlockAndUpdate(worldPosition, state.setValue(ContentObserverBlock.POWERED, true));
level.setBlockAndUpdate(worldPosition, state.setValue(SmartObserverBlock.POWERED, true));
level.updateNeighborsAt(worldPosition, state.getBlock());
}

View file

@ -0,0 +1,35 @@
package com.simibubi.create.content.logistics.block.redstone;
import com.simibubi.create.foundation.data.AssetLookup;
import com.simibubi.create.foundation.data.SpecialBlockStateGen;
import com.tterrag.registrate.providers.DataGenContext;
import com.tterrag.registrate.providers.RegistrateBlockstateProvider;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.state.BlockState;
import net.minecraftforge.client.model.generators.ModelFile;
public class SmartObserverGenerator extends SpecialBlockStateGen {
@Override
protected int getXRotation(BlockState state) {
return switch (state.getValue(SmartObserverBlock.TARGET)) {
case CEILING -> -90;
case WALL -> 0;
case FLOOR -> 90;
};
}
@Override
protected int getYRotation(BlockState state) {
return horizontalAngle(state.getValue(ThresholdSwitchBlock.FACING)) + 180;
}
@Override
public <T extends Block> ModelFile getModel(DataGenContext<Block, T> ctx, RegistrateBlockstateProvider prov,
BlockState state) {
return AssetLookup.forPowered(ctx, prov)
.apply(state);
}
}

View file

@ -4,15 +4,13 @@ import java.util.Random;
import com.simibubi.create.AllBlockEntityTypes;
import com.simibubi.create.AllItems;
import com.simibubi.create.AllShapes;
import com.simibubi.create.content.contraptions.wrench.IWrenchable;
import com.simibubi.create.foundation.block.IBE;
import com.simibubi.create.foundation.gui.ScreenOpener;
import com.simibubi.create.foundation.utility.Iterate;
import net.minecraft.client.player.LocalPlayer;
import net.minecraft.core.BlockPos;
import net.minecraft.core.Direction;
import net.minecraft.core.Direction.Axis;
import net.minecraft.server.level.ServerLevel;
import net.minecraft.world.InteractionHand;
import net.minecraft.world.InteractionResult;
@ -22,15 +20,13 @@ import net.minecraft.world.level.BlockGetter;
import net.minecraft.world.level.Level;
import net.minecraft.world.level.LevelReader;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.HorizontalDirectionalBlock;
import net.minecraft.world.level.block.entity.BlockEntity;
import net.minecraft.world.level.block.entity.BlockEntityType;
import net.minecraft.world.level.block.state.BlockState;
import net.minecraft.world.level.block.state.StateDefinition.Builder;
import net.minecraft.world.level.block.state.properties.AttachFace;
import net.minecraft.world.level.block.state.properties.IntegerProperty;
import net.minecraft.world.phys.BlockHitResult;
import net.minecraft.world.phys.shapes.CollisionContext;
import net.minecraft.world.phys.shapes.VoxelShape;
import net.minecraftforge.api.distmarker.Dist;
import net.minecraftforge.api.distmarker.OnlyIn;
import net.minecraftforge.common.capabilities.Capability;
@ -40,12 +36,11 @@ import net.minecraftforge.fml.DistExecutor;
import net.minecraftforge.items.CapabilityItemHandler;
import net.minecraftforge.items.IItemHandler;
public class StockpileSwitchBlock extends HorizontalDirectionalBlock
implements IBE<StockpileSwitchBlockEntity>, IWrenchable {
public class ThresholdSwitchBlock extends DirectedDirectionalBlock implements IBE<ThresholdSwitchBlockEntity> {
public static final IntegerProperty INDICATOR = IntegerProperty.create("indicator", 0, 6);
public static final IntegerProperty LEVEL = IntegerProperty.create("level", 0, 5);
public StockpileSwitchBlock(Properties p_i48377_1_) {
public ThresholdSwitchBlock(Properties p_i48377_1_) {
super(p_i48377_1_);
}
@ -54,23 +49,8 @@ public class StockpileSwitchBlock extends HorizontalDirectionalBlock
updateObservedInventory(state, worldIn, pos);
}
@Override
public void onNeighborChange(BlockState state, LevelReader world, BlockPos pos, BlockPos neighbor) {
// if (world.isClientSide())
// return;
// if (!isObserving(state, pos, neighbor))
// return;
// updateObservedInventory(state, world, pos);
}
@Override
public VoxelShape getShape(BlockState state, BlockGetter p_220053_2_, BlockPos p_220053_3_,
CollisionContext p_220053_4_) {
return AllShapes.STOCKPILE_SWITCH.get(state.getValue(FACING));
}
private void updateObservedInventory(BlockState state, LevelReader world, BlockPos pos) {
withBlockEntityDo(world, pos, StockpileSwitchBlockEntity::updateCurrentLevel);
withBlockEntityDo(world, pos, ThresholdSwitchBlockEntity::updateCurrentLevel);
}
@Override
@ -88,20 +68,19 @@ public class StockpileSwitchBlock extends HorizontalDirectionalBlock
if (side == blockState.getValue(FACING)
.getOpposite())
return 0;
return getBlockEntityOptional(blockAccess, pos).filter(StockpileSwitchBlockEntity::isPowered)
return getBlockEntityOptional(blockAccess, pos).filter(ThresholdSwitchBlockEntity::isPowered)
.map($ -> 15)
.orElse(0);
}
@Override
public void tick(BlockState blockState, ServerLevel world, BlockPos pos, Random random) {
getBlockEntityOptional(world, pos).ifPresent(StockpileSwitchBlockEntity::updatePowerAfterDelay);
getBlockEntityOptional(world, pos).ifPresent(ThresholdSwitchBlockEntity::updatePowerAfterDelay);
}
@Override
protected void createBlockStateDefinition(Builder<Block, BlockState> builder) {
builder.add(FACING, INDICATOR);
super.createBlockStateDefinition(builder);
super.createBlockStateDefinition(builder.add(LEVEL));
}
@Override
@ -115,9 +94,9 @@ public class StockpileSwitchBlock extends HorizontalDirectionalBlock
}
@OnlyIn(value = Dist.CLIENT)
protected void displayScreen(StockpileSwitchBlockEntity be, Player player) {
protected void displayScreen(ThresholdSwitchBlockEntity be, Player player) {
if (player instanceof LocalPlayer)
ScreenOpener.open(new StockpileSwitchScreen(be));
ScreenOpener.open(new ThresholdSwitchScreen(be));
}
@Override
@ -127,42 +106,41 @@ public class StockpileSwitchBlock extends HorizontalDirectionalBlock
Capability<IFluidHandler> fluidCap = CapabilityFluidHandler.FLUID_HANDLER_CAPABILITY;
Direction preferredFacing = null;
for (Direction face : Iterate.horizontalDirections) {
for (Direction face : context.getNearestLookingDirections()) {
BlockEntity be = context.getLevel()
.getBlockEntity(context.getClickedPos()
.relative(face));
if (be != null && (be.getCapability(itemCap)
.isPresent()
|| be.getCapability(fluidCap)
.isPresent()))
if (preferredFacing == null)
preferredFacing = face;
else {
preferredFacing = null;
break;
}
.isPresent())) {
preferredFacing = face;
break;
}
}
if (preferredFacing != null)
return state.setValue(FACING, preferredFacing);
if (preferredFacing == null) {
Direction facing = context.getNearestLookingDirection();
preferredFacing = context.getPlayer() != null && context.getPlayer()
.isSteppingCarefully() ? facing : facing.getOpposite();
}
Direction facing = context.getClickedFace()
.getAxis()
.isHorizontal() ? context.getClickedFace()
: context.getHorizontalDirection()
.getOpposite();
return state.setValue(FACING, context.getPlayer() != null && context.getPlayer()
.isSteppingCarefully() ? facing.getOpposite() : facing);
if (preferredFacing.getAxis() == Axis.Y) {
state = state.setValue(TARGET, preferredFacing == Direction.UP ? AttachFace.CEILING : AttachFace.FLOOR);
preferredFacing = context.getHorizontalDirection();
}
return state.setValue(FACING, preferredFacing);
}
@Override
public Class<StockpileSwitchBlockEntity> getBlockEntityClass() {
return StockpileSwitchBlockEntity.class;
public Class<ThresholdSwitchBlockEntity> getBlockEntityClass() {
return ThresholdSwitchBlockEntity.class;
}
@Override
public BlockEntityType<? extends StockpileSwitchBlockEntity> getBlockEntityType() {
return AllBlockEntityTypes.STOCKPILE_SWITCH.get();
public BlockEntityType<? extends ThresholdSwitchBlockEntity> getBlockEntityType() {
return AllBlockEntityTypes.THRESHOLD_SWITCH.get();
}
}

View file

@ -10,9 +10,9 @@ import com.simibubi.create.foundation.blockEntity.behaviour.filtering.FilteringB
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.CapManipulationBehaviourBase.InterfaceProvider;
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.InvManipulationBehaviour;
import com.simibubi.create.foundation.blockEntity.behaviour.inventory.TankManipulationBehaviour;
import com.simibubi.create.foundation.utility.BlockFace;
import net.minecraft.core.BlockPos;
import net.minecraft.core.Direction;
import net.minecraft.nbt.CompoundTag;
import net.minecraft.util.Mth;
import net.minecraft.world.item.ItemStack;
@ -25,7 +25,7 @@ import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.capability.IFluidHandler;
import net.minecraftforge.items.IItemHandler;
public class StockpileSwitchBlockEntity extends SmartBlockEntity {
public class ThresholdSwitchBlockEntity extends SmartBlockEntity {
public float onWhenAbove;
public float offWhenBelow;
@ -38,7 +38,7 @@ public class StockpileSwitchBlockEntity extends SmartBlockEntity {
private InvManipulationBehaviour observedInventory;
private TankManipulationBehaviour observedTank;
public StockpileSwitchBlockEntity(BlockEntityType<?> type, BlockPos pos, BlockState state) {
public ThresholdSwitchBlockEntity(BlockEntityType<?> type, BlockPos pos, BlockState state) {
super(type, pos, state);
onWhenAbove = .75f;
offWhenBelow = .25f;
@ -94,11 +94,10 @@ public class StockpileSwitchBlockEntity extends SmartBlockEntity {
observedInventory.findNewCapability();
observedTank.findNewCapability();
BlockPos target = worldPosition.relative(getBlockState().getOptionalValue(StockpileSwitchBlock.FACING)
.orElse(Direction.NORTH));
BlockPos target = worldPosition.relative(ThresholdSwitchBlock.getTargetDirection(getBlockState()));
BlockEntity targetBlockEntity = level.getBlockEntity(target);
if (targetBlockEntity instanceof StockpileSwitchObservable observable) {
if (targetBlockEntity instanceof ThresholdSwitchObservable observable) {
currentLevel = observable.getPercent() / 100f;
} else if (StorageDrawers.isDrawer(targetBlockEntity) && observedInventory.hasInventory()) {
@ -143,7 +142,7 @@ public class StockpileSwitchBlockEntity extends SmartBlockEntity {
// No compatible inventories found
if (currentLevel == -1)
return;
level.setBlock(worldPosition, getBlockState().setValue(StockpileSwitchBlock.INDICATOR, 0), 3);
level.setBlock(worldPosition, getBlockState().setValue(ThresholdSwitchBlock.LEVEL, 0), 3);
currentLevel = -1;
redstoneState = false;
sendData();
@ -163,8 +162,8 @@ public class StockpileSwitchBlockEntity extends SmartBlockEntity {
int displayLevel = 0;
if (currentLevel > 0)
displayLevel = (int) (currentLevel * 6);
level.setBlock(worldPosition, getBlockState().setValue(StockpileSwitchBlock.INDICATOR, displayLevel),
displayLevel = (int) (1 + currentLevel * 4);
level.setBlock(worldPosition, getBlockState().setValue(ThresholdSwitchBlock.LEVEL, displayLevel),
update ? 3 : 2);
if (update)
@ -193,11 +192,12 @@ public class StockpileSwitchBlockEntity extends SmartBlockEntity {
@Override
public void addBehaviours(List<BlockEntityBehaviour> behaviours) {
filtering =
new FilteringBehaviour(this, new FilteredDetectorFilterSlot()).withCallback($ -> this.updateCurrentLevel());
behaviours.add(filtering);
behaviours.add(filtering = new FilteringBehaviour(this, new FilteredDetectorFilterSlot(true))
.withCallback($ -> this.updateCurrentLevel()));
InterfaceProvider towardBlockFacing =
(w, p, s) -> new BlockFace(p, DirectedDirectionalBlock.getTargetDirection(s));
InterfaceProvider towardBlockFacing = InterfaceProvider.towardBlockFacing();
behaviours.add(observedInventory = new InvManipulationBehaviour(this, towardBlockFacing).bypassSidedness());
behaviours.add(observedTank = new TankManipulationBehaviour(this, towardBlockFacing).bypassSidedness());
}

View file

@ -0,0 +1,36 @@
package com.simibubi.create.content.logistics.block.redstone;
import com.simibubi.create.Create;
import com.simibubi.create.foundation.data.SpecialBlockStateGen;
import com.simibubi.create.foundation.utility.Lang;
import com.tterrag.registrate.providers.DataGenContext;
import com.tterrag.registrate.providers.RegistrateBlockstateProvider;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.state.BlockState;
import net.minecraftforge.client.model.generators.ModelFile;
public class ThresholdSwitchGenerator extends SpecialBlockStateGen {
@Override
protected int getXRotation(BlockState state) {
return 0;
}
@Override
protected int getYRotation(BlockState state) {
return horizontalAngle(state.getValue(ThresholdSwitchBlock.FACING)) + 180;
}
@Override
public <T extends Block> ModelFile getModel(DataGenContext<Block, T> ctx, RegistrateBlockstateProvider prov,
BlockState state) {
int level = state.getValue(ThresholdSwitchBlock.LEVEL);
String path = "threshold_switch/block_" + Lang.asId(state.getValue(ThresholdSwitchBlock.TARGET)
.name());
return prov.models()
.withExistingParent(path + "_" + level, Create.asResource("block/" + path))
.texture("level", Create.asResource("block/threshold_switch/level_" + level));
}
}

View file

@ -1,6 +1,6 @@
package com.simibubi.create.content.logistics.block.redstone;
public interface StockpileSwitchObservable {
public interface ThresholdSwitchObservable {
public float getPercent();

View file

@ -18,25 +18,25 @@ import com.simibubi.create.foundation.utility.animation.LerpedFloat.Chaser;
import net.minecraft.network.chat.Component;
import net.minecraft.world.item.ItemStack;
public class StockpileSwitchScreen extends AbstractSimiScreen {
public class ThresholdSwitchScreen extends AbstractSimiScreen {
private ScrollInput offBelow;
private ScrollInput onAbove;
private IconButton confirmButton;
private IconButton flipSignals;
private final Component invertSignal = Lang.translateDirect("gui.stockpile_switch.invert_signal");
private final ItemStack renderedItem = new ItemStack(AllBlocks.STOCKPILE_SWITCH.get());
private final Component invertSignal = Lang.translateDirect("gui.threshold_switch.invert_signal");
private final ItemStack renderedItem = new ItemStack(AllBlocks.THRESHOLD_SWITCH.get());
private AllGuiTextures background;
private StockpileSwitchBlockEntity blockEntity;
private ThresholdSwitchBlockEntity blockEntity;
private int lastModification;
private LerpedFloat cursor;
private LerpedFloat cursorLane;
public StockpileSwitchScreen(StockpileSwitchBlockEntity be) {
super(Lang.translateDirect("gui.stockpile_switch.title"));
public ThresholdSwitchScreen(ThresholdSwitchBlockEntity be) {
super(Lang.translateDirect("gui.threshold_switch.title"));
background = AllGuiTextures.STOCKSWITCH;
this.blockEntity = be;
lastModification = -1;
@ -56,11 +56,11 @@ public class StockpileSwitchScreen extends AbstractSimiScreen {
cursorLane = LerpedFloat.linear()
.startWithValue(blockEntity.getState() ? 1 : 0);
offBelow = new ScrollInput(x + 36, y + 40, 102, 18).withRange(0, 100)
offBelow = new ScrollInput(x + 36, y + 42, 102, 18).withRange(0, 100)
.titled(Components.empty())
.calling(state -> {
lastModification = 0;
offBelow.titled(Lang.translateDirect("gui.stockpile_switch.move_to_upper_at", state));
offBelow.titled(Lang.translateDirect("gui.threshold_switch.move_to_upper_at", state));
if (onAbove.getState() <= state) {
onAbove.setState(state + 1);
onAbove.onChanged();
@ -68,11 +68,11 @@ public class StockpileSwitchScreen extends AbstractSimiScreen {
})
.setState((int) (blockEntity.offWhenBelow * 100));
onAbove = new ScrollInput(x + 36, y + 18, 102, 18).withRange(1, 101)
onAbove = new ScrollInput(x + 36, y + 20, 102, 18).withRange(1, 101)
.titled(Components.empty())
.calling(state -> {
lastModification = 0;
onAbove.titled(Lang.translateDirect("gui.stockpile_switch.move_to_lower_at", state));
onAbove.titled(Lang.translateDirect("gui.threshold_switch.move_to_lower_at", state));
if (offBelow.getState() >= state) {
offBelow.setState(state - 1);
offBelow.onChanged();
@ -86,14 +86,13 @@ public class StockpileSwitchScreen extends AbstractSimiScreen {
addRenderableWidget(onAbove);
addRenderableWidget(offBelow);
confirmButton =
new IconButton(x + background.width - 33, y + background.height - 24, AllIcons.I_CONFIRM);
confirmButton = new IconButton(x + background.width - 33, y + background.height - 24, AllIcons.I_CONFIRM);
confirmButton.withCallback(() -> {
onClose();
});
addRenderableWidget(confirmButton);
flipSignals = new IconButton(x + 14, y + 40, AllIcons.I_FLIP);
flipSignals = new IconButton(x + background.width - 62, y + background.height - 24, AllIcons.I_FLIP);
flipSignals.withCallback(() -> {
send(!blockEntity.isInverted());
});
@ -108,35 +107,35 @@ public class StockpileSwitchScreen extends AbstractSimiScreen {
background.render(ms, x, y, this);
AllGuiTextures.STOCKSWITCH_POWERED_LANE.render(ms, x + 36, y + (blockEntity.isInverted() ? 18 : 40), this);
AllGuiTextures.STOCKSWITCH_UNPOWERED_LANE.render(ms, x + 36, y + (blockEntity.isInverted() ? 40 : 18), this);
drawCenteredString(ms, font, title, x + (background.width - 8) / 2, y + 3, 0xFFFFFF);
AllGuiTextures.STOCKSWITCH_POWERED_LANE.render(ms, x + 37, y + (blockEntity.isInverted() ? 20 : 42), this);
AllGuiTextures.STOCKSWITCH_UNPOWERED_LANE.render(ms, x + 37, y + (blockEntity.isInverted() ? 42 : 20), this);
font.draw(ms, title, x + (background.width - 8) / 2 - font.width(title) / 2, y + 4, 0x592424);
AllGuiTextures sprite = AllGuiTextures.STOCKSWITCH_INTERVAL;
float lowerBound = offBelow.getState();
float upperBound = onAbove.getState();
sprite.bind();
blit(ms, (int) (x + upperBound) + 37, y + 18, (int) (sprite.startX + upperBound), sprite.startY,
blit(ms, (int) (x + upperBound) + 37, y + 20, (int) (sprite.startX + upperBound), sprite.startY,
(int) (sprite.width - upperBound), sprite.height);
blit(ms, x + 37, y + 40, sprite.startX, sprite.startY, (int) (lowerBound), sprite.height);
blit(ms, x + 37, y + 42, sprite.startX, sprite.startY, (int) (lowerBound), sprite.height);
AllGuiTextures.STOCKSWITCH_ARROW_UP.render(ms, (int) (x + lowerBound + 36) - 2, y + 35, this);
AllGuiTextures.STOCKSWITCH_ARROW_DOWN.render(ms, (int) (x + upperBound + 36) - 3, y + 17, this);
AllGuiTextures.STOCKSWITCH_ARROW_UP.render(ms, (int) (x + lowerBound + 36) - 2, y + 37, this);
AllGuiTextures.STOCKSWITCH_ARROW_DOWN.render(ms, (int) (x + upperBound + 36) - 3, y + 19, this);
if (blockEntity.currentLevel != -1) {
AllGuiTextures cursor = AllGuiTextures.STOCKSWITCH_CURSOR;
ms.pushPose();
ms.translate(Math.min(99, this.cursor.getValue(partialTicks) * sprite.width),
cursorLane.getValue(partialTicks) * 22, 0);
cursor.render(ms, x + 34, y + 19, this);
cursor.render(ms, x + 34, y + 21, this);
ms.popPose();
}
GuiGameElement.of(renderedItem)
.<GuiGameElement.GuiRenderBuilder>at(x + background.width + 6, y + background.height - 56, -200)
.scale(5)
.render(ms);
GuiGameElement.of(renderedItem).<GuiGameElement
.GuiRenderBuilder>at(x + background.width + 6, y + background.height - 56, -200)
.scale(5)
.render(ms);
}
@Override
@ -163,8 +162,9 @@ public class StockpileSwitchScreen extends AbstractSimiScreen {
}
protected void send(boolean invert) {
AllPackets.getChannel().sendToServer(new ConfigureStockswitchPacket(blockEntity.getBlockPos(), offBelow.getState() / 100f,
onAbove.getState() / 100f, invert));
AllPackets.getChannel()
.sendToServer(new ConfigureStockswitchPacket(blockEntity.getBlockPos(), offBelow.getState() / 100f,
onAbove.getState() / 100f, invert));
}
}

View file

@ -70,7 +70,7 @@ public class LinkedControllerScreen extends AbstractSimiContainerScreen<LinkedCo
int y = topPos;
background.render(ms, x, y, this);
font.draw(ms, title, x + 15, y + 4, 0x442000);
font.draw(ms, title, x + 15, y + 4, 0x592424);
GuiGameElement.of(menu.contentHolder).<GuiGameElement
.GuiRenderBuilder>at(x + background.width - 4, y + background.height - 56, -200)

View file

@ -7,6 +7,7 @@ import java.util.List;
import com.google.common.collect.ImmutableList;
import com.mojang.blaze3d.vertex.PoseStack;
import com.simibubi.create.AllItems;
import com.simibubi.create.content.logistics.item.filter.FilterScreenPacket.Option;
import com.simibubi.create.foundation.gui.AllGuiTextures;
import com.simibubi.create.foundation.gui.AllIcons;
@ -27,7 +28,7 @@ import net.minecraft.world.entity.player.Inventory;
public abstract class AbstractFilterScreen<F extends AbstractFilterMenu> extends AbstractSimiContainerScreen<F> {
protected AllGuiTextures background;
private List<Rect2i> extraAreas = Collections.emptyList();
private List<Rect2i> extraAreas = Collections.emptyList();
private IconButton resetButton;
private IconButton confirmButton;
@ -39,7 +40,8 @@ public abstract class AbstractFilterScreen<F extends AbstractFilterMenu> extends
@Override
protected void init() {
setWindowSize(Math.max(background.width, PLAYER_INVENTORY.width), background.height + 4 + PLAYER_INVENTORY.height);
setWindowSize(Math.max(background.width, PLAYER_INVENTORY.width),
background.height + 4 + PLAYER_INVENTORY.height);
super.init();
int x = leftPos;
@ -59,9 +61,7 @@ public abstract class AbstractFilterScreen<F extends AbstractFilterMenu> extends
addRenderableWidget(resetButton);
addRenderableWidget(confirmButton);
extraAreas = ImmutableList.of(
new Rect2i(x + background.width, y + background.height - 40, 80, 48)
);
extraAreas = ImmutableList.of(new Rect2i(x + background.width, y + background.height - 40, 80, 48));
}
@Override
@ -74,18 +74,19 @@ public abstract class AbstractFilterScreen<F extends AbstractFilterMenu> extends
int y = topPos;
background.render(ms, x, y, this);
drawCenteredString(ms, font, title, x + (background.width - 8) / 2, y + 3, 0xFFFFFF);
font.draw(ms, title, x + (background.width - 8) / 2 - font.width(title) / 2, y + 4,
AllItems.FILTER.isIn(menu.contentHolder) ? 0x303030 : 0x592424);
GuiGameElement.of(menu.contentHolder)
.<GuiGameElement.GuiRenderBuilder>at(x + background.width + 8, y + background.height - 52, -200)
.scale(4)
.render(ms);
GuiGameElement.of(menu.contentHolder).<GuiGameElement
.GuiRenderBuilder>at(x + background.width + 8, y + background.height - 52, -200)
.scale(4)
.render(ms);
}
@Override
protected void containerTick() {
if (!menu.player.getMainHandItem()
.equals(menu.contentHolder, false))
.equals(menu.contentHolder, false))
menu.player.closeContainer();
super.containerTick();
@ -147,7 +148,8 @@ public abstract class AbstractFilterScreen<F extends AbstractFilterMenu> extends
protected void contentsCleared() {}
protected void sendOptionUpdate(Option option) {
AllPackets.getChannel().sendToServer(new FilterScreenPacket(option));
AllPackets.getChannel()
.sendToServer(new FilterScreenPacket(option));
}
@Override

View file

@ -63,13 +63,13 @@ public class AttributeFilterMenu extends AbstractFilterMenu {
@Override
protected int getPlayerInventoryYOffset() {
return 105;
return 107;
}
@Override
protected void addFilterSlots() {
this.addSlot(new SlotItemHandler(ghostInventory, 0, 16, 22));
this.addSlot(new SlotItemHandler(ghostInventory, 1, 22, 57) {
this.addSlot(new SlotItemHandler(ghostInventory, 0, 16, 24));
this.addSlot(new SlotItemHandler(ghostInventory, 1, 22, 59) {
@Override
public boolean mayPickup(Player playerIn) {
return false;

View file

@ -67,34 +67,34 @@ public class AttributeFilterScreen extends AbstractFilterScreen<AttributeFilterM
int x = leftPos;
int y = topPos;
whitelistDis = new IconButton(x + 47, y + 59, AllIcons.I_WHITELIST_OR);
whitelistDis = new IconButton(x + 47, y + 61, AllIcons.I_WHITELIST_OR);
whitelistDis.withCallback(() -> {
menu.whitelistMode = WhitelistMode.WHITELIST_DISJ;
sendOptionUpdate(Option.WHITELIST);
});
whitelistDis.setToolTip(allowDisN);
whitelistCon = new IconButton(x + 65, y + 59, AllIcons.I_WHITELIST_AND);
whitelistCon = new IconButton(x + 65, y + 61, AllIcons.I_WHITELIST_AND);
whitelistCon.withCallback(() -> {
menu.whitelistMode = WhitelistMode.WHITELIST_CONJ;
sendOptionUpdate(Option.WHITELIST2);
});
whitelistCon.setToolTip(allowConN);
blacklist = new IconButton(x + 83, y + 59, AllIcons.I_WHITELIST_NOT);
blacklist = new IconButton(x + 83, y + 61, AllIcons.I_WHITELIST_NOT);
blacklist.withCallback(() -> {
menu.whitelistMode = WhitelistMode.BLACKLIST;
sendOptionUpdate(Option.BLACKLIST);
});
blacklist.setToolTip(denyN);
whitelistDisIndicator = new Indicator(x + 47, y + 53, Components.immutableEmpty());
whitelistConIndicator = new Indicator(x + 65, y + 53, Components.immutableEmpty());
blacklistIndicator = new Indicator(x + 83, y + 53, Components.immutableEmpty());
whitelistDisIndicator = new Indicator(x + 47, y + 55, Components.immutableEmpty());
whitelistConIndicator = new Indicator(x + 65, y + 55, Components.immutableEmpty());
blacklistIndicator = new Indicator(x + 83, y + 55, Components.immutableEmpty());
addRenderableWidgets(blacklist, whitelistCon, whitelistDis, blacklistIndicator, whitelistConIndicator,
whitelistDisIndicator);
addRenderableWidget(add = new IconButton(x + 182, y + 21, AllIcons.I_ADD));
addRenderableWidget(addInverted = new IconButton(x + 200, y + 21, AllIcons.I_ADD_INVERTED_ATTRIBUTE));
addRenderableWidget(add = new IconButton(x + 182, y + 23, AllIcons.I_ADD));
addRenderableWidget(addInverted = new IconButton(x + 200, y + 23, AllIcons.I_ADD_INVERTED_ATTRIBUTE));
add.withCallback(() -> {
handleAddedAttibute(false);
});
@ -106,9 +106,9 @@ public class AttributeFilterScreen extends AbstractFilterScreen<AttributeFilterM
handleIndicators();
attributeSelectorLabel = new Label(x + 43, y + 26, Components.immutableEmpty()).colored(0xF3EBDE)
attributeSelectorLabel = new Label(x + 43, y + 28, Components.immutableEmpty()).colored(0xF3EBDE)
.withShadow();
attributeSelector = new SelectionScrollInput(x + 39, y + 21, 137, 18);
attributeSelector = new SelectionScrollInput(x + 39, y + 23, 137, 18);
attributeSelector.forOptions(Arrays.asList(Components.immutableEmpty()));
attributeSelector.removeCallback();
referenceItemChanged(menu.ghostInventory.getStackInSlot(0));
@ -184,7 +184,7 @@ public class AttributeFilterScreen extends AbstractFilterScreen<AttributeFilterM
matrixStack.translate(0.0F, 0.0F, 32.0F);
this.setBlitOffset(150);
this.itemRenderer.blitOffset = 150.0F;
this.itemRenderer.renderGuiItemDecorations(font, stack, leftPos + 22, topPos + 57,
this.itemRenderer.renderGuiItemDecorations(font, stack, leftPos + 22, topPos + 59,
String.valueOf(selectedAttributes.size() - 1));
this.setBlitOffset(0);
this.itemRenderer.blitOffset = 0.0F;

View file

@ -34,13 +34,13 @@ public class FilterMenu extends AbstractFilterMenu {
@Override
protected int getPlayerInventoryYOffset() {
return 119;
return 121;
}
@Override
protected void addFilterSlots() {
int x = 23;
int y = 20;
int y = 22;
for (int row = 0; row < 2; ++row)
for (int col = 0; col < 9; ++col)
this.addSlot(new SlotItemHandler(ghostInventory, col + row * 9, x + col * 18, y + row * 18));

View file

@ -46,36 +46,36 @@ public class FilterScreen extends AbstractFilterScreen<FilterMenu> {
int x = leftPos;
int y = topPos;
blacklist = new IconButton(x + 18, y + 73, AllIcons.I_BLACKLIST);
blacklist = new IconButton(x + 18, y + 75, AllIcons.I_BLACKLIST);
blacklist.withCallback(() -> {
menu.blacklist = true;
sendOptionUpdate(Option.BLACKLIST);
});
blacklist.setToolTip(denyN);
whitelist = new IconButton(x + 36, y + 73, AllIcons.I_WHITELIST);
whitelist = new IconButton(x + 36, y + 75, AllIcons.I_WHITELIST);
whitelist.withCallback(() -> {
menu.blacklist = false;
sendOptionUpdate(Option.WHITELIST);
});
whitelist.setToolTip(allowN);
blacklistIndicator = new Indicator(x + 18, y + 67, Components.immutableEmpty());
whitelistIndicator = new Indicator(x + 36, y + 67, Components.immutableEmpty());
blacklistIndicator = new Indicator(x + 18, y + 69, Components.immutableEmpty());
whitelistIndicator = new Indicator(x + 36, y + 69, Components.immutableEmpty());
addRenderableWidgets(blacklist, whitelist, blacklistIndicator, whitelistIndicator);
respectNBT = new IconButton(x + 60, y + 73, AllIcons.I_RESPECT_NBT);
respectNBT = new IconButton(x + 60, y + 75, AllIcons.I_RESPECT_NBT);
respectNBT.withCallback(() -> {
menu.respectNBT = true;
sendOptionUpdate(Option.RESPECT_DATA);
});
respectNBT.setToolTip(respectDataN);
ignoreNBT = new IconButton(x + 78, y + 73, AllIcons.I_IGNORE_NBT);
ignoreNBT = new IconButton(x + 78, y + 75, AllIcons.I_IGNORE_NBT);
ignoreNBT.withCallback(() -> {
menu.respectNBT = false;
sendOptionUpdate(Option.IGNORE_DATA);
});
ignoreNBT.setToolTip(ignoreDataN);
respectNBTIndicator = new Indicator(x + 60, y + 67, Components.immutableEmpty());
ignoreNBTIndicator = new Indicator(x + 78, y + 67, Components.immutableEmpty());
respectNBTIndicator = new Indicator(x + 60, y + 69, Components.immutableEmpty());
ignoreNBTIndicator = new Indicator(x + 78, y + 69, Components.immutableEmpty());
addRenderableWidgets(respectNBT, ignoreNBT, respectNBTIndicator, ignoreNBTIndicator);
handleIndicators();

View file

@ -1,12 +1,12 @@
package com.simibubi.create.content.logistics.packet;
import com.simibubi.create.content.logistics.block.redstone.StockpileSwitchBlockEntity;
import com.simibubi.create.content.logistics.block.redstone.ThresholdSwitchBlockEntity;
import com.simibubi.create.foundation.networking.BlockEntityConfigurationPacket;
import net.minecraft.core.BlockPos;
import net.minecraft.network.FriendlyByteBuf;
public class ConfigureStockswitchPacket extends BlockEntityConfigurationPacket<StockpileSwitchBlockEntity> {
public class ConfigureStockswitchPacket extends BlockEntityConfigurationPacket<ThresholdSwitchBlockEntity> {
private float offBelow;
private float onAbove;
@ -38,7 +38,7 @@ public class ConfigureStockswitchPacket extends BlockEntityConfigurationPacket<S
}
@Override
protected void applySettings(StockpileSwitchBlockEntity be) {
protected void applySettings(ThresholdSwitchBlockEntity be) {
be.offWhenBelow = offBelow;
be.onWhenAbove = onAbove;
be.setInverted(invert);

View file

@ -69,7 +69,7 @@ public class StationScreen extends AbstractStationScreen {
Components.literal(station.name));
nameBox.setBordered(false);
nameBox.setMaxLength(25);
nameBox.setTextColor(0x442000);
nameBox.setTextColor(0x592424);
nameBox.setValue(station.name);
nameBox.changeFocus(false);
nameBox.mouseClicked(0, 0, 0);

View file

@ -73,9 +73,9 @@ public class TagGen {
.add(Blocks.BELL, Blocks.COCOA, Blocks.FLOWER_POT)
.addTag(BlockTags.BEDS)
.addTag(BlockTags.DOORS);
prov.tag(AllBlockTags.MOVABLE_EMPTY_COLLIDER.tag)
.add(Blocks.COBWEB, Blocks.POWDER_SNOW)
.add(Blocks.COBWEB, Blocks.POWDER_SNOW, Blocks.TRIPWIRE, Blocks.TRIPWIRE_HOOK)
.addTag(BlockTags.FENCE_GATES);
prov.tag(AllBlockTags.FAN_TRANSPARENT.tag)

View file

@ -244,7 +244,7 @@ public class StandardRecipeGen extends CreateRecipeProvider {
.requires(I.planks())
.requires(I.planks())),
LARGE_COGWHEEL_FROM_LITTLE = create(AllBlocks.LARGE_COGWHEEL).withSuffix("from_little")
LARGE_COGWHEEL_FROM_LITTLE = create(AllBlocks.LARGE_COGWHEEL).withSuffix("_from_little")
.unlockedBy(I::andesite)
.viaShapeless(b -> b.requires(I.cog())
.requires(I.planks())),
@ -908,15 +908,21 @@ public class StandardRecipeGen extends CreateRecipeProvider {
.pattern("AA")
.pattern("KK")),
CONTENT_OBSERVER = create(AllBlocks.CONTENT_OBSERVER).unlockedBy(AllItems.BELT_CONNECTOR::get)
SMART_OBSERVER = create(AllBlocks.SMART_OBSERVER).unlockedBy(I::brassCasing)
.viaShaped(b -> b.define('B', I.brassCasing())
.define('R', I.electronTube())
.define('I', Blocks.OBSERVER)
.pattern("R")
.pattern("B")
.pattern("I")),
THRESHOLD_SWITCH = create(AllBlocks.THRESHOLD_SWITCH).unlockedBy(I::brassCasing)
.viaShaped(b -> b.define('B', I.brassCasing())
.define('R', I.electronTube())
.define('I', Blocks.COMPARATOR)
.pattern("I")
.pattern("R")
.pattern("B")
.pattern("R")),
OBSERVER_CYCLE = conversionCycle(ImmutableList.of(AllBlocks.CONTENT_OBSERVER, AllBlocks.STOCKPILE_SWITCH)),
.pattern("I")),
PULSE_EXTENDER = create(AllBlocks.PULSE_EXTENDER).unlockedByTag(I::redstone)
.viaShaped(b -> b.define('T', Blocks.REDSTONE_TORCH)
@ -1080,10 +1086,18 @@ public class StandardRecipeGen extends CreateRecipeProvider {
.requires(Items.BONE_MEAL)),
NETHERITE_DIVING_HELMET =
create(AllItems.NETHERITE_DIVING_HELMET).viaSmithing(AllItems.COPPER_DIVING_HELMET, I.netherite()),
NETHERITE_BACKTANK = create(AllItems.NETHERITE_BACKTANK).viaSmithing(AllItems.COPPER_BACKTANK, I.netherite()),
create(AllItems.NETHERITE_DIVING_HELMET).viaSmithing(AllItems.COPPER_DIVING_HELMET::get, I::netherite),
NETHERITE_BACKTANK =
create(AllItems.NETHERITE_BACKTANK).viaSmithing(AllItems.COPPER_BACKTANK::get, I::netherite),
NETHERITE_DIVING_BOOTS =
create(AllItems.NETHERITE_DIVING_BOOTS).viaSmithing(AllItems.COPPER_DIVING_BOOTS, I.netherite())
create(AllItems.NETHERITE_DIVING_BOOTS).viaSmithing(AllItems.COPPER_DIVING_BOOTS::get, I::netherite),
NETHERITE_DIVING_HELMET_2 = create(AllItems.NETHERITE_DIVING_HELMET).withSuffix("_from_netherite")
.viaSmithing(() -> Items.NETHERITE_HELMET, () -> Ingredient.of(AllItems.COPPER_DIVING_HELMET.get())),
NETHERITE_BACKTANK_2 = create(AllItems.NETHERITE_BACKTANK).withSuffix("_from_netherite")
.viaSmithing(() -> Items.NETHERITE_CHESTPLATE, () -> Ingredient.of(AllItems.COPPER_BACKTANK.get())),
NETHERITE_DIVING_BOOTS_2 = create(AllItems.NETHERITE_DIVING_BOOTS).withSuffix("_from_netherite")
.viaSmithing(() -> Items.NETHERITE_BOOTS, () -> Ingredient.of(AllItems.COPPER_DIVING_BOOTS.get()))
;
@ -1327,10 +1341,10 @@ public class StandardRecipeGen extends CreateRecipeProvider {
});
}
GeneratedRecipe viaSmithing(ItemEntry<?> base, Ingredient upgradeMaterial) {
GeneratedRecipe viaSmithing(Supplier<? extends Item> base, Supplier<Ingredient> upgradeMaterial) {
return register(consumer -> {
UpgradeRecipeBuilder b =
UpgradeRecipeBuilder.smithing(Ingredient.of(base.get()), upgradeMaterial, result.get()
UpgradeRecipeBuilder.smithing(Ingredient.of(base.get()), upgradeMaterial.get(), result.get()
.asItem());
b.unlocks("has_item", inventoryTrigger(ItemPredicate.Builder.item()
.of(base.get())

View file

@ -40,16 +40,16 @@ public enum AllGuiTextures implements ScreenElement {
SCHEMATICANNON_FUEL("schematics_2", 28, 222, 47, 16),
SCHEMATICANNON_FUEL_CREATIVE("schematics_2", 28, 239, 47, 16),
STOCKSWITCH("logistics", 182, 93),
STOCKSWITCH("logistics", 182, 95),
STOCKSWITCH_ARROW_UP("logistics", 191, 0, 7, 24),
STOCKSWITCH_ARROW_DOWN("logistics", 198, 0, 7, 24),
STOCKSWITCH_CURSOR("logistics", 206, 0, 7, 16),
STOCKSWITCH_INTERVAL("logistics", 0, 93, 100, 18),
STOCKSWITCH_UNPOWERED_LANE("logistics", 36, 18, 102, 18),
STOCKSWITCH_POWERED_LANE("logistics", 36, 40, 102, 18),
STOCKSWITCH_INTERVAL("logistics", 0, 95, 100, 18),
STOCKSWITCH_UNPOWERED_LANE("logistics", 37, 20, 100, 18),
STOCKSWITCH_POWERED_LANE("logistics", 37, 42, 100, 18),
FILTER("filters", 214, 97),
ATTRIBUTE_FILTER("filters", 0, 97, 241, 83),
FILTER("filters", 214, 99),
ATTRIBUTE_FILTER("filters", 0, 99, 241, 85),
TOOLBOX("toolbox", 188, 171),
TOOLBELT_SLOT("minecraft", "widgets", 24, 23, 22, 22),
@ -63,12 +63,12 @@ public enum AllGuiTextures implements ScreenElement {
TOOLBELT_SELECTED_OFF("widgets", 0, 155, 22, 22),
TOOLBELT_SELECTED_ON("widgets", 22, 155, 22, 22),
SEQUENCER("sequencer", 173, 159),
SEQUENCER_INSTRUCTION("sequencer", 0, 14, 162, 22),
SEQUENCER_DELAY("sequencer", 0, 58, 162, 22),
SEQUENCER_END("sequencer", 0, 80, 162, 22),
SEQUENCER_EMPTY("sequencer", 0, 102, 162, 22),
SEQUENCER_AWAIT("sequencer", 0, 160, 162, 22),
SEQUENCER("sequencer", 173, 161),
SEQUENCER_INSTRUCTION("sequencer", 0, 16, 162, 22),
SEQUENCER_DELAY("sequencer", 0, 60, 162, 22),
SEQUENCER_END("sequencer", 0, 82, 162, 22),
SEQUENCER_EMPTY("sequencer", 0, 104, 162, 22),
SEQUENCER_AWAIT("sequencer", 0, 162, 162, 22),
LINKED_CONTROLLER("curiosities_2", 179, 109),
BLUEPRINT("curiosities_2", 0, 109, 179, 109),

View file

@ -453,8 +453,8 @@ public class PonderIndex {
.add(AllBlocks.BRASS_FUNNEL)
.add(AllBlocks.ANDESITE_TUNNEL)
.add(AllBlocks.BRASS_TUNNEL)
.add(AllBlocks.CONTENT_OBSERVER)
.add(AllBlocks.STOCKPILE_SWITCH)
.add(AllBlocks.SMART_OBSERVER)
.add(AllBlocks.THRESHOLD_SWITCH)
.add(AllBlocks.CREATIVE_CRATE)
.add(AllBlocks.PORTABLE_STORAGE_INTERFACE);
@ -531,8 +531,8 @@ public class PonderIndex {
PonderRegistry.TAGS.forTag(PonderTag.DISPLAY_SOURCES)
.add(AllBlocks.SEATS.get(DyeColor.WHITE))
.add(AllBlocks.ORANGE_NIXIE_TUBE)
.add(AllBlocks.STOCKPILE_SWITCH)
.add(AllBlocks.CONTENT_OBSERVER)
.add(AllBlocks.THRESHOLD_SWITCH)
.add(AllBlocks.SMART_OBSERVER)
.add(AllBlocks.ANDESITE_TUNNEL)
.add(AllBlocks.TRACK_OBSERVER)
.add(AllBlocks.TRACK_STATION)

View file

@ -4,7 +4,7 @@ import static com.simibubi.create.AllBlocks.ADJUSTABLE_CHAIN_GEARSHIFT;
import static com.simibubi.create.AllBlocks.ANDESITE_ENCASED_SHAFT;
import static com.simibubi.create.AllBlocks.BRASS_BELT_FUNNEL;
import static com.simibubi.create.AllBlocks.BRASS_TUNNEL;
import static com.simibubi.create.AllBlocks.CONTENT_OBSERVER;
import static com.simibubi.create.AllBlocks.SMART_OBSERVER;
import static com.simibubi.create.AllBlocks.ENCASED_CHAIN_DRIVE;
import static com.simibubi.create.AllBlocks.LINEAR_CHASSIS;
import static com.simibubi.create.AllBlocks.MECHANICAL_DRILL;
@ -21,7 +21,7 @@ import static com.simibubi.create.AllBlocks.REDSTONE_CONTACT;
import static com.simibubi.create.AllBlocks.REDSTONE_LINK;
import static com.simibubi.create.AllBlocks.SECONDARY_LINEAR_CHASSIS;
import static com.simibubi.create.AllBlocks.SPEEDOMETER;
import static com.simibubi.create.AllBlocks.STOCKPILE_SWITCH;
import static com.simibubi.create.AllBlocks.THRESHOLD_SWITCH;
import static com.simibubi.create.AllBlocks.STRESSOMETER;
import static com.simibubi.create.AllItems.ATTRIBUTE_FILTER;
import static com.simibubi.create.AllItems.COPPER_DIVING_BOOTS;
@ -78,11 +78,11 @@ public class RemapHelper {
reMap.put("encased_shaft", ANDESITE_ENCASED_SHAFT.getId());
reMap.put("encased_belt", ENCASED_CHAIN_DRIVE.getId());
reMap.put("adjustable_pulley", ADJUSTABLE_CHAIN_GEARSHIFT.getId());
reMap.put("stockswitch", STOCKPILE_SWITCH.getId());
reMap.put("stockswitch", THRESHOLD_SWITCH.getId());
reMap.put("redstone_latch", POWERED_LATCH.getId());
reMap.put("contact", REDSTONE_CONTACT.getId());
reMap.put("belt_funnel", BRASS_BELT_FUNNEL.getId());
reMap.put("entity_detector", CONTENT_OBSERVER.getId());
reMap.put("entity_detector", SMART_OBSERVER.getId());
reMap.put("saw", MECHANICAL_SAW.getId());
reMap.put("flexpulsepeater", PULSE_REPEATER.getId());
reMap.put("stress_gauge", STRESSOMETER.getId());

View file

@ -278,10 +278,10 @@
"create.gui.adjustable_crate.title": "Adjustable Crate",
"create.gui.adjustable_crate.storageSpace": "Storage Space",
"create.gui.stockpile_switch.title": "Stockpile Switch",
"create.gui.stockpile_switch.invert_signal": "Invert Signal",
"create.gui.stockpile_switch.move_to_lower_at": "Move to lower lane at %1$s%%",
"create.gui.stockpile_switch.move_to_upper_at": "Move to upper lane at %1$s%%",
"create.gui.threshold_switch.title": "Threshold Switch",
"create.gui.threshold_switch.invert_signal": "Invert Signal",
"create.gui.threshold_switch.move_to_lower_at": "Move to lower lane at %1$s%%",
"create.gui.threshold_switch.move_to_upper_at": "Move to upper lane at %1$s%%",
"create.gui.sequenced_gearshift.title": "Sequenced Gearshift",
"create.gui.sequenced_gearshift.instruction": "Instruction",

View file

@ -2,76 +2,25 @@
"credit": "Made with Blockbench",
"parent": "block/block",
"textures": {
"7": "create:block/brass_casing_connected",
"8": "create:block/content_observer",
"9": "create:block/content_observer_inner",
"10": "create:block/filtered_detector_top",
"particle": "create:block/filtered_detector_top",
"end": "create:block/filtered_detector_front"
"0": "create:block/smart_observer",
"2": "create:block/smart_observer_front",
"4": "create:block/smart_observer_top",
"6": "block/observer_top",
"7": "create:block/smart_observer_side",
"particle": "create:block/smart_observer"
},
"elements": [
{
"name": "Bottom Plate",
"from": [0, 0, 0],
"to": [16, 6, 16],
"faces": {
"north": {"uv": [0, 10, 16, 16], "texture": "#8"},
"east": {"uv": [0, 10, 16, 16], "texture": "#8"},
"south": {"uv": [0, 10, 16, 16], "texture": "#8"},
"west": {"uv": [0, 10, 16, 16], "texture": "#8"},
"up": {"uv": [0, 0, 16, 16], "rotation": 90, "texture": "#9"},
"down": {"uv": [0, 0, 2, 2], "rotation": 270, "texture": "#7"}
}
},
{
"name": "Center",
"from": [0.9, 2, 0.9],
"to": [15.1, 14, 15.1],
"faces": {
"north": {"uv": [12, 12.125, 13.625, 13.875], "rotation": 90, "texture": "#7"},
"east": {"uv": [12, 12.125, 13.625, 13.875], "rotation": 90, "texture": "#7"},
"south": {"uv": [12, 12.125, 13.625, 13.875], "rotation": 90, "texture": "#7"},
"west": {"uv": [12, 12.125, 13.625, 13.875], "rotation": 90, "texture": "#7"}
}
},
{
"name": "Indicator",
"from": [3.1, 3.1, -1.9],
"to": [12.9, 12.9, 1.1],
"faces": {
"north": {"uv": [0, 0, 10, 10], "texture": "#end"},
"east": {"uv": [10, 0, 13, 10], "texture": "#end"},
"west": {"uv": [10, 0, 13, 10], "texture": "#end"},
"up": {"uv": [10, 0, 13, 10], "rotation": 90, "texture": "#end"},
"down": {"uv": [10, 0, 13, 10], "rotation": 270, "texture": "#end"}
}
},
{
"name": "Top Plate",
"from": [0, 14, 0],
"to": [16, 16, 16],
"faces": {
"north": {"uv": [3.875, 0, 6, 0.25], "texture": "#7"},
"east": {"uv": [3.875, 0, 6, 0.25], "texture": "#7"},
"south": {"uv": [3.875, 0, 6, 0.25], "texture": "#7"},
"west": {"uv": [3.875, 0, 6, 0.25], "texture": "#7"},
"up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#10"},
"down": {"uv": [0, 0, 2, 2], "rotation": 270, "texture": "#7"}
"north": {"uv": [0, 0, 16, 16], "texture": "#2"},
"east": {"uv": [0, 0, 16, 16], "texture": "#7"},
"south": {"uv": [0, 0, 16, 16], "texture": "#0"},
"west": {"uv": [0, 0, 16, 16], "texture": "#7"},
"up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#4"},
"down": {"uv": [0, 0, 16, 16], "texture": "#6"}
}
}
],
"display": {
"gui": {
"rotation": [30, -135, 0],
"scale": [0.625, 0.625, 0.625]
}
},
"groups": [
{
"name": "stockpile_switch",
"origin": [8, 8, 8],
"color": 0,
"children": [0, 1, 2, 3]
}
]
}

View file

@ -1,7 +1,8 @@
{
"parent": "create:block/content_observer/block",
"textures": {
"8": "create:block/content_observer_powered",
"9": "create:block/content_observer_inner_powered"
"0": "create:block/smart_observer_powered",
"7": "create:block/smart_observer_side_powered",
"particle": "create:block/smart_observer_powered"
}
}

View file

@ -1,98 +0,0 @@
{
"credit": "Made with Blockbench",
"parent": "block/block",
"textures": {
"7": "create:block/filtered_detector_top",
"8": "create:block/brass_casing_connected",
"particle": "create:block/filtered_detector_top",
"indicator": "create:block/indicator/0",
"end": "create:block/filtered_detector_front"
},
"elements": [
{
"name": "Bottom Plate",
"from": [0, 0, 0],
"to": [16, 2, 16],
"faces": {
"north": {"uv": [1.875, 1.75, 4, 2], "texture": "#8"},
"east": {"uv": [1.875, 1.75, 4, 2], "texture": "#8"},
"south": {"uv": [1.875, 1.75, 4, 2], "texture": "#8"},
"west": {"uv": [1.875, 1.75, 4, 2], "texture": "#8"},
"up": {"uv": [0, 0, 2, 2], "rotation": 270, "texture": "#8"},
"down": {"uv": [0, 0, 2, 2], "rotation": 270, "texture": "#8"}
}
},
{
"name": "Top Plate",
"from": [0, 14, 0],
"to": [16, 16, 16],
"faces": {
"north": {"uv": [3.875, 0, 6, 0.25], "texture": "#8"},
"east": {"uv": [3.875, 0, 6, 0.25], "texture": "#8"},
"south": {"uv": [3.875, 0, 6, 0.25], "texture": "#8"},
"west": {"uv": [3.875, 0, 6, 0.25], "texture": "#8"},
"up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#7"},
"down": {"uv": [0, 0, 2, 2], "rotation": 270, "texture": "#8"}
}
},
{
"name": "Center",
"from": [0.9, 2, 0.9],
"to": [15.1, 14, 15.1],
"faces": {
"north": {"uv": [12, 12.125, 13.625, 13.875], "rotation": 90, "texture": "#8"},
"east": {"uv": [12, 12.125, 13.625, 13.875], "rotation": 90, "texture": "#8"},
"south": {"uv": [12, 12.125, 13.625, 13.875], "rotation": 90, "texture": "#8"},
"west": {"uv": [12, 12.125, 13.625, 13.875], "rotation": 90, "texture": "#8"}
}
},
{
"name": "Indicator",
"from": [3.1, 3.1, -1.9],
"to": [12.9, 12.9, 1.1],
"faces": {
"north": {"uv": [0, 0, 10, 10], "texture": "#end"},
"east": {"uv": [10, 0, 13, 10], "texture": "#end"},
"west": {"uv": [10, 0, 13, 10], "texture": "#end"},
"up": {"uv": [10, 0, 13, 10], "rotation": 90, "texture": "#end"},
"down": {"uv": [10, 0, 13, 10], "rotation": 270, "texture": "#end"}
}
},
{
"name": "Indicator",
"from": [13, 2, 6],
"to": [16, 14, 10],
"faces": {
"north": {"uv": [0, 0, 3, 12], "texture": "#indicator"},
"east": {"uv": [0, 0, 4, 12], "texture": "#indicator"},
"south": {"uv": [1, 0, 4, 12], "texture": "#indicator"}
}
},
{
"name": "Indicator",
"from": [0, 2, 6],
"to": [3, 14, 10],
"faces": {
"north": {"uv": [3, 0, 0, 12], "texture": "#indicator"},
"south": {"uv": [4, 0, 1, 12], "texture": "#indicator"},
"west": {"uv": [4, 0, 0, 12], "texture": "#indicator"}
}
},
{
"name": "Indicator",
"from": [6, 2, 13],
"to": [10, 14, 16],
"faces": {
"east": {"uv": [4, 0, 1, 12], "texture": "#indicator"},
"south": {"uv": [4, 0, 0, 12], "texture": "#indicator"},
"west": {"uv": [3, 0, 0, 12], "texture": "#indicator"}
}
}
],
"display": {
"gui": {
"rotation": [30, -135, 0],
"scale": [0.625, 0.625, 0.625]
}
}
}

View file

@ -0,0 +1,44 @@
{
"credit": "Made with Blockbench",
"parent": "block/block",
"textures": {
"3": "create:block/threshold_switch_back",
"level": "create:block/threshold_switch/level_0",
"5": "create:block/threshold_switch_front",
"7": "create:block/brass_block",
"8": "create:block/tunnel/brass_tunnel_top",
"particle": "#level"
},
"elements": [
{
"from": [0, 0, 0],
"to": [16, 16, 16],
"faces": {
"north": {"uv": [0, 0, 16, 16], "texture": "#level"},
"east": {"uv": [0, 0, 16, 16], "texture": "#3"},
"south": {"uv": [0, 0, 16, 16], "texture": "#level"},
"west": {"uv": [0, 0, 16, 16], "texture": "#3"},
"up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#7"},
"down": {"uv": [0, 0, 16, 16], "texture": "#8"}
}
},
{
"from": [2.95, 15.9, 2.95],
"to": [13.05, 17.95, 13.05],
"rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 8]},
"faces": {
"north": {"uv": [13, 11, 3, 13], "rotation": 180, "texture": "#5"},
"east": {"uv": [5, 3, 3, 13], "rotation": 270, "texture": "#5"},
"south": {"uv": [13, 3, 3, 5], "texture": "#5"},
"west": {"uv": [13, 3, 11, 13], "rotation": 90, "texture": "#5"},
"up": {"uv": [3, 3, 13, 13], "rotation": 180, "texture": "#5"}
}
}
],
"display": {
"gui": {
"rotation": [30, -135, 0],
"scale": [0.625, 0.625, 0.625]
}
}
}

View file

@ -0,0 +1,44 @@
{
"credit": "Made with Blockbench",
"parent": "block/block",
"textures": {
"3": "create:block/threshold_switch_back",
"level": "create:block/threshold_switch/level_0",
"5": "create:block/threshold_switch_front",
"7": "create:block/brass_block",
"8": "create:block/tunnel/brass_tunnel_top",
"particle": "#level"
},
"elements": [
{
"from": [0, 0, 0],
"to": [16, 16, 16],
"faces": {
"north": {"uv": [0, 0, 16, 16], "texture": "#level"},
"east": {"uv": [0, 0, 16, 16], "texture": "#3"},
"south": {"uv": [0, 0, 16, 16], "texture": "#level"},
"west": {"uv": [0, 0, 16, 16], "texture": "#3"},
"up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#8"},
"down": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#7"}
}
},
{
"from": [2.95, -1.95, 2.95],
"to": [13.05, 0.1, 13.05],
"rotation": {"angle": 0, "axis": "y", "origin": [8, 8, 8]},
"faces": {
"north": {"uv": [13, 3, 3, 5], "rotation": 180, "texture": "#5"},
"east": {"uv": [5, 3, 3, 13], "rotation": 90, "texture": "#5"},
"south": {"uv": [13, 11, 3, 13], "texture": "#5"},
"west": {"uv": [13, 3, 11, 13], "rotation": 270, "texture": "#5"},
"down": {"uv": [3, 3, 13, 13], "rotation": 180, "texture": "#5"}
}
}
],
"display": {
"gui": {
"rotation": [30, -135, 0],
"scale": [0.625, 0.625, 0.625]
}
}
}

View file

@ -0,0 +1,42 @@
{
"credit": "Made with Blockbench",
"parent": "block/block",
"textures": {
"3": "create:block/threshold_switch_back",
"level": "create:block/threshold_switch/level_0",
"5": "create:block/threshold_switch_front",
"6": "create:block/smart_observer_top",
"particle": "#level"
},
"elements": [
{
"from": [0, 0, 0],
"to": [16, 16, 16],
"faces": {
"north": {"uv": [0, 0, 16, 16], "texture": "#5"},
"east": {"uv": [0, 0, 16, 16], "texture": "#level"},
"south": {"uv": [0, 0, 16, 16], "texture": "#3"},
"west": {"uv": [0, 0, 16, 16], "texture": "#level"},
"up": {"uv": [0, 0, 16, 16], "rotation": 180, "texture": "#6"},
"down": {"uv": [0, 0, 16, 16], "texture": "#6"}
}
},
{
"from": [2.95, 2.95, -1.95],
"to": [13.05, 13.05, 0.1],
"faces": {
"north": {"uv": [3, 3, 13, 13], "texture": "#5"},
"east": {"uv": [5, 3, 3, 13], "texture": "#5"},
"west": {"uv": [13, 3, 11, 13], "texture": "#5"},
"up": {"uv": [13, 3, 3, 5], "texture": "#5"},
"down": {"uv": [13, 11, 3, 13], "texture": "#5"}
}
}
],
"display": {
"gui": {
"rotation": [30, -135, 0],
"scale": [0.625, 0.625, 0.625]
}
}
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 221 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 343 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 335 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 369 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 328 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 338 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 293 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 335 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 362 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 364 B

Some files were not shown because too many files have changed in this diff Show more