Return of the buttons

- Added recipe for linked controller
- Removed soundspam of saws, needs continuous replacement
- Soundscapes are now reset on resource reload
This commit is contained in:
simibubi 2021-06-17 16:20:15 +02:00
parent 0a0acb3d4c
commit 57f6e739e3
9 changed files with 77 additions and 12 deletions

View file

@ -1654,7 +1654,7 @@ d080b1b25e5bc8baf5aee68691b08c7f12ece3b0 assets/create/models/item/windmill_bear
a80fb25a0b655e76be986b5b49fcb0f03461a1ab assets/create/models/item/zinc_nugget.json
b1689617190c05ef34bd18456b0c7ae09bb3210f assets/create/models/item/zinc_ore.json
6490fa0587db770cf7c794b47f3bcd2b691f4226 assets/create/sounds.json
5d0cc4c0255dc241e61c173b31ddca70c88d08e4 data/create/advancements/aesthetics.json
0f1b4b980afba9bf2caf583b88e261bba8b10313 data/create/advancements/aesthetics.json
187921fa131b06721bfaf63f2623a28c141aae9a data/create/advancements/andesite_alloy.json
0ea2db7173b5be28b289ea7c9a6a0cf5805c60c7 data/create/advancements/andesite_casing.json
83c046bd200623933545c9e4326f782fb02c87fa data/create/advancements/arm_blaze_burner.json
@ -1783,6 +1783,7 @@ f2dc28c600011e6e8e515cb4d56118b1bd45b743 data/create/advancements/recipes/create
46c04e685ab345a80598176f7ac68a044a76cd76 data/create/advancements/recipes/create.base/crafting/appliances/diving_boots.json
5f06b7dcf2af11f30c2e10ade4ac3fd172bc04df data/create/advancements/recipes/create.base/crafting/appliances/diving_helmet.json
dd487f98c411f1ff22cb7fc208b8cc24b27deb2f data/create/advancements/recipes/create.base/crafting/appliances/dough.json
911159091a9674c36e8cd49f56f63e5442988e84 data/create/advancements/recipes/create.base/crafting/appliances/linked_controller.json
51cdcf168087f47e4458eed7543d227da1ee5ca0 data/create/advancements/recipes/create.base/crafting/appliances/tree_fertilizer.json
d531f87f425d199aee4777a588c1cd6cab6f5173 data/create/advancements/recipes/create.base/crafting/curiosities/minecart_coupling.json
2eef3201017af03f6a2f0f015645e3ff5e25d9c1 data/create/advancements/recipes/create.base/crafting/curiosities/wand_of_symmetry.json
@ -2858,11 +2859,12 @@ f7879d404d7a848d818278b4e788f285a9087e63 data/create/recipes/compacting/blaze_ca
27c23592d8fec03072a04544d3598ca9b1c798ff data/create/recipes/compacting/chocolate.json
7b2ef15dd28d1d8a450ea49a82dfb361d1adde4c data/create/recipes/compacting/diorite_from_flint.json
7657603e95ccf83dd0d4b104635db66e531d092a data/create/recipes/compacting/granite_from_flint.json
30030b15caa11b3a7c0104adb62fe74e8c7c0df1 data/create/recipes/crafting/appliances/copper_backtank.json
b187def3a843505ab42db301f5374043d90605d6 data/create/recipes/crafting/appliances/copper_backtank.json
c077375d16b4505e52548613fbc9356993556e6b data/create/recipes/crafting/appliances/crafting_blueprint.json
9ad82ac5ce02654b7af7f1a570a6b2c01e140da3 data/create/recipes/crafting/appliances/diving_boots.json
813081c6421b34e161ec44e8e470994c282f76be data/create/recipes/crafting/appliances/diving_helmet.json
19526da3a59fc136654ff1bc93c0251581f397a9 data/create/recipes/crafting/appliances/dough.json
75cdbd88973a8ca943ebe890153b01a344b96b01 data/create/recipes/crafting/appliances/linked_controller.json
7b5f863dda3d05a79cb85943a178eba0bd8a7dc7 data/create/recipes/crafting/appliances/slime_ball.json
b159ba84428eee6ef6e23df1766f2a18f2c8a63e data/create/recipes/crafting/appliances/tree_fertilizer.json
660e92da2b1b6698b1c0df74bd74a56a25fb3eca data/create/recipes/crafting/curiosities/minecart_coupling.json

