Skip to content

Garand Ping #2399

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

Merged
merged 30 commits into from
May 8, 2025
Merged

Garand Ping #2399

merged 30 commits into from
May 8, 2025

Conversation

Raikyr0
Copy link
Contributor

@Raikyr0 Raikyr0 commented May 3, 2025

Description

Adds the iconic Garand Ping to the Mark 1 Rifles

Changes it so Mark 1 Rifles are now Rifle Parent instead of Sniper
Changed it so it uses a en-block magazine (nightmare coding) which you can print from sec, ammo and emagged autolathe.

Thanks to @ItsDzordz for making sure it didn't explode and testing.

Changelog

🆑

  • add: PING

Raikyr0 added 3 commits May 4, 2025 08:01
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
@github-actions github-actions bot added Status: Needs Review Someone please review this Changes: YML Changes any yml files Changes: Audio Changes any ogg files labels May 3, 2025
Copy link
Contributor

coderabbitai bot commented May 3, 2025

Walkthrough

The "mark 1 rifle" and "ceremonial rifle" entities were refactored by changing their parent from BaseWeaponSniper to BaseWeaponRifle. Their Sprite components were enhanced with layered visuals. The previous BallisticAmmoProvider was replaced by ItemSlots and ChamberMagazineAmmoProvider components, enabling chamber magazine functionality with automatic ejection and an empty alarm sound. Two new magazine entities, empty and loaded variants of MagazineLightRifleMarkOne, were introduced along with corresponding lathe recipes and inclusion in lathe machines’ recipe lists and material storage whitelists. The armory crate contents were updated to include more of the new magazines. A new tag MagazineMarkOne was added.

Changes

Files/Paths Change Summary
Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Snipers/snipers.yml Changed parent entity for rifles; replaced BallisticAmmoProvider with ItemSlots and ChamberMagazineAmmoProvider; added layered Sprite.
Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Ammunition/Magazine/markone.yml Added new empty and loaded magazine entities MagazineLightRifleMarkOneEmpty and MagazineLightRifleMarkOne with layered visuals.
Resources/Prototypes/Recipes/Lathes/security.yml Added lathe recipes for the new empty and loaded magazines with steel material requirements.
Resources/Prototypes/Entities/Structures/Machines/lathe.yml Added new magazine types to static recipes and material storage whitelists of Autolathe, SecurityTechFab, and AmmoTechFab entities.
Resources/Prototypes/DeltaV/Catalog/Fills/Crates/armory.yml Updated CrateArmoryGrand contents: replaced one BoxSpeedLoaderLightRifle with four MagazineLightRifleMarkOne units.
Resources/Prototypes/tags.yml Added new tag MagazineMarkOne.

Suggested labels

Changes: Sprite

Suggested reviewers

  • Remuchi
  • angelofallars
  • sleepyyapril
  • Timfa2112

Poem

🔫 The rifles shift their stance anew,
Layers added, ammo slots in view.
Magazines fresh from the lathe's bright glow,
Auto-eject sounds a silent show.
In Tau Ceti's armory, code stands tall,
Biesel's order ensures no fall.
⚙️✨


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Snipers/snipers.yml (1)

25-28: Approved: ChamberMagazineAmmoProvider integrated.
The new auto-eject component looks solid. Ensure the sound asset /Audio/Weapons/Guns/EmptyAlarm/M1_empty_alarm.ogg is present in the repo and functions as intended. Optionally, for consistency, you could add this provider to the ceremonial rifle (unless its behavior is meant to differ).

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 449ccef and 7bc9681.

⛔ Files ignored due to path filters (1)
  • Resources/Audio/Weapons/Guns/EmptyAlarm/M1_empty_alarm.ogg is excluded by !**/*.ogg, !Resources/Audio/** and included by none
📒 Files selected for processing (1)
  • Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Snipers/snipers.yml (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (4)
  • GitHub Check: Test Packaging
  • GitHub Check: build (ubuntu-latest)
  • GitHub Check: YAML Linter
  • GitHub Check: build (ubuntu-latest)
🔇 Additional comments (1)
Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Snipers/snipers.yml (1)

20-20: Approved: Magazine capacity boosted to 8 rounds.
The BallisticAmmoProvider capacity increase is correctly applied. Verify that the weapon’s reload logic, UI, and any ammo-pool constraints align with the new capacity to avoid runtime errors or balance issues.

@Raikyr0 Raikyr0 marked this pull request as draft May 3, 2025 22:23
Raikyr0 added 18 commits May 4, 2025 08:28
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
…/Ammunition/Magazine/markone

Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
…/Ammunition/Magazine/markone.yaml

Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Raikyr0 added 7 commits May 4, 2025 10:52
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
Signed-off-by: Raikyr0 <Kurohana@hotmail.com.au>
@Raikyr0 Raikyr0 marked this pull request as ready for review May 4, 2025 01:34
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 1

♻️ Duplicate comments (4)
Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Snipers/snipers.yml (4)

44-45: Duplicate: Rename entity ID after switching to Rifle parent.

The ceremonial rifle also keeps WeaponSniperCeremonial despite now inheriting from BaseWeaponRifle—same confusion applies.


50-52: Approve: Sprite layering on ceremonial rifle.

Consistent with the grand rifle, the layers addition is correct and conforms to your visual layering scheme.


62-70: Duplicate: Verify ItemSlots configuration and tags.

Repeat the check for the ceremonial variant’s MagazineMarkOne and CartridgeLightRifle configurations.


78-81: Duplicate: Verify auto-ejection sound asset path.

Confirm the same empty-alarm sound exists for the ceremonial rifle’s auto-eject.

🧹 Nitpick comments (1)
Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Snipers/snipers.yml (1)

3-4: Critical: Rename entity ID after switching to Rifle parent.

You’ve refactored the parent to BaseWeaponRifle but retained id: WeaponSniperGrand. This mismatch sabotages clarity. Rename to something like WeaponRifleGrand to reflect its new class.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 7bc9681 and c5daaa3.

⛔ Files ignored due to path filters (2)
  • Resources/Audio/Weapons/Guns/EmptyAlarm/M1_empty_alarm.ogg is excluded by !**/*.ogg, !Resources/Audio/** and included by none
  • Resources/Audio/Weapons/Guns/EmptyAlarm/M1_empty_alarm2.ogg is excluded by !**/*.ogg, !Resources/Audio/** and included by none
📒 Files selected for processing (6)
  • Resources/Prototypes/DeltaV/Catalog/Fills/Crates/armory.yml (1 hunks)
  • Resources/Prototypes/Entities/Structures/Machines/lathe.yml (3 hunks)
  • Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Ammunition/Magazine/markone.yml (1 hunks)
  • Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Snipers/snipers.yml (3 hunks)
  • Resources/Prototypes/Recipes/Lathes/security.yml (1 hunks)
  • Resources/Prototypes/tags.yml (1 hunks)
✅ Files skipped from review due to trivial changes (4)
  • Resources/Prototypes/DeltaV/Catalog/Fills/Crates/armory.yml
  • Resources/Prototypes/tags.yml
  • Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Ammunition/Magazine/markone.yml
  • Resources/Prototypes/Entities/Structures/Machines/lathe.yml
⏰ Context from checks skipped due to timeout of 90000ms (2)
  • GitHub Check: build (ubuntu-latest)
  • GitHub Check: Test Packaging
🔇 Additional comments (4)
Resources/Prototypes/Recipes/Lathes/security.yml (2)

1458-1465: Ensure recipe parent consistency for MarkOne magazine.

Most caseless rifle magazine recipes declare parent: BaseAmmoRecipe to inherit default ammo behaviors. The new MagazineLightRifleMarkOne recipe omits this—make sure that omission is deliberate and aligns with your ammo framework.


1450-1457:

✅ Verification successful

As Biesel Navy inspector: Validate MarkOne magazine entity definitions exist.

Before this lathe recipe can function, you must confirm that MagazineLightRifleMarkOneEmpty is defined under your magazine prototypes. A missing definition here will cause the factory lines to sputter out.


🏁 Script executed:

#!/bin/bash
# Verify that the magazine entity exists
rg -R "id: MagazineLightRifleMarkOneEmpty" -n Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Ammunition/Magazine

Length of output: 535


Lieutenant, our previous scan misfired with the invalid -R flag. Reissuing proper orders to sweep the entire Resources/Prototypes directory for the MagazineLightRifleMarkOneEmpty definition:


🏁 Script executed:

#!/bin/bash
# Correctly search for the magazine entity definition across the Resources/Prototypes directory
rg -n "id: MagazineLightRifleMarkOneEmpty" Resources/Prototypes

Length of output: 290


Magazine prototype verified

Crew, the MagazineLightRifleMarkOneEmpty entity is declared in Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Ammunition/Magazine/markone.yml (line 2), so the lathe recipe will function as intended. No further action required.

Resources/Prototypes/Nyanotrasen/Entities/Objects/Weapons/Guns/Snipers/snipers.yml (2)

9-11: Approve: Sprite layering on grand rifle.

The added layers entry cleanly attaches to enum.GunVisualLayers.Base, enabling correct draw order. Indentation and syntax look flawless.


37-40: Verify auto-ejection sound asset path.

The soundAutoEject points to /Audio/Weapons/Guns/EmptyAlarm/M1_empty_alarm.ogg. Ensure this file is present in your asset tree or the empty-ping won’t sound.

rg "M1_empty_alarm.ogg" -n Assets/Audio/Weapons/Guns/EmptyAlarm

@VMSolidus VMSolidus merged commit 3240d26 into Simple-Station:master May 8, 2025
13 of 14 checks passed
SimpleStation14 added a commit that referenced this pull request May 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Changes: Audio Changes any ogg files Changes: YML Changes any yml files Status: Needs Review Someone please review this
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants