Skip to content

Player: Add sound effect for throwing the grapple string - #2902

Merged
manuq merged 8 commits into
endlessm:mainfrom
Codex-1010:grapple-throw-sfx
Sep 23, 2026
Merged

manuq merged 8 commits into
endlessm:mainfrom
Codex-1010:grapple-throw-sfx

Conversation

@Codex-1010

@Codex-1010 Codex-1010 commented Sep 16, 2026 •

Copy link
Copy Markdown
Contributor

Adds sound effects to PlayerHook:

  • When an item is hooked
  • When the string hits the air
  • When the string hits a wall

Resolves #1918

@Codex-1010
Codex-1010 requested a review from a team as a code owner September 16, 2026 04:31
@github-actions

github-actions Bot commented Sep 17, 2026 •

Copy link
Copy Markdown

Test build no longer available.

@manuq manuq left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not an expert but I think this sounds very well! Check my request on unique names. Also your pull request description seems outdated:

Adds a sound effect that plays when the player throws the grappling hook string, using the "string_thrown" signal already emitted in "_new_hook_string()". The sound "Whip woosh" by ErikCruzDev (CC0) was used, licensed via a ".license" file following the project's REUSE convention. This addresses part of #1918 — specifically the "throwing thread" sound.

This PR is playing the sound directly in _new_hook_string(). This means that it will also play when making contact with the first hookable item (pin, needle, or any other). I don't think it's bad, I just mention it because reading the ticket #1918 that case could have a differrent sound effect.

Probably you intended to use the "string_thrown" signal and add the sound to the player scene. Another option would be to add it to the AnimationPlayer throw_string animation. I think what you have is good for now, just update the description to match the implementation.

Also please add the following as the last line in the description:

Helps https://github.com/endlessm/threadbare/issues/1918

We use "Helps" when the PR doesn't fully adress the issue. Thanks!

@onready var phantom_camera_2d: PhantomCamera2D = %PhantomCamera2D

## Plays a sound effect when the string is thrown.
@onready var throw_audio_player: AudioStreamPlayer2D = $ThrowAudioPlayer

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please give a unique name to the new node, and reference it here with %. See the other @onready variables in this same file. This is documented in https://github.com/endlessm/threadbare/wiki/Contributing#coding-style

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done, thanks for the pointer, updated all 5 audio player nodes to use unique names

@Codex-1010
Codex-1010 requested a review from a team as a code owner September 23, 2026 04:47
@manuq

manuq commented Sep 23, 2026 •

Copy link
Copy Markdown
Collaborator

@Codex-1010 I did a number of fixes myself because we would like to add this into the next release. Please continue iterating on the sound effects if you want, in a separate pull request. I found that the "fail" sound wasn't transmiting failure, and the opposite was happening with the "hooked" sound, it was a bit too sad. So I played with the volume and pitch. All of the sound effects were playing at the default 0 db recorded sound. Also:

  • The bus was not correct, it was in the master bus. It should be in SFX.
  • I removed the collected sound, because that seems more proper to be added into the item, when collected.
  • I moved the AudioStreamPlayer2D nodes to the PlayerHook scene, and updated their names to match the code.
  • I also changed when to play them in the script, and always play the throw effect combined with the others.
  • Also I updated the name of the license files. They should have the audio extension too. For example grapple_fail.ogg.license (not grapple_fail.license)

@manuq

manuq commented Sep 23, 2026

Copy link
Copy Markdown
Collaborator

@Codex-1010 these two license files are empty:

  • assets/third_party/sounds/grapple/grapple_collect.wav.license
  • assets/third_party/sounds/grapple/grapple_hit.wav.license

Sorry but I will have to leave this out of the next release if you don't provide them. Don't worry though, there will be another release soon!

@Codex-1010

Copy link
Copy Markdown
Contributor Author

@manuq Sorry about that! Just fixed both license files grapple_hit.wav.license, grapple_collect.wav.license, they now have the proper CC0 attribution. Thanks a lot for all the fixes and for taking the time to polish this for the release, really appreciate the feedback on the sound

@manuq
manuq merged commit d4b0acf into endlessm:main Sep 23, 2026
6 checks passed
@manuq

manuq commented Sep 23, 2026

Copy link
Copy Markdown
Collaborator

@Codex-1010 thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add grappling sound effects

2 participants