View file

@ -28,8 +28,8 @@
"trigger": "create:bracket_apply",
"conditions": {
"accepted_entries": [
"create:large_cogwheel",
"create:cogwheel"
"create:cogwheel",
"create:large_cogwheel"
]
}
},

View file

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

View file

@ -2,7 +2,7 @@
"type": "minecraft:crafting_shaped",
"pattern": [
"AGA",
"PPP",
"PBP",
" P "
],
"key": {
@ -12,6 +12,9 @@
"A": {
"item": "create:andesite_alloy"
},
"B": {
"tag": "forge:storage_blocks/copper"
},
"P": {
"tag": "forge:ingots/copper"
}

View file

@ -0,0 +1,19 @@
{
"type": "minecraft:crafting_shaped",
"pattern": [
"SSS",
" P ",
"SSS"
],
"key": {
"S": {
"tag": "minecraft:wooden_buttons"
},
"P": {
"item": "create:redstone_link"
}
},
"result": {
"item": "create:linked_controller"
}
}

View file

@ -147,7 +147,7 @@ public class SawTileEntity extends BlockBreakingKineticTileEntity {
return;
}
AllSoundEvents.SAW_PROCESS.playAt(world, pos, 1, 1, true);
// AllSoundEvents.SAW_PROCESS.playAt(world, pos, 1, 1, true); TODO
}
@Override

View file

@ -3,6 +3,7 @@ package com.simibubi.create.foundation;
import com.simibubi.create.CreateClient;
import com.simibubi.create.content.contraptions.goggles.IHaveGoggleInformation;
import com.simibubi.create.foundation.block.render.SpriteShifter;
import com.simibubi.create.foundation.sound.SoundScapes;
import com.simibubi.create.foundation.utility.ISimpleReloadListener;
import net.minecraft.profiler.IProfiler;
@ -15,6 +16,7 @@ public class ResourceReloadHandler implements ISimpleReloadListener {
SpriteShifter.reloadUVs();
CreateClient.invalidateRenderers();
IHaveGoggleInformation.numberFormat.update();
SoundScapes.invalidateAll();
}
}

View file

@ -957,9 +957,10 @@ public class StandardRecipeGen extends CreateRecipeProvider {
COPPER_BACKTANK = create(AllItems.COPPER_BACKTANK).unlockedByTag(I::copper)
.viaShaped(b -> b.key('G', I.shaft())
.key('A', I.andesite())
.key('B', I.copperBlock())
.key('P', I.copper())
.patternLine("AGA")
.patternLine("PPP")
.patternLine("PBP")
.patternLine(" P ")),
DIVING_BOOTS = create(AllItems.DIVING_BOOTS).unlockedByTag(I::copper)
@ -969,6 +970,13 @@ public class StandardRecipeGen extends CreateRecipeProvider {
.patternLine("P P")
.patternLine("G G")),
LINKED_CONTROLLER = create(AllItems.LINKED_CONTROLLER).unlockedBy(AllBlocks.REDSTONE_LINK::get)
.viaShaped(b -> b.key('S', ItemTags.WOODEN_BUTTONS)
.key('P', AllBlocks.REDSTONE_LINK.get())
.patternLine("SSS")
.patternLine(" P ")
.patternLine("SSS")),
CRAFTING_BLUEPRINT = create(AllItems.CRAFTING_BLUEPRINT).unlockedBy(() -> Items.CRAFTING_TABLE)
.viaShapeless(b -> b.addIngredient(Items.PAINTING)
.addIngredient(Items.CRAFTING_TABLE)),

View file

@ -105,11 +105,10 @@ public class SoundScapes {
});
}
public static void clean() {
BlockPos playerLocation = getCameraPos();
for (Map<PitchGroup, Set<BlockPos>> map : counter.values())
for (Set<BlockPos> set : map.values())
set.removeIf(p -> !playerLocation.withinDistance(p, MAX_AMBIENT_SOURCE_DISTANCE));
public static void invalidateAll() {
counter.clear();
activeSounds.forEach(($, sound) -> sound.remove());
activeSounds.clear();
}
protected static boolean outOfRange(BlockPos pos) {