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

Audit .223 STANAG magazines, add max_item_length to ammo pouches #46251

Conversation

Salty-Panda
Copy link
Contributor

@Salty-Panda Salty-Panda commented Dec 22, 2020

Summary

SUMMARY: Balance "Audit .223 STANAG magazines, add max_item_length to ammo pouches"

Purpose of change

Weights were very random
Volumes were illogical (Stanag 20 was heavier and bigger than Stanag 30)
Magazines had no max length.

Secondary: Dedicated ammo containers don't have a max_item_length set. Pockets are limited by MAG_COMPACT, but the game defaults them to small max_item_length.

Describe the solution

  • Audited based on real-world information where I could find them and estimations where I couldn't

  • Add max_item_length to ammo pouches
    Set max_item_length of AMMO_COMPACT pouches to 24cm, MAG_BULKY ones to 30cm.

Describe alternatives you've considered

Do nothing

Testing

Put Stanag 30 (19cm) into various ammo pouches that accept MAG_COMPACT and have a limit of 24cm.
Failed to put Stanag 100 (35cm) into those pouches.
Failed to put Stanag 50 drum into those pouches.
Put Stanag 50 drum into tac vest, which accepts MAG_BULKY

Additional context

Detailed spreadsheet, source links, estimations marked
https://docs.google.com/spreadsheets/d/1foxk7S1diwP7s4NVytM_bDT-L7ymwDXIxicEA4Ti1vI/edit?usp=sharing

@mlangsdorf mlangsdorf added <Bugfix> This is a fix for a bug (or closes open issue) Items: Ammo / Guns Ammunition for all kinds of weapons and these weapons themselves Items: Magazines Ammo holding items and objects. labels Dec 22, 2020
@actual-nh
Copy link
Contributor

actual-nh commented Dec 22, 2020

The travis build is having (possibly as well as others like it) a bunch of "ERROR : src/item.cpp:1053 [ret_val item::put_in(const item &, item_pocket::pocket_type)] tried to put an item (stanag30) count (1) in a container (legpouch_large) that cannot contain it: pockets unacceptable because item is too long" lines. (There's also something in the weary test at the end that is unrelated to this PR.)

@Salty-Panda
Copy link
Contributor Author

Salty-Panda commented Dec 22, 2020

The travis build is having (possibly as well as others like it) a bunch of "ERROR : src/item.cpp:1053 [ret_val item::put_in(const item &, item_pocket::pocket_type)] tried to put an item (stanag30) count (1) in a container (legpouch_large) that cannot contain it: pockets unacceptable because item is too long" lines. (There's also something in the weary test at the end that is unrelated to this PR.)

Leg ammo pouch doesn't have set length. Its pockets are limited to MAG_COMPACT, which is flag that .223 Stanag 30 mags have.
I tried giving ammo pouch "longest_side": "300 mm",, but the same error happened during loading the game.

In the game, its pocket's max item length is set to 113mm
No item in ammo_pouch.json has set pocket's max item length other than Javelin bag.

@Salty-Panda
Copy link
Contributor Author

Salty-Panda commented Dec 22, 2020

There are 33 occurrences of \"flag_restriction\"\:.*MAG, which I assume account for all dedicated ammo containers.
I'll extend this PR by adding max_item_length to them, probably somewhat blindly, since the main restriction is already there, the flag.

@Salty-Panda Salty-Panda changed the title Audit .223 STANAG magazines Audit .223 STANAG magazines, add max_item_length to ammo pouches Dec 22, 2020
@BrettDong BrettDong added the [JSON] Changes (can be) made in JSON label Jan 7, 2021
@ZhilkinSerg ZhilkinSerg merged commit 07e0c94 into CleverRaven:master Jan 8, 2021
@Salty-Panda Salty-Panda deleted the Streamline-223-magazines-volumes,-add-lenghts branch January 8, 2021 11:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
<Bugfix> This is a fix for a bug (or closes open issue) Items: Ammo / Guns Ammunition for all kinds of weapons and these weapons themselves Items: Magazines Ammo holding items and objects. [JSON] Changes (can be) made in JSON
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants