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

Speedloaders for Internal Magazine Weapons #29807

Closed

Conversation

Cojoke-dot
Copy link
Contributor

@Cojoke-dot Cojoke-dot commented Jul 7, 2024

About the PR

Adds speedloaders for shotguns and makes the SpeedLoaderLightRifle function like a speedloader.

Why / Balance

This was more made for a system that would let people quickly load internal mags the same way that revolvers do. Neither of the speedloaders mentioned are currently obtainable, but replacing the .30 rifle ammo box in the uplink with the light rifle speedloader would be nice. If people want I could add the shotgun speedloader to the secfab, but I don't think that would balance all that well with the existence of the bulldog. If I do it would be in another pr.

Technical details

Check if the object interacting with the gun has the SpeedLoaderComponent in the OnBallisticInteractUsing. Gets the empty slots in the shotgun, does a TakeAmmoEvent to clear them out of the speedloader, and then adds them to the weapon.

Media

2024-07-07.20-26-46.mp4
  • I have added screenshots/videos to this PR showcasing its changes ingame, or this PR does not require an ingame showcase

Breaking changes

Changelog

no cl, nothing players can obtain has been changed

@github-actions github-actions bot added the Changes: Sprites Changes: Might require knowledge of spriting or visual design. label Jul 8, 2024
Copy link
Contributor

github-actions bot commented Jul 8, 2024

RSI Diff Bot; head commit abb9c24 merging into 9f55000
This PR makes changes to 1 or more RSIs. Here is a summary of all changes:

Resources/Textures/Objects/Weapons/Guns/Ammunition/SpeedLoaders/Shotgun/shotgun_speed_loader.rsi

State Old New Status
base-1 Added
base-2 Added
base-3 Added
base-4 Added
base Added

Edit: diff updated after abb9c24

@Cojoke-dot Cojoke-dot marked this pull request as ready for review July 8, 2024 01:31
@github-actions github-actions bot added the S: Needs Review Status: Requires additional reviews before being fully accepted label Jul 8, 2024
@IProduceWidgets
Copy link
Contributor

IProduceWidgets commented Jul 8, 2024

I had to look it up, but shotgun "speed loaders" are apparently a thing. Sort of. They're somewhere between a neat idea someone had to justify their 3d printer and a bad substitute for just practicing with a shotgun.
I could not however find any that load seven shells because they'd be long as hell. I'd just make it load 4 like the sprite implies and then it fits the kammerer where it's mildly more justifiable. am blind. I think it would make a decent science tech.

The stripper clip is good though, I like that.

@IProduceWidgets
Copy link
Contributor

On further thought, it might be good to make the speedloaders require doafters.
Does the revolver require one? I can't recall.
Either way, while it does probably take the same amount of loading time at the moment, having these does represent a pretty big improvement to RoF of the best guns on the game (shotguns). To be clear, I'm not saying a long doafter, I'm thinking the same as what it takes to load one round.

@IProduceWidgets
Copy link
Contributor

Also reminds me we could really use a visualizer that can layer these based on the contained ents so it can show the right shells. That's out of scope for now though imo.

@Cojoke-dot
Copy link
Contributor Author

Does the revolver require one?

Nah, speed loaders are instant for revolvers

Also reminds me we could really use a visualizer that can layer these based on the contained ents so it can show the right shells. That's out of scope for now though IMO.

I would have to look into how revolvers do it, I just wanted a basic sprite so I did not ask for too much from the person who made the sprites.

I think it would make a decent science tech.

My biggest issue with the shotgun speed loader is how it devalues the advantage of the bulldog. The bulldog would still be better, it would just only be better due to 1 extra capacity and less space for ammo rather than the speed at which you load it. Sci tech would be fine if war ops was not a thing. Its really the only time it would be good and the only time it would be researched.

@Plykiya
Copy link

Plykiya commented Jul 8, 2024

Does the revolver require one?

Nah, speed loaders are instant for revolvers

imo just give this one a do-after and add it to the lathes, bulldogs will still be superior because their ammo swap wouldn't require a do-after

