Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issue with bashing satalight dish and negative noise #78482

Merged
merged 1 commit into from
Dec 11, 2024

Conversation

WhaleYogurt
Copy link
Contributor

@WhaleYogurt WhaleYogurt commented Dec 11, 2024

Pull Request: Fix Negative Sound When Smashing Satellite Dish

Summary

Bugfixes "Fix negative sound when smashing satellite dish"


Purpose of Change

This change resolves issue #77823, where smashing a satellite dish produced an error for a negative sound volume. The expected behavior is for a positive sound value to be generated when the dish is smashed, providing appropriate feedback to the player.


Describe the Solution

The fix involves adding bash properties to the satellite dish item, including:

  • Strength-based bashing effects:
    • str_min: 6
    • str_max: 10
  • Sound effects:
    • sound: "whack!" for successful bashing
    • sound_fail: "womp!" for failed bashing
  • Material drops:
    • Items dropped include scrap (4–6 units) and plastic_chunk (4–12 units).

These changes resolves the negative sound bug.


Testing

The following steps were taken to test the fix:

  1. Verified the JSON structure for correctness.
  2. Loaded the game with the modified satellite dish properties and tested:
    • Bashing the dish produces the correct sounds: "whack!" or "womp!" depending on success or failure.
    • No errors related to negative sound values are encountered.
    • Materials (scrap and plastic_chunk) drop as intended.
    • Strength thresholds (str_min and str_max) are respected during bashing.

Additional Context

This change improves gameplay interactions with the satellite dish and resolves the error encountered when smashing it. Below is an example of the new bash properties in JSON format:

"bash": {
  "str_min": 6,
  "str_max": 10,
  "sound": "whack!",
  "sound_fail": "womp!",
  "items": [
    { "item": "scrap", "count": [ 4, 6 ] },
    { "item": "plastic_chunk", "count": [ 4, 12 ] }
  ]
}

Related Issues

Fixes #77823.

@github-actions github-actions bot added [JSON] Changes (can be) made in JSON Fields / Furniture / Terrain / Traps Objects that are part of the map or its features. <Bugfix> This is a fix for a bug (or closes open issue) astyled astyled PR, label is assigned by github actions json-styled JSON lint passed, label assigned by github actions labels Dec 11, 2024
@Night-Pryanik Night-Pryanik merged commit 1684d63 into CleverRaven:master Dec 11, 2024
23 of 28 checks passed
@github-actions github-actions bot added the BasicBuildPassed This PR builds correctly, label assigned by github actions label Dec 11, 2024
@WhaleYogurt WhaleYogurt deleted the satelight-dish-fix branch December 11, 2024 13:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
astyled astyled PR, label is assigned by github actions BasicBuildPassed This PR builds correctly, label assigned by github actions <Bugfix> This is a fix for a bug (or closes open issue) Fields / Furniture / Terrain / Traps Objects that are part of the map or its features. [JSON] Changes (can be) made in JSON json-styled JSON lint passed, label assigned by github actions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Negative Sound When Smashing Satellite Dish
2 participants