Skip to content
This repository has been archived by the owner on Apr 14, 2020. It is now read-only.

Merger from FastTrack fork - Phase I (Core) #1006

Merged

Conversation

sumghai
Copy link
Contributor

@sumghai sumghai commented Feb 19, 2020

Phase I of the Merger from the CE:FT fork, containing just the Core changes:

  • Added new real-world and genericized sci-fi ammo, projectiles and textures added:
    • 6, 8 and 12 mm Railgun cartridges
    • Plasma Heavy, Pistol and Rifle Power Cells
    • 50 mm GS-50 Grenades
    • 20x102mm NATO, 20x128mm Oerlikon, 25x137mm NATO and 30x173mm NATO High Caliber cartridges
    • .455 Webley and 7.65x20mm Longue Pistol cartridges
    • 130mm Type 63 and 70mm APKWS Rockets
    • Tomahawk TLAM missile
    • 100x695mmR, 120mm tank cannon, 155mm Howitzer, 28cm Spgr., 40x365mm Bofors, 57x483mm Bofors and 76.2x385mmR Cannon shells
  • Added Non-Lethal (Tranq) ammo type and hediff
    • Separate tranq-only ammosets for 9x19mm Para and 7.62x51mm NATO, implemented to support at least two different Metal Gear Solid-themed mods (therefore genericized)
  • Removed mod-unique ammo from main CE ammo library
    • These should be re-implemented as conditional PatchOps within their respective mods' compatibility patches
  • Added new BodyShapeDef for vehicle pawns
  • Changed description of CE Heavy Weapons research project to expand scope to include automatic grenade launchers and artillery
  • Added a new Graphic_StackCountRanged graphicClass that gives modders better control over what graphic is displayed for an item based on the current stack count; this works by retrieving the upper limit for each stack size interval from the filenames of the graphics themselves
  • Added an optional ammoConsumedPerShotCount xml tag that allows ranged weapons to consume multiple rounds of ammunition simultaneously per shot or trigger pull, such as double-barrelled shotguns or Metal Storm-style multi-barrel weapons turrets; setting this value to 0,1 or omitting it altogether will cause the weapon to default to standard CE behaviour of one ammo consumed per shot (ensuring backwards compatibility with all existing weapons patches)

NOTE: Some manual merging and fixes may be required, due to de-synchronization between CE and FT teams as a result of time zone differences

sumghai and others added 30 commits November 9, 2019 01:30
Sync with upstream repo - v1.0.1.6a v4
Sync with upstream repo - v1.0.1.6b v1
Sync with upstream repo - v1.0.1.6b v6
For #69

CE:FT/RN exclusive content. All stock CE thrown grenades were already patched from upstream.
For #135

Update courtesy of @Magichp, who originally provided these files via Mediafire
@zozilin zozilin self-requested a review February 19, 2020 14:10
@Alicecomma Alicecomma mentioned this pull request Feb 19, 2020
@N7Huntsman
Copy link
Contributor

The new high caliber shells need FMJ added, and some are missing other ammo types as well. These can be added later, but they do need to be added.

@N7Huntsman
Copy link
Contributor

@sumghai Based on our discussion, what'd we determine for the tranq rounds? Were we going to make them a base ammo type (which may require we add them to a bunch of other rifle and pistol rounds) or just make them a patched ammo type for whatever patches need them?

zozilin added a commit that referenced this pull request Feb 19, 2020
zozilin added a commit that referenced this pull request Feb 19, 2020
zozilin added a commit that referenced this pull request Feb 19, 2020
…rger

Revert "Update CombatExtended.dll for #1006"
@zozilin
Copy link
Collaborator

zozilin commented Feb 19, 2020

Source/CombatExtended/CombatExtended/Projectiles/BulletCE.cs
Forgot to remove FastTrack Edition

I updated that

@sumghai looks good to me. Will be merged as soon as @N7Huntsman reviews ammunition and all connected issues (if any) are resolved.

Copy link
Contributor

@Alicecomma Alicecomma left a comment

Choose a reason for hiding this comment

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

DamageDef Tranquilizer is missing to give to Bullet_9x19mmPara_NL (Defs/Ammo/Pistols/9x19mmPara_NL.xml), Bullet_762x51mmNATO_NL (Defs/Ammo/Rifle/762x51mmNATO_NL.xml)

Copy link
Contributor

@Alicecomma Alicecomma left a comment

Choose a reason for hiding this comment

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

Errors from texture paths:
Things/Ammo/RPG/SMAW_HEAT (Ammo/Rocket/83mmSMAW.xml)
Things/Ammo/RPG/SMAW_Thermobaric (Ammo/Rocket/83mmSMAW.xml)
Things/Projectile/RPG/SMAW_HEAT (Ammo/Rocket/83mmSMAW.xml)
Things/Projectile/RPG/SMAW_Thermobaric (Ammo/Rocket/83mmSMAW.xml)
Things/Projectile/RPG/AT4 (Ammo/Rocket/84mmAT4.xml)
Things/Projectile/RPG/MATADOR (Ammo/Rocket/90mmMATADOR.xml)
Things/Projectile/RPG/M72LAW (Ammo/Rocket/M72LAW.xml)
Things/Ammo/RPG/M74 (Ammo/Rocket/M74.xml)
Things/Projectile/RPG/M74 (Ammo/Rocket/M74.xml)

Copy link
Contributor

@Alicecomma Alicecomma left a comment

Choose a reason for hiding this comment

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

ThingCategoryDef.AmmoMissiles is missing to give to TomahawkLAM (Defs/Ammo/Rocket/TomahawkLAM.xml)

@sumghai
Copy link
Contributor Author

sumghai commented Feb 20, 2020

@N7Huntsman

The new high caliber shells need FMJ added, and some are missing other ammo types as well. These can be added later, but they do need to be added.

Based on real-life manufacturers' brochures and data, those High Caliber rounds were never available in FMJ.

As for certain shells not having EMP variants, fair point.

(In general, I'm a wee bit apprehensive about adding ammo types to calibers that never had those variants in real life - for example, the Imperial Japanese Army never manufactured the 8x22mm Nambu in anything other than FMJ, yet CE has AP and HP variants)

Based on our discussion, what'd we determine for the tranq rounds? Were we going to make them a base ammo type (which may require we add them to a bunch of other rifle and pistol rounds) or just make them a patched ammo type for whatever patches need them?

In short, I proposed making them a base ammo type, but only available in certain (9x19mm Para and 7.62x51mm NATO) calibers, and in separate tranq-only ammosets.

This is because the other, usual two options are currently inappropriate:

  • Designating them mod-unique and implementing them as conditional patches would only work if there was only one Metal Gear Solid mod out there; as it stands, there are at least two different MGS faction mods that use these particular ammo, and since it is possible that a player may be running both mods, having them both conditionally patch the same two tranq ammo may cause issues with duplicate ammo defs

  • On the other hand, updating every single other Pistol/Rifle caliber and ammosets to also have tranq variants creates a lot of unnecessary work, and is thematically inaccurate to boot (as the essence of the two different MGS mods are that only two specific weapons can exclusively fire tranq ammo)

If it is possible to conditionally patch the tranq ammo for both MGS mods without resulting in duplicate defs when both mods are active in a savegame, then I may be partial to regular policy number one (as above).

@Alicecomma - something must've borked very badly in the upstream_merger_core branch of CEFT for the texture references to be incorrect.

@N7Huntsman
Copy link
Contributor

N7Huntsman commented Feb 20, 2020

@sumghai

Based on real-life manufacturers' brochures and data, those High Caliber rounds were never available in FMJ.

I can appreciate your position, but ultimately I think there was an acknowledgement that we're sort of left filling in a lot of "gaps" with these ammo types--even the ones on the list that did exist aren't necessarily accurate to their actual specifications just because of the reality that it'd be a full-time job for a professional researcher to find all the information.

I wouldn't worry about it for now anyway--I'll generate the other ammo types and get them added on our end to save you the distraction from the merger.

Designating them mod-unique and implementing them as conditional patches would only work if there was only one Metal Gear Solid mod out there

A PatchOperationFindMod will allow us to keep the conditional, even for multiple mods. The following PatchOp will execute if one or multiple targeted mods are active:

<Operation Class="PatchOperationFindMod"> <mods> <li>MGS Mod 1</li> <li>MGS Mod 2</li> </mods> <match ... (Add ammo)

@N7Huntsman
Copy link
Contributor

N7Huntsman commented Feb 20, 2020

@sumghai Additionally, I noticed while reviewing the ammo that it seems that perhaps FT's sabot rounds are generated (when there's not RL data to use) somewhat different to CE? Are there any particular metrics FT uses?

For CE, they're generated as:

  • Sabot Bullet Diameter = 0.7*Base Bullet Diameter
  • Sabot Bullet Mass = 0.57*Base Bullet Mass (This is an approximation/rule of thumb I came up with while generating the original batch; it's more accurate for Rifle rounds, but it's sufficient for everything else and it's what's been used.)
  • Sabot Velocity = 1.5*Base Bullet Velocity
  • Sabot RHA Penn = 1.75*AP Ammo Penn
  • All else remains the same.

@sumghai
Copy link
Contributor Author

sumghai commented Feb 20, 2020

@N7Huntsman

I can appreciate your position, but ultimately I think there was an acknowledgement that we're sort of left filling in a lot of "gaps" with these ammo types--even the ones on the list that did exist aren't necessarily accurate to their actual specifications just because of the reality that it'd be a full-time job for a professional researcher to find all the information.

Fair point. I suppose from a Watsonian perspective, the various tribes/factions on RimWorld invented these variants to suit their needs, while the Doylist explanation would be to suit different playstyles.

As an aside, when I was calculating the stats for FT, I would spend an average of 2~3 hours' of research per caliber, and frequently add research citations to the notes for each cell. Not fun.

I wouldn't worry about it for now anyway--I'll generate the other ammo types and get them added on our end to save you the distraction from the merger.

Sounds good.

As agreed, we should use existing CE ammo textures where possible, but I can do additional graphics if required, as I have been given a copy of A_Friendo's (?) original CE art files, and I'm reasonably comfortable working to the official CE artstyle.

A PatchOperationFindMod will allow us to keep the conditional, even for multiple mods. The following PatchOp will execute if one or multiple targeted mods are active:

Ah yes, I remember this technique now.

To put things into context, the two MGS mods have separate patch folders. I can put the conditional ammo patch file in one of the two patch folders, but have the PatchOp look up either mod. I think this should work!

Additionally, I noticed while reviewing the ammo that it seems that perhaps FT's sabot rounds are generated (when there's not RL data to use) somewhat different to CE? Are there any particular metrics FT uses?

Sabot rounds (as opposed to Railgun rounds) should be following standard CE calculation rules. Unless, I borked the spreadsheet calcs yet again...

@N7Huntsman
Copy link
Contributor

N7Huntsman commented Feb 20, 2020

@sumghai

Sabot rounds (as opposed to Railgun rounds) should be following standard CE calculation rules.

Fair enough. I plan to give the ammo types coming in a thorough review for balance this coming weekend anyway, my primary concern now is just making sure there aren't any issues/changes that need to be made significant enough to hold up bringing it it--which, at the moment, the only one I'm seeing is the tranq ammo.

Other than that, the only other thing I do want to see changed for the ammo is that on the FT spreadsheet, the Railgun Sabots currently do 100% Damage, and I'd like to see that changed to 70% to match the conventional Sabot ammo--sort of reflective of their comparatively poor terminal ballistics. It's a pretty small tweak, so whether you can do this on your end or I do it on mine makes no difference to me.

Copy link
Contributor

@N7Huntsman N7Huntsman left a comment

Choose a reason for hiding this comment

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

I have reviewed the .xml components and am generally comfortable with what I see.
Notes:

  • Added comments to the tranq ammo for tracking purposes.
  • Tranq ammo category should probably be moved from _Advanced to _General, since it's for conventional cartridges.
  • I noticed that that the generic Ballistic Knife blade was removed. I assume it's been moved to a patch instead?

Defs/Ammo/AmmoCategoryDefs/AmmoCategories_Advanced.xml Outdated Show resolved Hide resolved
Defs/Ammo/Pistols/9x19mmPara_NL.xml Outdated Show resolved Hide resolved
Defs/Ammo/Rifle/762x51mmNATO_NL.xml Outdated Show resolved Hide resolved
Robin Chang added 4 commits February 20, 2020 20:37
For CombatExtendedRWMod/issues/1006

Moved to general, since it is an ammo type for conventional rifle/pistol calibers
For CombatExtendedRWMod/issues/1006

Will later be re-implemented as a conditional patch for Metal Gear Solid mods; also moved ammo textures to ThirdParty subdirectory
@sumghai
Copy link
Contributor Author

sumghai commented Feb 20, 2020

@Alicecomma - please see 2d3daa1 and 0f5cd42 for the rocket/missile texture path and thingcategorydef fixes

(I have temporarily removed the tranq round defs, so that I can re-implement them as conditional patches within their respective mods)

@zozilin zozilin merged commit dbd81b8 into CombatExtendedRWMod:Development Feb 20, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants