Skip to content

Commit

Permalink
Fix bugged cherry fence gate sounds. (#56)
Browse files Browse the repository at this point in the history
* Fix bugged cherry fence gate sounds.

* Bump version

* Update developer documentation

* Typo Fix 1

Co-authored-by: chris <[email protected]>

* Typo Fix 2

Co-authored-by: chris <[email protected]>

---------

Co-authored-by: chris <[email protected]>
  • Loading branch information
letsgoawaydev and onebeastchris authored Jul 3, 2024
1 parent 095a9dd commit e02280f
Show file tree
Hide file tree
Showing 4 changed files with 101 additions and 8 deletions.
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,6 @@ textures/geyser/particle/damage.png
textures/geyser/particle/flash.png
textures/geyser/particle/nautilus.png
textures/geyser/particle/sweep_attack.png
textures/geyser/entity/illager/illusioner.png
textures/geyser/entity/illager/illusioner.png
# Blockception's Minecraft Bedrock Development VS Code Extension settings
.mcattributes
76 changes: 71 additions & 5 deletions developer_documentation.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
* [Spyglass animations](#Spyglass-animations)
* [Zombie villager textures](#Zombie-villager-textures)
* [UI modifications](#ui-modifications)
* [Structure block texture changes (MCPE-48224)](#structure-block-texture-changes-mcpe-48224)
* [Cherry Fence Gate Sound Fix (MCPE-168021)](#cherry-fence-gate-sound-fix-mcpe-168021)
<!--te-->

### Introduction
Expand Down Expand Up @@ -270,10 +272,6 @@ Unfortunately, the spyglass cannot actually be used in the offhand by Bedrock pl
Like villagers, zombie villagers in Java Edition have visible biome and profession variants. It appears that initial implementation of this was started in the Bedrock vanilla resources, given the presence of the entity with the identifier `minecraft:zombie_villager_v2`. However, the textures specified in this vanilla entity definition appear to be entirely blank TGA files. Luckily, the profession textures of zombie villagers and villagers are essentially identical, so the entity definition was updated to reference the villager profession textures.
Zombie villagers, like villagers, have a profession level. This is implemented by adding the same vanilla render controller used to create this effect in the villager entity, `controller.render.villager_v2_level`. The remainder of the entity definition is unchanged.
### Structure block texture changes
Bedrock edition is currently wrongly assigning textures to the load, save and corner structure block modes. The `terrain_texture.json` file fixes this by
putting the textures in the correct order. See https://bugs.mojang.com/browse/MCPE-48224 for the associated bug report.
### UI modifications
Some inventories have added functionality on Bedrock, that does not exist on Java edition. For example, this includes:
- 2x2 crafting grid while in creative mode
Expand Down Expand Up @@ -315,4 +313,72 @@ Hiding the 2x2 crafting grid is a bit more involved. We have to use bindings to
```
This uses the `#is_creative_mode` binding, and applies it to the crafting panel. Note that we insert this modification into the bindings array
instead of directly modifying the UI - this allows the GeyserOptionalPack to stay compatible with other resource packs that modify this screen.
instead of directly modifying the UI - this allows the GeyserOptionalPack to stay compatible with other resource packs that modify this screen.
### Structure block texture changes (MCPE-48224)
Bedrock edition is currently wrongly assigning textures to the load, save and corner structure block modes. The `terrain_texture.json` file fixes this by
putting the textures in the correct order.
See https://bugs.mojang.com/browse/MCPE-48224 for the associated bug report.
### Cherry fence gate sound fix (MCPE-168021)
Likely due to a copy and paste mistake as the bamboo and nether wood fence gates have 4 sounds, the Bedrock Edition default resource pack defines opening and closing a Cherry Fence Gate to have four sounds as seen below:
```json
"open.cherry_wood_fence_gate" : {
"category" : "block",
"max_distance" : null,
"min_distance" : null,
"sounds" : [
"sounds/block/cherry_wood_fence_gate/toggle1",
"sounds/block/cherry_wood_fence_gate/toggle2",
"sounds/block/cherry_wood_fence_gate/toggle3",
"sounds/block/cherry_wood_fence_gate/toggle4"
]
},

...

"close.cherry_wood_fence_gate" : {
"category" : "block",
"max_distance" : null,
"min_distance" : null,
"sounds" : [
"sounds/block/cherry_wood_fence_gate/toggle1",
"sounds/block/cherry_wood_fence_gate/toggle2",
"sounds/block/cherry_wood_fence_gate/toggle3",
"sounds/block/cherry_wood_fence_gate/toggle4"
]
},
```
This `toggle4` sound does not exist in Bedrock Editions's default resources, meaning that sometimes the Cherry Fence Gate can play no sound.
Both Java and Bedrock don't have this sound, so GeyserOptionalPack fixes this by redefining these sound events, and removing `toggle4` from the `sound_definitions.json` as seen below:
```json
"close.cherry_wood_fence_gate": {
"category": "block",
"max_distance": null,
"min_distance": null,
"sounds": [
"sounds/block/cherry_wood_fence_gate/toggle1",
"sounds/block/cherry_wood_fence_gate/toggle2",
"sounds/block/cherry_wood_fence_gate/toggle3"
]
},
"open.cherry_wood_fence_gate": {
"category": "block",
"max_distance": null,
"min_distance": null,
"sounds": [
"sounds/block/cherry_wood_fence_gate/toggle1",
"sounds/block/cherry_wood_fence_gate/toggle2",
"sounds/block/cherry_wood_fence_gate/toggle3"
]
}
```
See https://bugs.mojang.com/browse/MCPE-168021 for the associated bug report.
4 changes: 2 additions & 2 deletions manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@
"description": "Optional Bedrock resource pack to extend Geyser functionality",
"name": "GeyserOptionalPack",
"uuid": "e5f5c938-a701-11eb-b2a3-047d7bb283ba",
"version": [1, 0, 9],
"version": [1, 0, 10],
"min_engine_version": [ 1, 16, 0 ]
},
"modules": [
{
"description": "GeyserOptionalPack",
"type": "resources",
"uuid": "eebb4ea8-a701-11eb-95ba-047d7bb283ba",
"version": [1, 0, 9]
"version": [1, 0, 10]
}
]
}
25 changes: 25 additions & 0 deletions sounds/sound_definitions.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
{
"format_version": "1.20.20",
"sound_definitions": {
"close.cherry_wood_fence_gate": {
"category": "block",
"max_distance": null,
"min_distance": null,
"sounds": [
"sounds/block/cherry_wood_fence_gate/toggle1",
"sounds/block/cherry_wood_fence_gate/toggle2",
"sounds/block/cherry_wood_fence_gate/toggle3"
]
},
"open.cherry_wood_fence_gate": {
"category": "block",
"max_distance": null,
"min_distance": null,
"sounds": [
"sounds/block/cherry_wood_fence_gate/toggle1",
"sounds/block/cherry_wood_fence_gate/toggle2",
"sounds/block/cherry_wood_fence_gate/toggle3"
]
}
}
}

0 comments on commit e02280f

Please sign in to comment.