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

shotgunshell boxes and big creates are not linked in reqestion vendor #6096

Closed
3 tasks done
cuberound opened this issue Apr 6, 2024 · 5 comments
Closed
3 tasks done
Assignees
Labels
Consistency Issue Who needs consistency?

Comments

@cuberound
Copy link
Contributor

Testmerges

#5938: 'Adds Shockwaves to Explosions and Xeno Screeches ' by GrrrKitten at commit 23c093f #5914: 'Ports stripping menu from TG' by ihatethisengine at commit ac0caeb #6015: 'Colony Synthetic variants with a refresh' by QuickLode at commit c6f1f9a #6040: 'Better throw logic' by Git-Nivrak at commit 7314763 #5401: 'M540-B Armored Recon Carrier' by Zonespace27 at commit 6cbd84f #6039: 'Project ARES TM Holder (v5)' by realforest2001 at commit 20f293b

Round ID

21640

Description of the bug

possibly more of an oversight, with nades and other ammo the huge boxes share ammo with normal mags, aka when you take box with 10 m41a mags tere is 10 less m41a mags less in the vendor . does not work with shotgun shell boxes

What's the difference with what should have happened?

there should be 4 times the number of small boxes as large boxes and when you vend large box it reduces number of small boxes by 4

How do we reproduce this bug?

1.check number of boxes
2.vend big box
3.check again, it is the same

Issue Bingo

@cuberound cuberound added the Bug Admin events aren't bugs label Apr 6, 2024
@Huffie56 Huffie56 added Consistency Issue Who needs consistency? and removed Bug Admin events aren't bugs labels Apr 8, 2024
@Huffie56
Copy link
Contributor

this PR added the logic for it. should be a good start to look into it
#1759

@ThePiachu
Copy link
Contributor

As I'm looking at my old code, the Shotgun shell boxes were never integrated into the change since they are a weirder case. Shotgun Shell Box contains handfuls of shotgun shells, not full Box Of XXX Shells. So you'd have to have a separate code converting Shell Boxes into handfuls and those back into Boxes of Shells. I guess it would be doable, especially if you add individual handfuls of ammo into the vendor itself...

@ThePiachu
Copy link
Contributor

Looking more into it, another cursed thing about shotgun shells is that they aren't magazines, but handfuls, and the two type of Boxes kind of handle them differently... Might be a bit complicated to get this thing straight...

@ThePiachu ThePiachu self-assigned this Jun 6, 2024
@ThePiachu
Copy link
Contributor

Okay, I think I've got it. Will also clean up something else I had an idea to do with vendors years back...

github-merge-queue bot pushed a commit that referenced this issue Jul 7, 2024
# About the pull request

Fixes Issue #6096

Some small improvements around the code that handles Requisitions' ammo
box vendor filling logic. It now handles boxes that use handfuls
(shotgun boxes) and also checks the vendor's inventory for if the boxes
already exist to let the devs order them neatly as needed.

Also neatly added the various boxes to Requisitions' vendors that were
auto-populated before.

# Explain why it's good for the game

It makes the vendors nicer to use and keeps the ammo boxes consistent.

# Testing Photographs and Procedure

- Check Requisitions' vendors
- Vend shotgun ammo boxes big and small to see the ratios are maitained

<details>
<summary>Screenshots & Videos</summary>


![image](https://github.com/cmss13-devs/cmss13/assets/964559/695302b3-c62a-4d0b-98a1-0cb1b50d557a)

</details>


# Changelog
:cl: ThePiachu
qol: Shotgun ammo boxes now behave like other ammo boxes in the
Requisitions' vendors.
code: Ammo box maping code now handles pre-populated boxes in vendors,
letting devs order them more neatly than before.
/:cl:

---------

Co-authored-by: harryob <[email protected]>
@ThePiachu
Copy link
Contributor

Should be completed via #6397

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Consistency Issue Who needs consistency?
Projects
None yet
Development

No branches or pull requests

3 participants