I created a small expansion that makes this mod's functionality available in ECO, allowing for dynamic attachment of those penetration values to any weapon. This should somewhat reduce the need for patches for both vanilla and custom weapons.
Well now, that was a proper Charlie Foxtrot... tried to patch the PTRS-41 to use this framework and wound up breaking everything so badly I had to reinstall the rifle mod...
Hey Marrock, thank you for your feedback, endorsements, and support so far. I encourage you not to give up on modding. Just a couple weeks ago I didn't even have xEdit installed. You will find great help by carefully reading both the Description (particularly the Adding Penetration sections under Functionality Details) as well as the extensive documentation in the Articles.
Just this once, I will provide a very very detailed step-by-step using the records in the PTRS-41 mod as examples. It may look lengthy, but that is only because I have included every single step in excruciating detail, on the assumption that you are at a complete loss on how to use xEdit. I encourage you to watch some YouTube videos on how to use xEdit, but even if you don't, the following steps should help you.
I have stickied the post for others as the steps apply mutatis mutandis. Simply replace the names used as examples. Note that all FormIDs are presented with xx ("[PROJ:xx000A8C]") because the precise xx depends on where the particular mod lies on your particular load order.
Unfortunately, I have a lot of real-life matters to attend to, so I will instead teach you how to fish (which is also in keeping with the DIY purpose of this framework). I will use the specific example of the PTRS-41 mod, though I really think the documentation should be more than enough assistance.
Patching an Existing Mod
Firstly, as you had to reinstall the PTRS-41 mod, I am assuming that you attempted to directly modify the PTRS-41 records themselves. This is generally not recommended because it makes it difficult to keep track of your changes, which might be problematic if the original mod updates. Instead, make a separate patch:
Open the mjp_PTRS41ATR.esp in xEdit. Go to the Projectile records.
While holding CTRL, click every single Projectile record you see if the left panel. Then, right click and select "Copy as override into...", and swear that you are absolutely sure.
Click <new file> .esp, the one with the ESL flag (to make it an .esp flagged as ESL). Should be the 3rd new file option.
This will be your compatibility patch. Give it a good name such as "PTRS-41 Real Time Cover Penetration". It will appear at the very bottom of your load order in Bold.
Right click on your brand new patch and select Add Masters. Find "Penetration Framework.esp", check it, and click Ok.
You are now ready to penetrate. I will use only two Projectiles as examples. You can repeat the process accordingly (or maybe make a fancy xEdit script to do it automatically, I don't know how).
No Projectile Records?
Spoiler:
Show
If the mod adds new Ammunition records but does not add new Projectile records, this means that it uses Vanilla Projectiles (or those from another mod).
In this case, replace "Projectile" with "Ammunition" for the above steps 1-5. You will then also need to create a new Projectile.
Go to the Projectile records in "Penetration Framework.esp" and find "Template for adding new Initial Projectile [PROJ:xx000811]" (v0.4-Beta). Right click on this, but this time select "Copy as new record into..." and select your compat patch "PTRS-41 Real Time Cover Penetration.esp". It will prompt you to rename, so just give it something simple like "Projectile [Ammo Name]".
This process should be repeated for each different Ammunition type, unless you are satisfied with having different ammo share the same penetration properties.
Then, return to the Ammunition records in "PTRS-41 Real Time Cover Penetration.esp" (which you made in step 1).
Ensure that the Projectile fired (DNAM - DNAM > Projectile) by those Ammunition records are changed to your new Projectiles, "Projectile [Ammo Name]". If multiple new Projectiles were made, link each Ammunition record to its respective Projectile.
As the provided template initial Projectile applies the Explosion "Generic Penetration Effect [EXPL:xx000801]" by default, simply change this to the desired effect. Under DNAM - Data, go to "Explosion" and double click. Select the Penetration Effect you want from my framework. For example, say you want it to do 90 damage after penetration. Add "Penetration Effect 90 Damage "Penetration Effect: Add to Projectile as Explosion " [EXPL:xx000840]" from my Penetration Framework.
Done. That's literally it! The Ammunition will now penetrate cover and deal 90 damage (depending on global damage modifiers, etc.) to anyone behind cover. Happy penetrating.
Existing Projectile DOES NOT Apply Explosion
PTRS41_145mmProjectileN [PROJ:xx000A8C] This will be my example for how to patch an existing Projectile that does not already have an Explosion. All edits should be made to your new "PTRS-41 Real Time Cover Penetration.esp". This type of Projectile will be the easiest to patch:
First, check whether the Projectile meets the requirements listed in the Framework Documentation. As stated in the Description, the initial Projectile must be flagged as an Explosion and Tracer Frequency must be set to 1. Here, PTRS41_145mmProjectileN is not flagged as an Explosion and Tracer Frequency is set to 4, so we must correct that. Under DNAM - Data, double click on "Flags (sorted)" and select "Explosion". Further down, under Tracer Frequency, change it to 1. The right hand column (your compat patch) should now reflect a difference from the left hand column (the original mod). This is good.
Next, add the desired effect as an Explosion. Also under DNAM - Data, go to "Explosion" and double click. Select the Penetration Effect you want from my framework. For example, say you want it to do 90 damage after penetration. Add "Penetration Effect 90 Damage "Penetration Effect: Add to Projectile as Explosion " [EXPL:xx000840]" from my Penetration Framework.
Done. That's literally it! The PTRS41_145mmProjectileN will now penetrate cover and deal 90 damage (depending on global damage modifiers, etc.) to anyone behind cover. Happy penetrating.
Do the same for any of the other Projectiles that do not have an existing Explosion (i.e. the Projectile record Explosion entry should say NULL). Select a different Penetration Effect depending on how powerful you want the specific round to be.
For visual learners who want a practical example (above and beyond the templates provided), you can download and look at the way I made 50 BMG Cover Penetration?; 50 Cal Penetration Demonstration?; or 50 Cal Spalling Demonstration?. That was the intended purpose of providing demonstrations that show how to patch a Vanilla record (.50 cal).
Existing Projectile APPLIES Explosion
PTRS41_20mmAPDS_Projectile [PROJ:xx000B2D] This will be my example for how to patch an existing Projectile that has an Explosion. All edits should be made to your new "PTRS-41 Real Time Cover Penetration.esp". This type of Projectile will be teeny tiny slightly more involved to patch:
First, identify all Projectiles that have an existing explosion. Similar to the first case, make sure they are all flagged as an Explosion and Tracer Frequency is set to 1. We will now have to merge the Explosions.
Next, make an override record for the Explosions. To find the relevant Explosion, hold CTRL and click on the Explosion entry, which will take you to the existing Explosion record. In our case, this is "PTRS41_20mmAPFSDS_Explosion [EXPL:xx000B2E]" located in the "mjp_PTRS41ATR.esp". Right click on this entry in the left panel and select "Copy as override into...", but this time select your compat patch "PTRS-41 Real Time Cover Penetration.esp".
You must now make the override Explosion record adhere to the basic rules as stated in the Description and Documentation of this Framework. To make things easier, in the left panel, hold CTRL and click on both your override Explosion record and on the "Generic Penetration Effect [EXPL:xx000801]" in my "Penetration Framework.esp" (it should be the topmost Explosion record). Then, right click and select "Compare Selected (2)". This should place the data of both files side by side in the right panel (left column being the "Generic Penetration Effect", right column your override PTRS41_20mmAPFSDS_Explosion Explosion)
Now to merge (make the existing Explosion work as a Penetration Effect). Click anywhere and some colourful data should show up. You must make the override Explosion record adhere to the basic rules as stated in the Description and Documentation of this Framework. In our example, you need to add and copy over a few things. Under DATA - Data > Flags (sorted), check "Ignore LOS Check" (or simply drag all the flags from the left column over to the right column). Under DATA - Data > Spawn, make sure everything in the right column (your override PTRS41_20mmAPFSDS_Explosion Explosion) is identical to the left column (the "Generic Penetration Effect"). To spell it out, X = 0, Y = -1, Z = 0, Spread = 0, Count = 1.
You will need to make the a new Penetrator Projectile. Testing has shown that for some reason the Penetration Effect and Penetrator Projectile should be in the same plugin, I don't really know why. At any rate, decide how much damage you want the PTRS41_20mmAPDS_Projectile to do after penetration. I'm guessing pretty high because that's a rather spritely round. Let's assume you want it to do massive damage, say 150 after penetration. Go to Projectile records in my "Penetration Framework.esp" and look for "Penetrator Projectile 150 [PROJ:xx000832]". Right click on this entry in the left panel and select "Copy as new record into...", and select your compat patch "PTRS-41 Real Time Cover Penetration.esp". It will prompt you to rename, so just give it something simple like "PTRS41_20mmAPDS_Penetrator Projectile". It will now show up as an additional record in your "PTRS-41 Real Time Cover Penetration.esp".
Now link the merged Penetration Effect to the Penetrator Projectile. Go back to the record for your override Explosion that you made in step 2 (i.e. PTRS41_20mmAPFSDS_Explosion). Under DATA - Data > Spawn Projectile, double click and reference the penetrator "PTRS41_20mmAPDS_Penetrator Projectile" you created in step 5.
If you want the post-penetration projectile to retain the same on hit effects as the pre-penetration projectile, you will also need to make a new "Determines Damage" Explosion. Go to Explosion records in my "Penetration Framework.esp" and look for "150 Damage Penetrator "Determines Damage: " [EXPL:xx000823]". Right click on this entry in the left panel and select "Copy as new record into...", and select your compat patch "PTRS-41 Real Time Cover Penetration.esp". It will prompt you to rename, so just give it something simple like "PTRS41_20mmAPDS_150 Damage Penetrator". It will now show up as an additional record in your "PTRS-41 Real Time Cover Penetration.esp".
(For Step 7) Now to forward the effects from the impact Explosion to the ultimate hit Explosion (i.e. make your own "Determines Damage" Explosion). In the left panel, hold CTRL and click on (the override you made in step 2) "PTRS41_20mmAPFSDS_Explosion" and "PTRS41_20mmAPDS_150 Damage Penetrator". They should appear side by side in the right panel. Copy over (drag from left column to right column) the data in the; OBND - Object Bounds; Model (if any); EITM - Object Effect (if any); MNAM - Image Space Modifier; DATA - Light, Sound, Impact Data Set, Placed Object, Force, IS Radius, Flags (Sorted), Sound Level, Stagger (if any). DO NOT copy over the "Spawn Projectile" or the "Damage". Spawn Projectile should be a Null Reference, and "Damage" is how much damage you want the bullet to do after penetration.
(For Step 7) Now to link the new Determines Damage with your Penetrator Projectile. Go back to the record for your Penetrator Projectile that you made in step 5 (i.e. PTRS41_20mmAPDS_Penetrator Projectile). Instead of "150 Damage Penetrator "Determines Damage: " [EXPL:xx000823]", replace this with the "PTRS41_20mmAPDS_150 Damage Penetrator" you created in step 7.
DONE. Happy penetrating.
Do the same for any of the other Projectiles that already have an existing Explosion (i.e. the Projectile record Explosion entry should state the Explosion record you will need to create an override for). Select a different Penetrator Projectile to copy as new record depending on how powerful you want the specific round to be.
Alternatively, you can instead simply follow the above steps for the PTRS41_145mmProjectileN and just replace the existing explosion with one of my template Explosions, but this will result in loss of some of the original functionality from the ammo of the PTRS41 mod, in particular any splash damage from impacts.
For visual learners who want a practical example (above and beyond the templates provided), you can download and look at the way I made Gauss Rifle 2mm EC Cover Penetration?; or Combined Arms AKM High Penetration Ammo Plugin. The Vanilla Gauss rifle applies an explosion effect, which I merged with my Penetration Effects. The same goes for Combined Arm's AKM.
Congratulations If you have done any/either/both of the above to one or more of the Projectiles, you are officially a modder and no longer just a player. Congratulations. Release your work as a compatibility patch for everyone to enjoy (or keep it to yourself)!
Coincidentally, the round I used most is the one you used in your tutorial in this thread, but after several hours of trying I just couldn't get anything to work right.
It's a moot point anyway as now the only game I have on my computer is solitaire... I'm just going to take a break from the whole mess for a little while, probably only 10 or 12 months.
Step 5 "You will need to make the a new Penetrator Projectile. Testing has shown that for some reason the Penetration Effect and Penetrator Projectile should be in the same plugin, I don't really know why. At any rate, decide how much damage you want the PTRS41_20mmAPDS_Projectile to do after penetration. I'm guessing pretty high because that's a rather spritely round. Let's assume you want it to do massive damage, say 150 after penetration. Go to Projectile records in my "Penetration Framework.esp" and look for "Penetrator Projectile 150 [PROJ:xx000832]". Right click on this entry in the left panel and select "Copy as new record into...", and select your compat patch "PTRS-41 Real Time Cover Penetration.esp". It will prompt you to rename, so just give it something simple like "PTRS41_20mmAPDS_Penetrator Projectile". It will now show up as an additional record in your "PTRS-41 Real Time Cover Penetration.esp".
It did not prompt me to rename but just copy right into the new esp instead?
Step 9 "(For Step 7) Now to link the new Determines Damage with your Penetrator Projectile. Go back to the record for your Penetrator Projectile that you made in step 5 (i.e. PTRS41_20mmAPDS_Penetrator Projectile). Instead of "150 Damage Penetrator "Determines Damage: " [EXPL:xx000823]", replace this with the "PTRS41_20mmAPDS_150 Damage Penetrator" you created in step 7". How do I "replace"? I can't find any replace specific function by right clicking
Greetings riceball, thank you for your appreciation, it is appreciated.
For Step 5, you must "Copy as new record into..." rather than copy as override. If it did not prompt you to rename, you probably selected copy as override rather than as new record. Creating an override will make your edits to the Penetrator Projectile 150 affect everything else that relies upon Penetration Effect 150.
For Step 9, "replace" is not a specific xEdit function, I meant it as a verb. Simply copy into the "Explosion" section the FormID of your new Determines Damage entry, and put it in place of the existing Determines Damage Explosion.
Do let me know (in a separate comment to avoid increasing the length of this sticky) if you have additional questions. Additionally, I understand that there may be visually impaired users. To improve accessibility, kindly let me know if orange is not a suitable colour for emphasis, I apologize for my ignorance.
Orange color is totally noticeable as I later realized that I missed the word "Copy as new record into...". Apologies..and Step5,9 solved :)
However, I'm currently still trying to get it to work.
(For Step 7) Now to forward the effects from the impact Explosion to the ultimate hit Explosion (i.e. make your own "Determines Damage" Explosion). In the left panel, hold CTRL and click on (the override you made in step 2) "PTRS41_20mmAPFSDS_Explosion" and "PTRS41_20mmAPDS_150 Damage Penetrator". They should appear side by side in the right panel. Copy over (drag from left column to right column) the data in the; OBND - Object Bounds; Model (if any); EITM - Object Effect (if any); MNAM - Image Space Modifier; DATA - Light, Sound, Impact Data Set, Placed Object, Force, IS Radius, Flags (Sorted), Sound Level, Stagger (if any). DO NOT copy over the "Spawn Projectile" or the "Damage". Spawn Projectile should be a Null Reference, and "Damage" is how much damage you want the bullet to do after penetration.
Do I need to copy over the spawn"XYZ" value as well?
Extremely odd, everything looks correct. Could you tell me (1) what you are trying to penetrate for your testing; and (2) what modifications you have made to the AK? Sometimes OMODs apply a projectile override. Try penetrating with a naked AK.
1) I tried penetrating it on steel, wood and concrete 2) Tried it without OMOD, no luck as well 3) I tried the 9x39 plugin RTCP as well but oddly it doesn't work however the vanilla ammo .50cal penetration works
Now I'm doubting could it be the problem of the ammo type?
Hey riceball, thanks for working with me on this so far, I can confirm that there seems to be something up with the 9x39 plugin, which is indeed not functioning as intended. However, a quick plugin I created for the .458 Ammo from the MK18 works perfectly as intended (a plugin for the .50 AE from CA also works as intended). My current theory is that there might be something in the way the AS Val is set up in CA, which might be the same as AKM Complex (which you use). Oddly enough the High-Penetration Ammo plugin works as intended, and the .50 cal plugin works for the M82 from CA. I'll look deeper into this.
Update: Noticed that the "On Hit" for AS Val and AKM are set to "No dismember/explode" whereas M82 is set to "Explode only". However, changing this seems to have no impact. Update 2: I am fairly certain it is something to do with how the AS Val/AKM is set up, because changing the Weapon record to feed .50 cal results in no penetration with the .50 cal plugin. I have taken down the 9x39 plugin until I have time to delve into the CA files for the AS Val. Update 3: Converting the CA AKM to fire 9x39 rounds seems to work just fine.
Solved: Turns out Tracer Frequency is an essential variable. Must be set to 1. I have updated the framework and documentation accordingly.
9x39 Plugin was not functioning with the AS Val as the OMODs for the Barrels had an override Projectile that changed it to Vanilla AssaultRifleProjectileSuppressor. Should have checked this first but wasted hours like an idiot. Reuploaded the plugin.
Hey Man! It's my honor to work with someone that has a great courtesy as well and I'm glad that the issue is finally solved! :) (AKM on my side solved as well turns out it's OMOD barrel override and tracer frequency as well)
Apart from that, I just saw that a user on discord made a patch to your framework and he/she's been trying to reach you, it says it fixes the "Penetrate Everything Issue" by letting it properly penetrating only just thin sheets but not something like tree or concrete. Sent you a PM to the discord server, kindly check it out if you're interested! :D
Hey riceballl, thank you for bringing this to my attention. Looking at the link you sent, it appears to be less of a patch and more of a replacement that copies my collision layer. Although this is fine (he credited me!), I would have appreciated it if the author reached out to me directly.
However, the author might have accidentally mistaken the point of the framework. Their replacement version basically utilizes the existing/known workaround of directly setting the collision layer for the initial Projectile, along with its attendant problems
Spoiler:
Show
[See Background section: Some existing workarounds (directly setting collision layers for fired projectiles) were unsatisfactory due to the consequential lack of interaction between the projectile and the environment: the rounds pass clean through anything without leaving even a bullet decal. For example, see the High Penetration rounds for the AKM in NovaFinch's Combined Arms - Modern Weapon Pack, which initiated and inspired this entire project (Nova's mod is fantastic)].
This method was also mentioned in my documentation and the shortfalls of this method is precisely what my mod intends (or tries at least) to address. The replacement mod also does not prevent the bullet from passing through everything, after all they are using my collision layer. Additionally, the author's Explosion does not scale bullet damage by half but rather applies a 50 damage Explosion to every bullet, which is probably unintended. However, this is a really great idea that I have not been able to figure out (reducing damage automatically rather than manually), I would be happy to discuss with the author directly if they have any ideas!
You're much welcome man!:) And yes, yes please it would be a beautiful piece of work to see if you managed to get in touch with the author and evaluate this mod into something more automated and hopefully BIG! :D (Don't get me wrong, this is already a magnificent piece of work)
-Gonna start making some RTCP compatibility patch for different weapons XD
Aaron7491 has released a patch for Caliber Complex that applies penetration to all Caliber Complex ammo. You can use this as a springboard or as reference for your own balancing decisions.
No idea, I don't use Caliber Complex. Should be pretty easy to check in xEdit.
Edit: Both the CC-WB Patch and CC-RTCPF Patch will conflict, whichever loads last will win. Follow the stickied comment to merge the Explosions yourself in FO4Edit. The optional Demonstration file should work with the CC-WB Patch (do not enable the CC-RTCPF Patch), but (as stated in the description) I have not tested this file and if it works, only the Ammo that applies the explosions pertaining to .44, .45-70, .308, 5.56, 7.62, .50 Cal. Projectiles will have penetration (the CC-RTCPF Patch adds penetration to all ammo added by CC). Precisely which Projectiles will penetrate is easy to check in FO4Edit, just open up the Projectile records of the CC-WB Patch.
So, I made a comment about this some time ago, and its been that long since I"ve gotten to play. But apparently this mod does cause issues with power armor. I'm not going to list it with any kind of bug, but its worth mentioning.
To test what was going on, I used a variation of Damage Threshold Framework, where I modded the minimum damage to zero. Then set the T60 power armor to be immune to my test weapon (.50 machinegun).
When I am wearing the power armor and someone shoots me, no problems at all.
When I shoot Brotherhood Knights in that same power armor who should also be immune to its damage output, they die almost immediately. Tested this several times. It seems clear to me that with this mod installed, rounds that hit power armor create a penetration effect that passes through and hits the person inside the power armor. (Same thing happens with the penetrator perk, making it stupid easy to kill BOS by targeting their fusion core from the front.)
Now, even taking DTF out of the equation, this means that with this mod installed, projectile based attacks against anyone in power armor will be doing more damage than they should be. How much more being the amount for whatever penetrator effect has been assigned.
For reference, I did test again without DTF, using the information on Fallout's DR formula, and even then, when I shot someone in T60 with the test weapon, they were taking more damage than they should. (Again the amount of excess damage being equal to the penetrator effect.)
This isn't a complaint, just an advisory, that this does have a direct effect on damage dealt to power armor NPC's, though apparently not to the player. If the mod author feels I may have gotten something wrong, by all means let me know. If someone else has brought this up before, and I missed it, my bad.
This mod turns power armor into a liability for NPC's, since they take damage twice from every bullet. The first time when they are hit when they take full damage minus DR, and a second time when they take the penetrator with no DR.
Try a power armor mod like Bastion, it will prevent NPCs from taking damage while their armor is intact. Also, there's a game setting which multiplies damage to NPCs in power armor. Disabling it makes the power armored NPCs as tanky as the player, and I think you could even set it to .5 so they take only half as much damage (or it multiplies out to the normal amount if you're using this mod).
I don't think that's going to accomplish anything, since the penetrator projectile is never going to interact with the power armor. If this were a valid solution, turning the minimum damage down to 0 with DTF should have solved the problem. It didn't. Even if Bastion were to work in this case, that's really just a band-aid solution that is requiring mod-stacking in order to address an issue with this mod.
Due to the need to turn on the explosion flag, does that mean I can't turn off the decapitation and gore explosion? For some odd reason, the gore gets activated with weapons that have the gore turned off in xedit, so I'm not sure if its got something to do with the projectile explosion flag.
I've noticed this too. I've got dismemberment set up by weapon's ammo type but even the weapons using 38 and 10mm which are set to 'no dismember/explode' are still removing heads and limbs. So it would seem explosions completely ignore those flags.
I HAVE noticed in xEdit some fields in body part data for Explode Chance for a given limb but I'm not sure if it'll be of any use to reining the part explosion/sever back in. Torso for example has an explode chance of 100 but you need to have the Bloody Mess effect from perk or another source to even see the torso blow up, ever, so I'm not sure if those values are ever relevant to normal gameplay,
Explosions will by default dismember/explode. You can avoid this by setting a source weapon in the Explosion entry, and setting it to a weapon that does not dismember/explode.
Hello, is compatibility with Wasteland Ballistics planned ? The mod edits the explosion entry in the projectiles records as well, so I have no idea how to fix it myself :(
If you look at the optional files, you'll see a reference mod for patching Wasteland Ballistics specifically. Do note that (as mentioned elsewhere) there is a non-zero risk that projectiles may spawn at your feet when shooting at dirt in certain areas of the map.
Self-harm from projectiles seem to be caused solely by having the Alt. Trigger flag ticked on ANY projectile that is made to spawn the projectiles from this framework. I found this out when trying to patch Burst Impact FX for it, and after testing it for a bit over 10 hours of play the issue seems to go away entirely when that flag is disabled.
EDIT: If you think about it, it makes sense, Alt Trigger basically seems to give the explosion tied to the projectile a time delay fuse, and if you had the params for Alt Trigger at 0, the bullet blows up instantly, sending out the penetrator, and its damage projectile instantly, probably while it's still in your character collision. And explosions ignore the fact you can't harm yourself with your own projectiles (easy to test in VR, you can't shoot yourself in the head, no it totally wasn't the first thing I tried to do as soon as I got the 10mm in the vault).
EDIT 2: It seems this is NOT the case for Wasteland Ballistics now that I actually got around to testing it. Shoot at feet, any material = self-harm. You sometimes also get completely random ricochets back into your face when shooting things far away. Firing a weapon that does full auto or just firing a weapon too fast will also dump rounds back into your face. (character dropping dead as soon as minigun with JSRS M134 sound went BRRRRRRRRRT was some choice comedic timing, just about perfectly reflected how I felt having my eardrums assaulted at the moment) Something about the way WB delivers its bleed effects to player/NPCs does not like the way this mod does its thing. And so far, the lack of an enchantment or placed object on the penetration effect/oenetrator damage is the only difference between my own Burst Impact penetration patch and what's currently in my conflict resolution patch where I set WB explodes/projectiles up for penetration. Very frustrating, might actually necessitate dropping WB out of the load order assuming there's no solution to stop bouncing rounds into my face.
Hey TehDave, did you find a way to stop the "bouncing rounds?"
Also, your post is a little unclear - are the rounds physically coming back, or is the issue just the effects being incorrectly applied to the player/NPCs when they shouldn't be?
I did figure it out, the issue really is having the penetrator projectile as a missile. Beam to Beam and Missile to Beam is fine, Missile to Missile will cause player face-seeking bullets. You can still hurt yourself firing at the ground right at your feet but let's be honest, you would hurt yourself/risk a ricochet into your feet/legs doing that in reality so why would you do it in game?
And the issue has only a slight relation to the effects, for whatever reason setting the penetrator as a missile causes the damage explosion tied to it to go off at your feet. This can also happen by shooting into the distance randomly which makes no sense whatsoever.
This can be solved by removing L_ground from the collision layer provided by this mod. It seems the issue is caused by the engine detecting an object underneath the ground which should have collided with the ground and for some reason teleporting it to the player's feet. My guess is it has to do with the script that teleports the player up to the terrain if the player ever falls through the earth and into the "void."
I've put in a few dozen hours trying to figure out how to make projectiles not penetrate thick cover after observing them going straight through brick buildings a few times. I've made some progress.
A non-hitscan penetrator projectile can be given a short lifetime so that it detonates very soon after spawning. Since the speed and lifetime can be set, we can use the two to set a maximum distance the projectile can fly before detonating. So, a weaker caliber like 5.56x45mm can be set to detonate after 6 inches and thus go through plywood and sheet metal but not through a brick wall, while a stronger caliber like .50 BMG can be set to detonate after 24 inches and go through walls.
I ran into the issue of non-hitscan projectiles for some reason spawning at my feet and hitting me, particularly when shooting at the ground several or more feet away. As far as I could tell, the projectile was being detected underground by the game engine and transported to the player's horizontal coordinates and the ground's vertical coordinates at those horizontal coordinates - if you've ever fallen through the ground in this game you'll know the game engine repositions the character back to the ground layer to compensate, as a sort of fail-safe to avoid the player being stuck falling into the void... I think the same process is what repositions the projectiles. I found that a workaround is to disable L_Ground collision from your collision layer. Without this, projectiles no longer "bounce back." This collision is in fact no longer needed with the time/distance detonation I described above, since the projectile will detonate before traveling any real distance under the ground.
The last issue I have left to solve is how to get the third projectile (pre-penetration projectile -> collisionless penetration projectile -> post-penetration projectile) to line up with the second projectile. Right now, since the second projectile's explosion is time and not impact based, the third projectile is being spawned facing a random direction.
If I figure this out, I will publish a mod using your framework for vanilla and Munitions ammo types.
Update: I don't think this is possible without the use of scripts or F4SE. A time-activated detonation (as opposed to an impact detonation) has an almost completely random orientation; I can't get the projectiles spawned to have the same vector as the previous projectile. I even tried using the unknown flags for projectiles and explosives.
While I have the skills to delve into F4SE, I likely won't ever have time. :-(
I did try out (years ago now) your suggested method of using a time delay to get around the over-penetration issue, I must have failed to include that in the documentation. Good creative thinking! However, the problem with that solution is; first, inconsistent results (which I believe you have experienced), and second (and more importantly), severe limitations to this method where the cover to be penetrated is close to the player character. For example, where the obstructing object (say, a fence) is close to the shooter, this method means that the penetration only works immediately behind the fence and does not hit faraway enemies. Given that players are regularly behind cover, the annoyance this caused led me to stick to the current method.
Interesting workaround with the discovery of the L_Ground layer! If you (or another party) can confirm that that fixes the "rebounding" glitch, I might push an update. I am, however, curious if this means that players will be able to shoot through the floor of buildings?
very nice mod, but there are too many drawbacks if not outright bugs, 1. the bullet holes dont appear on the objects since the bullet passes through also there is not hit effect or anything, so its like you didnt shoot anything in the fuirst place. 2. this is somewhat important, namely you cant set off explosive objects like fuel tanks or pressurized containers which really sucks. only issues i ve met so far, a patch for those would be nice but im a noob so
For many weapons, when I chose a penetration mod (like idk, 20 damage, 30 damage, whatever) it reduces the damage of the whole weapon?
And if the weapon has different damage types (like ballistic damage + plasma damage) it often removes on of the damage types and the weapon just ends up with ballistic damage (reduced again)
172 comments
Real Time Cover Penetration Framework - ECO
The version for old ECO is part of old ECO's installer package.
Modding just isn't for me, I give up.
Just this once, I will provide a very very detailed step-by-step using the records in the PTRS-41 mod as examples. It may look lengthy, but that is only because I have included every single step in excruciating detail, on the assumption that you are at a complete loss on how to use xEdit. I encourage you to watch some YouTube videos on how to use xEdit, but even if you don't, the following steps should help you.
I have stickied the post for others as the steps apply mutatis mutandis. Simply replace the names used as examples. Note that all FormIDs are presented with xx ("[PROJ:xx000A8C]") because the precise xx depends on where the particular mod lies on your particular load order.
Firstly, as you had to reinstall the PTRS-41 mod, I am assuming that you attempted to directly modify the PTRS-41 records themselves. This is generally not recommended because it makes it difficult to keep track of your changes, which might be problematic if the original mod updates. Instead, make a separate patch:
You are now ready to penetrate. I will use only two Projectiles as examples. You can repeat the process accordingly (or maybe make a fancy xEdit script to do it automatically, I don't know how).
If the mod adds new Ammunition records but does not add new Projectile records, this means that it uses Vanilla Projectiles (or those from another mod).
PTRS41_145mmProjectileN [PROJ:xx000A8C]
This will be my example for how to patch an existing Projectile that does not already have an Explosion. All edits should be made to your new "PTRS-41 Real Time Cover Penetration.esp". This type of Projectile will be the easiest to patch:
- First, check whether the Projectile meets the requirements listed in the Framework Documentation. As stated in the Description, the initial Projectile must be flagged as an Explosion and Tracer Frequency must be set to 1. Here, PTRS41_145mmProjectileN is not flagged as an Explosion and Tracer Frequency is set to 4, so we must correct that. Under DNAM - Data, double click on "Flags (sorted)" and select "Explosion". Further down, under Tracer Frequency, change it to 1. The right hand column (your compat patch) should now reflect a difference from the left hand column (the original mod). This is good.
- Next, add the desired effect as an Explosion. Also under DNAM - Data, go to "Explosion" and double click. Select the Penetration Effect you want from my framework. For example, say you want it to do 90 damage after penetration. Add "Penetration Effect 90 Damage "Penetration Effect: Add to Projectile as Explosion " [EXPL:xx000840]" from my Penetration Framework.
- Done. That's literally it! The PTRS41_145mmProjectileN will now penetrate cover and deal 90 damage (depending on global damage modifiers, etc.) to anyone behind cover. Happy penetrating.
- Do the same for any of the other Projectiles that do not have an existing Explosion (i.e. the Projectile record Explosion entry should say NULL). Select a different Penetration Effect depending on how powerful you want the specific round to be.
For visual learners who want a practical example (above and beyond the templates provided), you can download and look at the way I made 50 BMG Cover Penetration?; 50 Cal Penetration Demonstration?; or 50 Cal Spalling Demonstration?. That was the intended purpose of providing demonstrations that show how to patch a Vanilla record (.50 cal).PTRS41_20mmAPDS_Projectile [PROJ:xx000B2D]
This will be my example for how to patch an existing Projectile that has an Explosion. All edits should be made to your new "PTRS-41 Real Time Cover Penetration.esp". This type of Projectile will be teeny tiny slightly more involved to patch:
Alternatively, you can instead simply follow the above steps for the PTRS41_145mmProjectileN and just replace the existing explosion with one of my template Explosions, but this will result in loss of some of the original functionality from the ammo of the PTRS41 mod, in particular any splash damage from impacts.
For visual learners who want a practical example (above and beyond the templates provided), you can download and look at the way I made Gauss Rifle 2mm EC Cover Penetration?; or Combined Arms AKM High Penetration Ammo Plugin. The Vanilla Gauss rifle applies an explosion effect, which I merged with my Penetration Effects. The same goes for Combined Arm's AKM.
Congratulations
If you have done any/either/both of the above to one or more of the Projectiles, you are officially a modder and no longer just a player. Congratulations. Release your work as a compatibility patch for everyone to enjoy (or keep it to yourself)!
My skull currently feels like it's explodng in slow-motion so probably not the best time to try fiddling with mods.
ETA: Yeah... nevermind, thanks anyway... apparently I just too damn stupid or this sort of thing.
Gonna go uninstall the game now.
See you around sometime.
It's a moot point anyway as now the only game I have on my computer is solitaire... I'm just going to take a break from the whole mess for a little while, probably only 10 or 12 months.
I'm using FO4edit and by following
Step 5
"You will need to make the a new Penetrator Projectile. Testing has shown that for some reason the Penetration Effect and Penetrator Projectile should be in the same plugin, I don't really know why. At any rate, decide how much damage you want the PTRS41_20mmAPDS_Projectile to do after penetration. I'm guessing pretty high because that's a rather spritely round. Let's assume you want it to do massive damage, say 150 after penetration. Go to Projectile records in my "Penetration Framework.esp" and look for "Penetrator Projectile 150 [PROJ:xx000832]". Right click on this entry in the left panel and select "Copy as new record into...", and select your compat patch "PTRS-41 Real Time Cover Penetration.esp". It will prompt you to rename, so just give it something simple like "PTRS41_20mmAPDS_Penetrator Projectile". It will now show up as an additional record in your "PTRS-41 Real Time Cover Penetration.esp".
It did not prompt me to rename but just copy right into the new esp instead?
Step 9
"(For Step 7) Now to link the new Determines Damage with your Penetrator Projectile. Go back to the record for your Penetrator Projectile that you made in step 5 (i.e. PTRS41_20mmAPDS_Penetrator Projectile). Instead of "150 Damage Penetrator "Determines Damage: " [EXPL:xx000823]", replace this with the "PTRS41_20mmAPDS_150 Damage Penetrator" you created in step 7".
How do I "replace"? I can't find any replace specific function by right clicking
Lastly Thanks for the detailed tutorial! :D
For Step 5, you must "Copy as new record into..." rather than copy as override. If it did not prompt you to rename, you probably selected copy as override rather than as new record. Creating an override will make your edits to the Penetrator Projectile 150 affect everything else that relies upon Penetration Effect 150.
For Step 9, "replace" is not a specific xEdit function, I meant it as a verb. Simply copy into the "Explosion" section the FormID of your new Determines Damage entry, and put it in place of the existing Determines Damage Explosion.
Do let me know (in a separate comment to avoid increasing the length of this sticky) if you have additional questions. Additionally, I understand that there may be visually impaired users. To improve accessibility, kindly let me know if orange is not a suitable colour for emphasis, I apologize for my ignorance.
However, I'm currently still trying to get it to work.
(For Step 7) Now to forward the effects from the impact Explosion to the ultimate hit Explosion (i.e. make your own "Determines Damage" Explosion). In the left panel, hold CTRL and click on (the override you made in step 2) "PTRS41_20mmAPFSDS_Explosion" and "PTRS41_20mmAPDS_150 Damage Penetrator". They should appear side by side in the right panel. Copy over (drag from left column to right column) the data in the; OBND - Object Bounds; Model (if any); EITM - Object Effect (if any); MNAM - Image Space Modifier; DATA - Light, Sound, Impact Data Set, Placed Object, Force, IS Radius, Flags (Sorted), Sound Level, Stagger (if any). DO NOT copy over the "Spawn Projectile" or the "Damage". Spawn Projectile should be a Null Reference, and "Damage" is how much damage you want the bullet to do after penetration.
Do I need to copy over the spawn"XYZ" value as well?
I think I got everything right but mods doesn't looks like working to me, could you help me take a look at it? Thank you! :)
2) Tried it without OMOD, no luck as well
3) I tried the 9x39 plugin RTCP as well but oddly it doesn't work however the vanilla ammo .50cal penetration works
Now I'm doubting could it be the problem of the ammo type?
Update: Noticed that the "On Hit" for AS Val and AKM are set to "No dismember/explode" whereas M82 is set to "Explode only". However, changing this seems to have no impact. Update 2: I am fairly certain it is something to do with how the AS Val/AKM is set up, because changing the Weapon record to feed .50 cal results in no penetration with the .50 cal plugin. I have taken down the 9x39 plugin until I have time to delve into the CA files for the AS Val. Update 3: Converting the CA AKM to fire 9x39 rounds seems to work just fine.
9x39 Plugin was not functioning with the AS Val as the OMODs for the Barrels had an override Projectile that changed it to Vanilla AssaultRifleProjectileSuppressor. Should have checked this first but wasted hours like an idiot. Reuploaded the plugin.
(AKM on my side solved as well turns out it's OMOD barrel override and tracer frequency as well)
Apart from that, I just saw that a user on discord made a patch to your framework and he/she's been trying to reach you, it says it fixes the "Penetrate Everything Issue" by letting it properly penetrating only just thin sheets but not something like tree or concrete. Sent you a PM to the discord server, kindly check it out if you're interested! :D
However, the author might have accidentally mistaken the point of the framework. Their replacement version basically utilizes the existing/known workaround of directly setting the collision layer for the initial Projectile, along with its attendant problems
This method was also mentioned in my documentation and the shortfalls of this method is precisely what my mod intends (or tries at least) to address. The replacement mod also does not prevent the bullet from passing through everything, after all they are using my collision layer. Additionally, the author's Explosion does not scale bullet damage by half but rather applies a 50 damage Explosion to every bullet, which is probably unintended. However, this is a really great idea that I have not been able to figure out (reducing damage automatically rather than manually), I would be happy to discuss with the author directly if they have any ideas!
And yes, yes please it would be a beautiful piece of work to see if you managed to get in touch with the author and evaluate this mod into something more automated and hopefully BIG! :D (Don't get me wrong, this is already a magnificent piece of work)
-Gonna start making some RTCP compatibility patch for different weapons XD
Edit: Both the CC-WB Patch and CC-RTCPF Patch will conflict, whichever loads last will win. Follow the stickied comment to merge the Explosions yourself in FO4Edit. The optional Demonstration file should work with the CC-WB Patch (do not enable the CC-RTCPF Patch), but (as stated in the description) I have not tested this file and if it works, only the Ammo that applies the explosions pertaining to .44, .45-70, .308, 5.56, 7.62, .50 Cal. Projectiles will have penetration (the CC-RTCPF Patch adds penetration to all ammo added by CC). Precisely which Projectiles will penetrate is easy to check in FO4Edit, just open up the Projectile records of the CC-WB Patch.
To test what was going on, I used a variation of Damage Threshold Framework, where I modded the minimum damage to zero.
Then set the T60 power armor to be immune to my test weapon (.50 machinegun).
When I am wearing the power armor and someone shoots me, no problems at all.
When I shoot Brotherhood Knights in that same power armor who should also be immune to its damage output, they die almost immediately.
Tested this several times. It seems clear to me that with this mod installed, rounds that hit power armor create a penetration effect that passes through and hits the person inside the power armor. (Same thing happens with the penetrator perk, making it stupid easy to kill BOS by targeting their fusion core from the front.)
Now, even taking DTF out of the equation, this means that with this mod installed, projectile based attacks against anyone in power armor will be doing more damage than they should be. How much more being the amount for whatever penetrator effect has been assigned.
For reference, I did test again without DTF, using the information on Fallout's DR formula, and even then, when I shot someone in T60 with the test weapon, they were taking more damage than they should. (Again the amount of excess damage being equal to the penetrator effect.)
This isn't a complaint, just an advisory, that this does have a direct effect on damage dealt to power armor NPC's, though apparently not to the player. If the mod author feels I may have gotten something wrong, by all means let me know. If someone else has brought this up before, and I missed it, my bad.
This mod turns power armor into a liability for NPC's, since they take damage twice from every bullet. The first time when they are hit when they take full damage minus DR, and a second time when they take the penetrator with no DR.
Even if Bastion were to work in this case, that's really just a band-aid solution that is requiring mod-stacking in order to address an issue with this mod.
EDIT: If you think about it, it makes sense, Alt Trigger basically seems to give the explosion tied to the projectile a time delay fuse, and if you had the params for Alt Trigger at 0, the bullet blows up instantly, sending out the penetrator, and its damage projectile instantly, probably while it's still in your character collision. And explosions ignore the fact you can't harm yourself with your own projectiles (easy to test in VR, you can't shoot yourself in the head, no it totally wasn't the first thing I tried to do as soon as I got the 10mm in the vault).
EDIT 2: It seems this is NOT the case for Wasteland Ballistics now that I actually got around to testing it. Shoot at feet, any material = self-harm. You sometimes also get completely random ricochets back into your face when shooting things far away. Firing a weapon that does full auto or just firing a weapon too fast will also dump rounds back into your face. (character dropping dead as soon as minigun with JSRS M134 sound went BRRRRRRRRRT was some choice comedic timing, just about perfectly reflected how I felt having my eardrums assaulted at the moment)
Something about the way WB delivers its bleed effects to player/NPCs does not like the way this mod does its thing. And so far, the lack of an enchantment or placed object on the penetration effect/oenetrator damage is the only difference between my own Burst Impact penetration patch and what's currently in my conflict resolution patch where I set WB explodes/projectiles up for penetration. Very frustrating, might actually necessitate dropping WB out of the load order assuming there's no solution to stop bouncing rounds into my face.
Also, your post is a little unclear - are the rounds physically coming back, or is the issue just the effects being incorrectly applied to the player/NPCs when they shouldn't be?
You can still hurt yourself firing at the ground right at your feet but let's be honest, you would hurt yourself/risk a ricochet into your feet/legs doing that in reality so why would you do it in game?
And the issue has only a slight relation to the effects, for whatever reason setting the penetrator as a missile causes the damage explosion tied to it to go off at your feet. This can also happen by shooting into the distance randomly which makes no sense whatsoever.
A non-hitscan penetrator projectile can be given a short lifetime so that it detonates very soon after spawning. Since the speed and lifetime can be set, we can use the two to set a maximum distance the projectile can fly before detonating. So, a weaker caliber like 5.56x45mm can be set to detonate after 6 inches and thus go through plywood and sheet metal but not through a brick wall, while a stronger caliber like .50 BMG can be set to detonate after 24 inches and go through walls.
I ran into the issue of non-hitscan projectiles for some reason spawning at my feet and hitting me, particularly when shooting at the ground several or more feet away. As far as I could tell, the projectile was being detected underground by the game engine and transported to the player's horizontal coordinates and the ground's vertical coordinates at those horizontal coordinates - if you've ever fallen through the ground in this game you'll know the game engine repositions the character back to the ground layer to compensate, as a sort of fail-safe to avoid the player being stuck falling into the void... I think the same process is what repositions the projectiles. I found that a workaround is to disable L_Ground collision from your collision layer. Without this, projectiles no longer "bounce back." This collision is in fact no longer needed with the time/distance detonation I described above, since the projectile will detonate before traveling any real distance under the ground.
The last issue I have left to solve is how to get the third projectile (pre-penetration projectile -> collisionless penetration projectile -> post-penetration projectile) to line up with the second projectile. Right now, since the second projectile's explosion is time and not impact based, the third projectile is being spawned facing a random direction.
If I figure this out, I will publish a mod using your framework for vanilla and Munitions ammo types.
While I have the skills to delve into F4SE, I likely won't ever have time. :-(
I did try out (years ago now) your suggested method of using a time delay to get around the over-penetration issue, I must have failed to include that in the documentation. Good creative thinking! However, the problem with that solution is; first, inconsistent results (which I believe you have experienced), and second (and more importantly), severe limitations to this method where the cover to be penetrated is close to the player character. For example, where the obstructing object (say, a fence) is close to the shooter, this method means that the penetration only works immediately behind the fence and does not hit faraway enemies. Given that players are regularly behind cover, the annoyance this caused led me to stick to the current method.
Interesting workaround with the discovery of the L_Ground layer! If you (or another party) can confirm that that fixes the "rebounding" glitch, I might push an update. I am, however, curious if this means that players will be able to shoot through the floor of buildings?
1. the bullet holes dont appear on the objects since the bullet passes through also there is not hit effect or anything, so its like you didnt shoot anything in the fuirst place.
2. this is somewhat important, namely you cant set off explosive objects like fuel tanks or pressurized containers which really sucks.
only issues i ve met so far, a patch for those would be nice but im a noob so
For many weapons, when I chose a penetration mod (like idk, 20 damage, 30 damage, whatever) it reduces the damage of the whole weapon?
And if the weapon has different damage types (like ballistic damage + plasma damage) it often removes on of the damage types and the weapon just ends up with ballistic damage (reduced again)
Is that normal or am I doing something wrong?