@IProduceWidgets
Copy link
Contributor

Also reminds me we could really use a visualizer that can layer these based on the contained ents so it can show the right shells. That's out of scope for now though IMO.

I would have to look into how revolvers do it, I just wanted a basic sprite so I did not ask for too much from the person who made the sprites.

They don't, that's why it reminded me.

Comment on lines +76 to +82

component.Entities.Add(ent.Value);
Containers.Insert(ent.Value, component.Container);

if (IsClientSide(ent.Value))
Del(ent.Value);

Copy link
Contributor

Choose a reason for hiding this comment

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

Why is this inserting then deleting it?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is what happens without the delete. OnBallisticAmmoFillDoAfter does the same thing

2024-08-08.21-51-03.mp4

Comment on lines +56 to +58

if (EntityManager.HasComponent<SpeedLoaderComponent>(args.Used))
{
Copy link
Contributor

Choose a reason for hiding this comment

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

Why is this doubling the existing speedloaders? It's not even using a whitelist or anything.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

What do you mean by this? Doubling the existing speedloaders? It is also using a whitelist for anything inserted.
image

Comment on lines +83 to +84
if (ev.Ammo.Count == 0)
break;
Copy link
Contributor

Choose a reason for hiding this comment

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

The event one is just a ref to the local variable, is this even possible here? It's being iterated in the loop.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It seems to work, is there another way to do this that's preferred or is that fine?

2024-08-08.22-00-55.mp4

@metalgearsloth metalgearsloth added S: Awaiting Changes Status: Changes are required before another review can happen and removed S: Needs Review Status: Requires additional reviews before being fully accepted labels Aug 8, 2024
Copy link
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@github-actions github-actions bot added the S: Merge Conflict Status: Needs to resolve merge conflicts before it can be accepted label Aug 12, 2024
@github-actions github-actions bot removed the S: Merge Conflict Status: Needs to resolve merge conflicts before it can be accepted label Aug 12, 2024
@github-actions github-actions bot added the S: Merge Conflict Status: Needs to resolve merge conflicts before it can be accepted label Sep 9, 2024
Copy link
Contributor

github-actions bot commented Sep 9, 2024

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@SlamBamActionman SlamBamActionman added the S: Untriaged Status: Indicates an item has not been triaged and doesn't have appropriate labels. label Nov 14, 2024
@eoineoineoin eoineoineoin added P3: Standard Priority: Default priority for repository items. T: New Feature Type: New feature or content, or extending existing content D3: Low Difficulty: Some codebase knowledge required. T: Balance Change Type: Balance changes through direct value changes, or changes to mechanics that affect it A: Art Area: Art with no implications for other areas. A: Combat Area: Combat features and changes, balancing, feel and removed S: Untriaged Status: Indicates an item has not been triaged and doesn't have appropriate labels. labels Nov 18, 2024
@K-Dynamic
Copy link
Contributor

Are you still working on this

Also I'd consider removing the drum mags from sec techfabs since the only drum-fed shotguns are Syndicate weapons.

Copy link
Contributor

This pull request has conflicts, please resolve those before we can evaluate the pull request.

@TheShuEd
Copy link
Member

image
Seems derelict for me
If you wanna continue work, comment for reopen

@TheShuEd TheShuEd closed this Dec 20, 2024
@TheShuEd TheShuEd added the S: Derelict Status: Abandoned, but may contain something that can be salvaged. label Dec 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A: Art Area: Art with no implications for other areas. A: Combat Area: Combat features and changes, balancing, feel Changes: Sprites Changes: Might require knowledge of spriting or visual design. D3: Low Difficulty: Some codebase knowledge required. Merge Conflict P3: Standard Priority: Default priority for repository items. S: Awaiting Changes Status: Changes are required before another review can happen S: Derelict Status: Abandoned, but may contain something that can be salvaged. S: Merge Conflict Status: Needs to resolve merge conflicts before it can be accepted T: Balance Change Type: Balance changes through direct value changes, or changes to mechanics that affect it T: New Feature Type: New feature or content, or extending existing content
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants