fitfondue
Members-
Posts
74 -
Joined
-
Last visited
-
Days Won
6
Content Type
Profiles
Forums
Gallery
Downloads
News Articles
Modding Wiki
RDR2 Native Database
RDR2 Native Parameters
RDR2 Player Clothes Database
RDR2 Ped Voices Database
RDR2 Ped Speech Lines
RDR2 Modding Tutorials
RDR2 Ped Model Database
RDR2 Animations Database
RDRFR Changelog
RDRFR Installation Guide
RDRFR Features
RDRFR Settings
LML User Contributions
Everything posted by fitfondue
-
@HughJanusJust gave it a quick test and yep, we've got a workaround! All the code you added is functioning properly, including IgnoreUpVector. By using these values... DyingPushChance=500 DyingForcePushX=20 DyingForcePushY=0 DyingForcePushZ=0 UseAdvancedDyingPush=0 ... enemies who go into the anti-stagger behaviour will now wander around before falling, so they no longer come to a stop. They walk around dazed, then fall, sometimes into scenery. It looks far better, but in order to really test it, could you add non-relative x y and z options? I might be more successful at finding the right values that way, particularly for things that require a push in one consistent direction. Incidentally, I tested different bones with different forces, and it's really really good that you added a bone-specific option. It does lead to different results and is worth testing. For now the center of mass force push yields better results than bone-specific, but I'll have to test further. One thing I learned from this is that the anti-stagger behaviour is REALLY persistent even at high forces. But the code you added improves it immensely. A force push of 15-20 makes a difference while NPCs are in the anti-stagger behaviour, but not so much when they're on any other behaviour, so there isn't much conflict with the mod's other functions. I'll provide more detailed feedback tomorrow! EDIT: NPCs don't roll around on the ground just yet, but that's probably because the force push vector is relative. A non-relative force push in one consistent direction may help with this.
-
-
-
@Jim Jam Banana SlamThe Cattleman with regular ammo most definitely should not be killing that fast on the realistic setting. I just tried it on my game and it takes three shots for the damn thing to deplete more than 30 health. Is this the only mod you're using? Did you tinker with anything in the game? As for the mod working with the story playthrough, that's awesome. Please let us know if any bugs come up. And hey, can't have enough Micah stumbling around in the mud like the asshole that he is.
-
@HughJanusThank you so much! That's very kind of you. I'm glad to be of help. By the way, what you said about the StumbleChance may be something that could be done to differentiate one leg being shot and two legs being shot. If both legs are shot, just increase StumbleChance to a fall-every-two-steps value. Until then, NPCs would stumble more rarely. I think that would work, if we can't find a more sophisticated behaviour for it. Before I get to my suggestions for 1.3, let me address @Jim Jam Banana Slam's point: in my testing, shotguns straight-up kill at close range (as in, you see a red crosshair), revolvers usually require two shots to the torso to down an enemy into the dying state (not killing them at first) and rifles may take just one shot to do the same. I found that to be more believable than vanilla settings, but if you're seeing a red crosshair at the first shot (as in, enemies are outright dying right away) please let us know. That would not be the intended design. SUGGESTIONS FOR 1.3: - Aggressive enemies always have that "shocked" reaction when they enter the knockback/dying state, and it takes a couple of seconds for them to fall. You tried to work around this by using a force push but you said it didn't look right. However, a weak but constant force push lasting two seconds would probably look right. Enemies in the "shocked" state are very susceptible to physical forces, with the exception of bullet impacts. A weak but constant force push backwards may lead to interesting reactions, and it shouldn't affect passive NPCs because they don't have the anti-stagger behaviour. They would still be affected by the force push but it would probably be too weak to change their ragdoll behaviour significantly. It's worth a try, at least until the anti-stagger behaviour can be isolated and removed completely. - Same force push method for downed enemies, to see if it makes them roll around on the ground realistically. This is in case no other ragdoll behaviours can be found and triggered instead. - StumbleChance increased to 80 or higher for enemies shot in both legs. - If the on fire behaviour can be triggered without the fire, I'd suggest adding it as a possibility for when an enemy is shot in both legs. - If the artery shot ragdoll behaviour can be triggered without the bleeding / health loss, I'd suggest making it happen more often, because it's a very good ragdoll behaviour. Who knows, it might even override the anti-stagger behaviour. - If the "wriggle oneself out from under horse" ragdoll behaviour can be triggered without the horse, I'd suggest testing it to see if it can be used as a "crawling away from battle" behaviour. - If the "dismemberment" behaviour can be isolated and customized, then I'd suggest making it last considerably longer (just like you did for the on-fire behaviour), and applying the ragdoll behaviour to non-dismemberment wounds to the arm and the leg. - Occasional arterial bleeding from headshots. Without the ragdoll behaviour, just the bleeding. - Making it possible to disarm lawmen, at which point they lose heart and run away like any other NPC. A workaround for this would be to make them flee if they're shot in the right arm, regardless of whether or not they still have a gun on their hand, since they can't shoot with a wounded arm. - Making NPCs wake up MUCH sooner after they're knocked out by melee damage. I have no idea how viable any of that is 😄 And this is your mod, you're the one doing the hard work of coding it, so ignore whatever you feel doesn't fit its scope or doesn't interest you.
-
@HughJanusTested 1.2 at default values. I am very glad to report that you've got a stable and (as far as I could tell) bug-free release candidate. I haven't tested it on missions due to a lack of time today, but that's gonna be a considerable undertaking, considering that Rockstar does all sorts of fuckery with the code in missions which may explain @ThanksHJ's problem above. So my feedback on free roam gameplay: - Bleed out is so subtle that it seems to not be working, but it IS working (I found that out by tweaking the values later). What matters is, it's working. If you're going for a really long bleed-out time, then you got it. - Arterial bleeding magnifies the bleed-out! Did you code that? 'Cause it does. Enemies who are bleeding from an artery will bleed out faster, often going beneath the DyingThreshold in the middle of the whole "get up, run, fall over, languish on ground" routine and may become incapacitated at different stages of the process. Sometimes an enemy will become incapacitated right after the artery shot (because the code by chance made them lose a lot of blood right away and put them under the DyingThreshold), some will ragdoll mid-run and some will get as far as languishing. It does add quite a bit of variety, because it keeps them from always reacting the exact same way. And fortunately, turning off BleedWhenDying does NOT make arterial bleeding stop dealing incremental damage. It still deals damage, so enemies do die from it regardless of whether or not BleedWhenDying is active. - Stumbling works, but it's prone to glitches if StumbleChance is set higher than your default value. This is because the RunningThreshold of 26 is still a bit low and affects NPCs who are moving slowly as they shoot at you. Their momentum isn't enough to tip them over so they'll just kind of glitch out without ragdolling, and StumbleChance magnifies that. I stand by the values I proposed previously: 30 for RunningThreshold, 80 for StumbleChance. It doesn't affect NPCs who are moving slow but does very quickly affect NPCs who break into a run. So it scales better, because this way, if the player wishes to increase StumbleChance, they won't be met with glitches. - The shotgun's effective range is still a bit too fearsome. Dialing it down to 2 or 3 may be ideal. So: after testing, I've tinkered with the .ini and come up with a "Realism" version, should you wish to make that available alongside your values. What this version does is: - Turns off invincibility by default. - Lowers NPC health to 70, which may seem too low, but they can still take something like four high-velocity shots to the torso without dying. - SpecialWeaponModifier is set to 1 because, at a lower health level, there's no reason to change it. Lower health also keeps fall damage as lethal as it is in vanilla. A health of 450 will make NPCs too resilient to high falls. - Sets KnockbackThreshold to 70 to fit the new health value, but maintains KnockbackChance at 11. It works really well so I kept it unchanged. - Sets DyingThreshold to 40. It takes two revolver shots OR 1 rifle shot to the chest to down an NPC permanently. Surprisingly, arterial bleeding scales properly and isn't brief, so that remains believable as well. - Changes BleedingChanceDying to 5 and BleedingValue to 1, in order to scale the bleeding time to a lower health level. The average time I saw in a few tests was something like two minutes, but it varies, and arterial bleeding is also magnified accordingly. - Sets StumbleChance to 80 and RunningThreshold to 30, making it impossible for NPCs to run, but avoiding the glitches caused by slower movement. - Melee, as far as I can tell, is not affected by any of this. NPCs can still take a lot of punches. - Increases FireHealth to 165 (I think that was the previous value) because 125 is a tad too fast, I think. Survival rate is unchanged. I've attached the .ini file below. Feel free to add it to the 1.2 release as an option for people who don't like the higher health. 🙂 Tomorrow I'll write more detailed suggestions for 1.3 features. On this test run I realized there is a ragdoll behaviour for when an NPC gets stuck beneath a dead horse. They try to wriggle themselves free of it, sometimes succeeding, sometimes failing. That behaviour may turn out to be useful. PedDamageOverhaul.ini
-
@HughJanusI'll make sure to test the default values you set for the .ini! Only after testing all the features as you've configured them will I start tinkering around. As for the 1.3 list you've proposed: - "chance of surviving bleedout (so not everyone will bleed out eventually)" - Thing is, NPCs only go into the dying state (in which they bleed out) once they've been shot many times, and at that point it makes sense for bleedout to be inevitable unless they receive medical treatment. Even the arm and the leg have arteries that if shot will cause you to die from blood loss in a minute. So this feature would actually be less realistic and might add unnecessary complexity. However, it actually makes sense for surviving a fire, and the mod already does that perfectly. - "finding out some animation hashes" - If that's possible right now, that would be awesome. - "special behavior when shot in both legs (dont know which behavior yet, maybe force pushing consistently but very weakly so it looks like stumbling/limping?)" - The game does its utmost to blend upright NPCs back into normal animation as soon as they seem stable enough, so in all likelihood they'd just glitch out. The "constant force push" method only works if they're in the dying state, i.e. lying on the ground in an enforced ragdoll state. It's worth testing out that feature to see if it looks good. If you want to see what it might look like, just walk into an NPC who's in the dying state (best do it in first person, because player movement is steadier in first person). The best behaviour, I think, would be the dismemberment behaviour but without the dismemberment. It's very underutilized in the vanilla game. Speaking of which, the "drunk" ragdoll behaviour might look great for NPCs who have been shot many times. Might be worth testing that out if the hash for it is known. - "disarming NPCs when shot in the hand (lawmen are almost un-disarmable)" - That would be fantastic. If aggressive lawmen can be fully disarmed and then run away like a normal NPC, it would provide players with a non-lethal way of defeating a lawman. It would be nice to have more non-lethal ways of neutralizing lawmen. I'll offer my views on 1.3 as soon as I'm done with testing the release candidate. 🙂
-
@HughJanusIt's been a pleasure to help out! About the new values, I'll try to find time to test them tomorrow. I may only be able to do so late at night, but I'll test them as soon as I can. If the bleeding is fixed and nothing else is broken, I'd recommend releasing this version as the official 1.2 update. It's already quite a leap from the previous version and feels feature-complete. As for the stumbling thing, it's fantastic that you can check whether both legs have been damaged. Problem is, for now, we have few behaviours to choose from. The problem with the DyingState and the KnockbackState is that the behaviour for both is usually very inactive, as if the enemy is in shock. This is fitting for a dying state, but not so much for a breathless state (Knockback) or for a non-fatally injured state (Stumbling). An enemy who's been knocked back by a bullet should be rolling uncomfortably on the ground (as if trying to get their breath back, or getting used to the pain of the wound) and an enemy who's been shot in both legs should be very, very agitated. So if I understand the current situation with the natives correctly, all we can do is drop the NPC into the dying behaviour if both legs have been shot. And that doesn't look right. There may be two workarounds to this: 1 - If the "on fire" ragdoll behaviour can be triggered WITHOUT the fire, we may be able to simulate an agitated state from being shot in both legs. So an NPC would repeatedly stumble when shot in one leg, and enter the "on fire" behaviour when shot in both legs. 2 - I noticed that, though the dying behaviour is very inactive, enemies still respond realistically to forces. So if you push them by walking into them, they'll turn around while in "living" ragdoll. In fact, this is determined by what caused the enemy to ragdoll in the first place. If they enter the dying behaviour from being shot in the leg, the ragdoll will seem more active because the leg keeps twitching slightly. If they entered the dying behaviour due to stumbling, they'll go into a protective fetal position if pushed around. And if they enter the dying behaviour from being shot from the torso upwards, they'll be more inactive (but still visibly alive). So the workaround would be to apply a small, constant force to the NPC while they're in the dying behaviour. The fact that the ragdoll is still being simulated as alive will result in the NPC constantly (but slowly) rolling around and readjusting their limbs into whatever their new position is, so it MIGHT look like they're moving themselves around instead of being pushed by something. It would make them seem much more active than they really are. However, in order to look right, the force would need to be applied constantly for a few seconds, stop for a few seconds, then be applied again in the other direction. Otherwise the NPC will just roll slowly but indefinitely in the same direction. Is anything like that even possible right now? PS: These workarounds are good for passive NPCs, but for aggressive ones, what would make sense would be for them to keep shooting at you from the ground. And that behaviour doesn't even exist in RDR 2. You know where it did exist? RDR 1. Enemies shot in both legs would be unable to leave their kneeling position (but still fire at you) and there was even a "crawling away" behaviour for fatally wounded enemies. Those behaviours aren't in RDR 2 at all, so they may only be possible once OpenIV figures out the files. Anyway. I'll get back to you on the new values as soon as I can. 🙂
-
@HughJanusOkay, I think I found the most realistic values for stumbling. Turns out I was wrong about x and z; it's the other way around. Z is upwards pull, X pulls to the right. Y remains forward, and apparently I was wrong about it having to do with the ped's current vector as well. While testing some higher values, I did see some NPCs lurch in the opposite direction they were headed in. But with the values below, that doesn't tend to happen: StumbleChance=80 RunningThreshold=3 StumbleForcePushX=0 StumbleForcePushY=400 StumbleForcePushZ=0 Here's what happens when those values are active: NPCs that try to run immediately stumble and fall. It takes two or three steps for it to happen, so they literally can't run, which looks more realistic. Sometimes they recover their footing before they fall, but in a way that looks more believable than previously. Most times, they'll actually stumble and fall, and if they do it on a slope, they'll roll all the way down. They'll stumble so often that you can almost keep up with them by walking. So now, shooting an enemy in the leg does prevent them from running away from you, and the stumbling looks frantic and energetic. At lower health values, NPCs won't actually be capable of fleeing for long. The frequent stumbling will chip away at their health until they reach the dying state, at which point they can't move anymore. So this leads to an accidental (but very welcome) exhaustion feature. In gunfights, it also has a significant effect. Enemies can mostly stay on their feet unless they try to break into a run, at which point they will stumble. They can still move without falling, but not if they try to run. So shooting an enemy in the leg prevents them from quickly changing positions. I tried setting RunningThreshold to 2, but that causes glitches on aggressive enemies. They'll be moving backwards but suddenly lurch forward in a way that looks weird (and without going so far as to ragdoll). A value of 3 ensures that the stumbling only kicks in at running speed. And frankly, it's believable enough that they can remain on their feet as long as they're not trying to outright run away. Ideally, a shot on both legs should stop them from getting up at all, but this feature isn't possible for now. I figure this is as good as it gets for now. It doesn't look perfect all the time, but that's mostly down to Euphoria's overzealous blending. I feel that it decides to blend back into normal animation too soon, while there's still significant momentum to the ragdoll. Regardless, this is a MASSIVE improvement. I recommend leaving the options in the .ini. No such thing as too many options. I figure the only thing left to fix is the bleeding, then.
-
@HughJanus Okay, I think I figured it out. NPCs ARE bleeding out but they don't die. I tested this by setting their health to 500 and DyingState to 499. I would shoot them once and they would go into the dying state indefinitely. However, if I shot them while they were in the dying state, they'd die instantly. If I disabled BleedWhenDying, one shot wouldn't be nearly enough to kill them in the dying state. Therefore what seems to be happening is this: NPCs enter the dying state, their health is depleted by the bleed-out feature, but for some reason, they don't die. They are killed by the slightest damage in that state, but they don't die from bleeding out alone. This may explain why some NPCs seemed to die from bleeding out when I first tested this. The stumbling feature actually causes incremental damage to peds. If you set their health low, stumbling 5-10 times will actually be enough to kill them, or drop them into the dying state if that's enabled. Therefore, ragdolling onto the ground chips away at health. So I guess that I shot the NPCs, the bleed-out feature led to their health depleting to near-zero before they hit the ground, at which point hitting the ground killed them. So that seems to be the bug with that feature. Now I'll see if I can find the ideal default values for the stumbling feature.
-
-
@HughJanusI'll have time to test more thoroughly in a few hours, but I took a quick look and first of all, y really was the right value for pushing NPCs forward. Or backwards, actually. Turns out negative values cause the whole thing to glitch out and skyrocket NPCs, but positive values work properly and they seem to always affect the direction an NPC is moving in, so if they're walking backwards, they'll stumble backwards. Y is what governs that, X pulls upward, Z I haven't tested which side it affects yet. Honestly, I'd keep X and Y in the .ini while clarifying which one does what in the commented sections, because tweaking does lead to significantly different results. Z may be useless, though, I'll determine that in a few hours. As for bleeding when dying, it's still inactive, although I intend to test it further soon. Two NPCs SEEMED to die from bleeding out early on, but this didn't happen again so I don't know if something else caused it. In every other case, NPCs would go into the dying state and not die. I set the parameters to make them die really quickly and they still didn't die. For now I have no clue as to why. I even set BleedWhenDying to 0 to see if the damn thing had been somehow inverted (far-fetched, I know) but nope, still didn't work. But yeah, stumbling seems fixed, it's just a matter of finding the sweet spot for the default .ini values. I'll do that on my next test run today. 🙂
-
@HughJanusYeah, the configurable value seems to be affecting their y direction, and I also found out a bizarre glitch that will have NPCs stand up in mid-air if you set the force push to something like 500. I set it to a negative value and it also sent NPCs rocketing towards the sky, so yeah. The fact that they're being pulled upwards may be what's causing that goofy glitch I mentioned, because being pulled upwards isn't as destabilizing as being pushed forward, therefore at the peak of the ascent Euphoria figures the character is on stable footing and triggers the recovery animation (or something to that effect). GTA 5 had a similar issue, actually. Without enough forward momentum, that's what happens. However, with the latest iteration of your mod, it happens far less. I found 300 to be a good balance in general, but 150 already works mostly. Still, it would be interesting to see if a forward push combined with a slight upward pull eliminates the problem entirely.
-
@HughJanusOh, an extra point about the stumbling: I played around with higher values and I noticed that the force push goes up instead of forward. Is there a way to tweak this? It may be more difficult for an enemy to recover their footing if the force push forces them forward. It also highlighted that your mod makes NPCs very resistant to falls, since I witnessed more than one NPC fall from 100 feet up and get back up again. But that's an inevitable effect of NPC health = 400, I guess 😄
-
@HughJanusI installed the mod at your new default values in the .ini and goddamn, you NAILED the knockback chance value. This new value strikes a perfect balance of variety because it prolongs the anti-stagger reaction without necessarily causing the NPC to fall over. They'll often blend back into their normal animation before they fall, so basically, with your default value, enemies take longer to process that they have been shot (as one would, in real life) but they don't necessarily fall over. However, they still CAN fall over. Most shots will lead to a longer reaction before they can back to shooting at you, and a few will result in them actually falling. So it's a great balance. The only things that break immersion are not your mod's fault: the stand-up animation and the way they get back to shooting at you are way too spry for someone who's just been shot. But I feel that, in this respect, your mod does everything that can possibly be done at this moment. You've pretty much fixed the stumbling. I still get the occasional goofy-recovery-before-falling, but in most cases the enemy falls over and it looks convincingly like stumbling. An enemy that gets shot in the leg can no longer outrun you, and it looks extremely realistic most of the time. It's a fantastic feature. It could only possibly look better if the enemy were forced into a constant limping animation after being shot in the leg, but I understand this is undoable for now. As for bleedout, at the default values, I've seen it happen once in a 10-minute-long gunfight. What I saw was someone keel over after stumbling and not get back up again. So I changed the default values to these: BleedWhenDying=1 BleedWhenShot=1 BleedingChanceShot=999 BleedingChanceDying=999 BleedingValue=100 Which should lead to them dying almost instantly upon knockback, but it doesn't. What happens is, every knockback shot drops them into a dying state, but they don't die. After tweaking those values further, I believe the BleedWhenDying boolean isn't working. They bleed from knockbacks, but once they get to the dying state, the bleeding stops and they remain alive. So those high values I set result in the enemy's health depleting near-instantly to the dying threshold, at which point they stop bleeding and remain permanently dying. But I did verify that BleedingChanceShot and Bleeding Value do have an effect on how quickly they go into the dying state. I was able to tweak it so that two knockbacks drop an enemy permanently into the dying state (on the second knockback). Those values are: BleedingChanceShot=60 BleedingValue=15 However, these values strongly affects the stumbling feature. Enemies will go into the dying state after the first stumble, so unless there is a way to differentiate between those states, one feature pretty much cancels out the other. The ideal version, I'd say, would be to fix BleedWhenDying and keep it activated by default on the .ini while BleedWhenShot remains deactivated by default, because it doesn't work well with the stumbling. BleedWhenDying is more stable and immersive, and it's just a matter of tweaking the DyingThreshold to decide how resilient enemies will be. As for the SpecialWeaponModifier parameter, 2 is a tad low. 5 strikes a better balance between ensuring high damage at close range (including one-shot dismemberment) but not being too effective at medium/long range.
-
@HughJanusTake your time! I'd recommend adding PedVelocity and ForcePush (example names for the parameters) to the .ini so the user can tweak to their taste, even if it means a force push that looks kind of weird (in order to ensure the ped will actually fall down). It could also be fun to tweak ForcePush to 9000 and watch peds stumble themselves into orbit.
-
@HughJanusI'm delighted to be of help! I just tested the beta, and I can confirm that the bleed out timer works, but there's some issues. First, the BleedingValue seems to either deactivate the bleeding feature or activate it at a fixed time (which is 8-12 seconds at 500 health). Bleeding values under 31 deactivate it. From 31 upwards (I went up to 12000), it's 8-12 seconds roughly. So the value seems to be working more like a boolean as of right now. One can get around this by increasing the NPCs health and the thresholds. Doubling the health resulted in twice the bleedout time, so that bit's working properly. The rate of bleeding, however, remains the same. Another thing (and this may be fully intended) is that the bleedout is only active while the enemy is in a knockdown state, so if they get back up, the bleedout timer stops. So shooting an enemy whose health is below the KnockdownThreshold will not activate bleedout unless they're actually knocked down. This may very well be the intended design, I'm just letting you know in case it isn't. It can actually work as an interesting mechanic, since a knockdown costs an enemy a lot of health. And finally, the stumbling behaviour plays into the bleedout. Basically, if you shoot an enemy in the leg while they're below the KnockdownThreshold, that's an instant knockout and the bleedout timer begins to tick. Often the enemy will get back up before they run out of health, and at that point the bleedout timer stops. But with every little force push, it ticks away a bit more, because for a brief moment the enemy enters ragdoll. If a force push occurs below the DyingThreshold, they just fall over, don`t get back up again and bleed to death. So yes. A shot in the leg is an eventual death sentence now. 😄 As for the stumbling, it's definitely improved. Now the NPCs can build up more speed before the force push happens, but as it turns out, it's still not enough speed for the force push to actually tip them over. Sometimes it happens, often it doesn't, so NPCs do still get "locked" into reaction animations. However, now they actually move forward considerably before the force push "resets" them. I think you can let them build a tad more speed before the force push happens, or you can make the force push stronger. Either way, seems like it's just a matter of tweaking now. It does look like you figured out the running speed threshold! It may be a good idea, perhaps, to try a stronger force push, because as I said in the earlier posts, enemies can still recover mid-ragdoll without actually falling, and it looks quite goofy.
-
@HughJanusI figured as much, no worries. We're still in the early days. I actually wasn't expecting to see a mod like this for another several months. 🙂 Speaking of the force push method, I took a closer look at the stumbling feature too. It works really, really well when the NPC is walking or running. Your code adds just enough of a forward push to make the NPC tip over in a way that looks natural. Problem is, that same push isn't enough to tip over an NPC who's standing still. Therefore, in those cases, the NPC will only jerk forward slightly, not enough to go into ragdoll. At default percentages, this causes a semi-frequent stutter in the NPC's animation. At higher percentages, that force push is applied constantly, and that will easily "lock" the NPC into a repetitive reaction animation that never allows them to walk or run, thus they can never build momentum and become perpetually locked. It does look quite funny, though. I figure this can't be fixed currently (not until an NPC's velocity can be checked) but as it turns out, the default percentage does have a believable frequency to it. The only problem is that NPCs will often recover mid-ragdoll and it always looks goofy. Is there a way to keep an NPC in ragdoll for a minimum amount of time, to guarantee that they will actually fall to the ground after stumbling?
-
@HughJanusI just tested the issue further and I think I figured out what the problem is: there's an anti-stagger behaviour applied to any enemy that's currently firing at you (not just lawmen). I tested this with vanilla. If you shoot an NPC who's in passive mode, they're programmed to stumble, fall and get back up. They don't shrug off the bullet. However, if they take out their gun and start firing at you, your bullets will not knock them down. They'll just shrug off the shots until their health is depleted. Exceptions to this are leg shots (they always cause a fall), artery shots and extreme circumstances (i.e. NPC is shot while dismounting a horse). I also managed to test this with the same NPC: I shot him in the torso while he was in passive mode, he fell, got back up, started firing at me, and from that point on, torso shots wouldn't knock him down. When you shoot an aggressive NPC in most parts of their body, they apparently go into a specific ragdoll behaviour that is designed to PREVENT a fall while still reacting to the impact of the bullet. The ragdoll quickly stabilizes the NPC again so that they can blend back into normal animation and keep firing at you. It takes a fraction of a second. If they happen to be moving extremely fast or they're tossed against scenery, this anti-stagger behaviour is overruled and they just fall. But in most cases, the behaviour works: they'll react to being shot but they'll stay upright and keep firing at you. I enabled the mod in order to test this further and, indeed, the circumstances in which the "shocked" behaviour kicks in are the exact same circumstances in which the anti-stagger behaviour would have kicked in. Artery shots, leg shots and headshots don't cause the "shocked" reaction, but any other kind of shot does. So if I had to guess, this is what's happening when your mod's enabled and you shoot an aggressive NPC: 1 - The NPC goes into anti-stagger ragdoll. 2 - Your mod prevents the NPC from blending back into normal animation, so the anti-stagger ragdoll is prolonged and does what it was designed to do: it brings the NPC to a complete standstill, stabilizing them. 3 - Wounded ragdoll kicks in shortly afterwards and the NPC falls over. I may be completely wrong here; as I said, I'm utterly hopeless at coding. 😄 EDIT: This would also explain why they're completely unresponsive to bullet impacts while they are in the anti-stagger ragdoll. Makes stabilization easier.
-
FULL DISCLOSURE (February 14th 2020): After this review, which was posted on February 9th, I started contributing to the mod and am now credited as co-author of version 1.2 (though all the real hard work is still by HughJanus, I'm just helping out as tester and suggesting features and .ini values). So the review below is for the 1.11 version when I still didn't know I'd get involved to this extent. It does what it says and is very configurable through an .ini file. If you're not keen on the increased health for NPCs, you can set it down to normal levels and still enable the more advanced behaviours of the mod as explained in the description (dying states, knockbacks, fires that don't magically kill NPCs in two seconds). Given that so much of RDR2's code is still unknown, the features in this mod are downright impressive and make the game much more immersive.
-
@HughJanusOh! I had misunderstood what KnockbackChance meant. I set the parameters to what you suggested and indeed NPCs do get back up after a random amount of time if you set it low enough. That's fantastic. One thing I've noticed is that the behaviour is different when facing armed enemies (or specifically lawmen when they're hunting you, that's where I've seen this issue the most). Shooting an unarmed NPC will cause them to stumble in the direction of the shot and fall over, which is perfect. However, if an enemy is actively shooting at you, they won't act that way when they're shot (unless it's an artery shot). They'll just stand there for a moment, arms down, as if they're processing the fact they've just been shot, and 2-3 seconds later they'll fall over. It looks like a shocked reaction, and interestingly, while that behaviour is active, they're unresponsive to bullets. The wounds will show up but they won't be pushed by the shots, they just stand upright for two or three seconds then fall over. This behaviour is overruled if they're moving fast or if you run into them, at which point they'll just stumble and fall. But if they're moving slow enough, they'll come to a stop when shot, stand there for 2-3 seconds, then fall over. This is, of course, when their health is below the threshold (either Dying or Knockback thresholds). I am utterly hopeless with coding, so the source code looks like sorcery to me (although I must compliment you on how well you comment your code). Do you think that "shocked" behaviour with armed enemies is caused by something in your code, or is it just a side effect of vanilla behaviour? If you want to replicate this potential bug, just get into a fight with lawmen with either KnockbackThreshold or DyingThreshold set to 499. You should see a difference between how the lawmen react to a knockback shot and how an unarmed NPC reacts. This may be a specific problem with lawmen, since some rules apply differently to them (they can't be fully disarmed, for instance, revolvers are pretty much glued to their hands). I wouldn't be surprised if this issue is currently unfixable. (EDIT: To clarify, I'm specifying lawmen because other kinds of armed enemies will often react normally to being shot, it really depends. As I said, this may be specific to lawmen, so it's worth testing it in shootouts against the law.) As ever, thanks so much for your replies and your work on this mod. You've really done an astounding job.
-
@HughJanusWhoa! I found a new problem, but this is a MASSIVE improvement. You single-handedly fixed one of RDR2's most immersion-breaking features. Here's the problem I found: it's quite possible that KnockbackThreshold and DyingThreshold cause functionally identical behaviour. The knockback behaviour is exactly the same as the dying behaviour. If I set KnockbackThreshold to 499 (with KnockbackChance to 100) and DyingThreshold to a very low value, a single shot will result in the enemy falling over into a dying behaviour and -- as far as I've seen -- never getting back up again. I did test it by shooting an NPC and seeing if they ever got back up, but minutes passed and they remained on the dying behaviour. Inverting the parameters (DyingThreshold to 499, KnockbackThreshold to a low value) would cause the exact same thing to happen, the exact same behaviour (except this time they were congruent with the parameters). If I understand the mod's description correctly, the Knockback is supposed to keep the NPC down for a certain amount of time, correct? It's the out-of-breath feature, so you shoot them, they fall, they get their breath back for a random amount of time, then they get back up in the fight, is that it? If that's the idea, then it's not working that way. Knockback and Dying are functionally identical behaviours. I set both down to 0 to see if it could be something else, but when they're both set to 0, then NPCs simply behave like in the vanilla game. Only by setting either parameter to a high value would the Dying behaviour kick in. Interestingly, KnockbackChance still has an effect over whether or not an enemy enters the Dying behaviour as set by KnockbackThreshold. So those values seem to be correctly interlinked but leading to the wrong behaviour. Another problem, which was also present in 1.1 and I think 1.0 but I forgot to mention it, is that headshots seem to have some problematic hitboxes. Hitting near the outline of the NPC's head will not cause them to die. In some cases I've shot the side of their head dead-center and they didn't die, as if the bullet has to hit the actual face in order to kill instantly. Finally, I tested the stumbling behaviour and it is unchanged. I'm mentioning this just in case you tweaked it, just so you know whether it changed anything. That's about it. Congratulations and thank you, the mod is now a huge improvement over the vanilla game. There's some great interplay between features now: if you hit an artery shot when the enemy is already near the DyingThreshold, they'll go into the artery shot ragdoll behaviour and then straight into the dying behaviour, without getting back up and running away. It adds a lot of variety to gunfights.
-
@HughJanusThanks for the reply! So I just tried the settings you suggested (I had tinkered with them previously) and they actually just prevented enemies from ever being knocked down, because the Knockback Threshold you suggested is 10 and it takes forever for them to go from 500 health to 10. Knockback only works from the start if it's set to 499, with knockback chance being set high as well. I set it to 99, but knockbacks aren't happening as frequently as that value suggests they should. As for DyingThreshold, it doesn't seem to have any effect regardless of what value it's set to. Be it 10 or 499, it never works. Those three values seem to be problematic, in fact. KnockbackThreshold does seem to actually work, but KnockbackChance doesn't really seem congruent with its values, and DyingThreshold does nothing. As I said, enemies always get back up instantly, even when their health is near zero. And yes, I've tried changing NPC's starting health, and tinkering with different combinations of values. Same result. I also tried the mod without any other mods active, just Scripthook. I went back to a previous save to make sure a trainer hadn't screwed something up in the current save. Same problem. DyingThreshold really works on your end? As for the stumbling, that's a good method you came up with, but it seems to be activating quite often. If you set it high, then NPCs seem to have force applied to them every few frames, resulting in glitchy movement. It seems like the effect can kick in at any time, so at high values it just kicks in all the time. The default value of 30 works fairly well, although perhaps the ragdoll time could last a bit longer. As for all the trouble with natives, yeah, I figured there were plenty of unknown values holding back the more ambitious features. Thanks so much for working on this mod and making it available. 🙂
-
Hey there! I love what you're trying to do with this mod. However, it doesn't seem to be working as intended in most cases. Enemies always get back up as soon as they fall over, so you can't knock the breath out of them (just like in vanilla), there seems to be no "wounded state" (they're either dead or not dead, unless there's an artery shot), the stumbling is very prone to glitches and doesn't feel realistic anyway, since an enemy shot in both legs shouldn't even be able to get back up. All in all, the mod doesn't really offer a way to "cripple" your opponents unless you get an artery shot, which is already in vanilla. It only seems to make combat more difficult by forcing a headshot; unless you get one, enemies are pretty much made of steel and can take literally forty shots to the chest before even considering the possibility of dying. So here's my suggestion: vanilla is actually quite generous with health already, depending on the weapon. It takes 4 to 5 shots to the chest with a revolver in order to kill an enemy. Rifles are more powerful than that, but their advantage should be range, not raw stopping power. Truth is, ANY bullet to the chest, from any weapon, should be a considerable hurdle to one's day. If the point is to make enemies react more realistically to damage, then different behaviours are required. You nailed it with the fire behaviour: enemies now remain alive for a realistic amount of time until the fire kills them, and even if they survive, they go into a permanent wounded state in which they're alive, conscious but incapacitated. So here's what I propose, and bear in mind I don't know if natives even allow for this, so I'm just spitballing: 01 - Apply that wounded state more often. It makes no sense for an enemy to take three bullets to the chest and keep fighting. They should either die or remain mortally wounded for minutes, regardless of whether they were shot with a rifle or a revolver. 02 - A shot in one leg warrants that stumbling mechanic (though it needs polish). A shot in both legs should lead to a permanent wounded state, since the enemy shouldn't be able to get back up with both legs crippled, and nor should they die from it. This may create problems with enemies spawning (since too many living enemies keeps new ones from coming in), but you'd have to non-fatally wound a LOT of enemies until that became a problem. 03 - A shot in the shooting hand should also lead to a wounded state: the enemy has no chance of firing back with a crippled hand (yeah, they could try their left, but I doubt the natives allows for that level of finesse). Better yet, they could simply run away. For some reason, this isn't possible with lawmen (they can't be fully disarmed), but it is with regular NPCs. 04 - It would be nice to have some variety for artery shots, since the behaviour always repeats itself: fall over, get up again, run away (for a very long time, with this mod), fall over again, die. In fact, this tends to happen more frequently with this mod. If there's any way to do this with natives, I would suggest sometimes enemies maintain their ragdoll behaviour right after an artery shot until they die. The ragdoll behaviour right after the shot is perhaps the most impressive in the game, but as soon as the enemy falls over, they go into the wounded running animation and there's no longer any ragdoll behaviour until they die. It would be nice if that didn't always happen. Arterial wounds aren't tipically a great incentive for running around. 05 - It makes perfect sense for shotguns, dynamite and other heavy weaponry to maintain their stopping power, so I suggest no changes there. As I said, fire is also great now. You seem to have nailed those. All in all, I suggest not increasing enemy health (though the .ini could always keep that option); instead, add a greater variety of behaviours that reward strategic aiming. Being able to non-fatally wound an enemy rather than kill him is great for roleplay, since right now there's no way to do that. You either kill them or tie them up, or they'll never stop trying to murder you.