-
Notifications
You must be signed in to change notification settings - Fork 4.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Killed a giant wasp and it fell on me, shattering my skull instantly and killing me from full hp #67785
Comments
In my opinion, the damage calc should depend on:
|
I would say it works as intended, except for the missing chance to miss (due to objects, monsters and characters not occupying the whole tile most of the time). |
Let's say a z-level is 2.5 meters. The wasp would be falling for √(2x2.5m/9.8m/s2) = 0.714s, and it's final velocity would be 9.8m/s2 * 0.714s = 7m/s. It's kinetic energy would be 87.5kg*(7m/s)2 / 2 = 2177 J, which is close to the muzzle energy of a 7.62×39mm fired from an AK47, which does 44 damage in game. Also:
TL;DR: 99 damage is too much. Somewhere between 20-44 damage would be more realistic. |
You probably didn't take in account that falling straight into your head would snap your neck plus brain trauma. I know someone who broke their arms from falling off their couch. This is a lot of conjecture though :P |
If the wasp is close enough to attack you it's what. 0.5 meters? |
I agree with the length, but 100 kg of wasp is the same is 100 kg of non-wasp |
The wasp would not be falling 2.5 meters but ~70cm (considering man height of 1.8m). So kinetic energy at impact would be mere ~500J. Also bullets do penetration damage and to compare them you would need to compare pressure and force. Formulas aside, 87.5kg and 2.5m is pretty much a man falling from not very high ledge on another man. Not saying it definitely can't be lethal but in most cases it would be few bruises. |
According to the following study, there's a 50% chance to survive a fall from 48 ft./14.6 m, which is mechanically equivalent of something weighting as much as you falling with the hardness and rigidity as the ground falling on you. https://link.springer.com/article/10.1007/s00068-017-0799-1 We can normalize 14.6 m to being 84 damage, the same head hp as a 8 strength character, Looking at the damage value for bullets in GAME_BALANCE.md, damage is equal square root of kinetic energy (muzzle energy). If we say falling damage is also proportional to square root of kinetic energy, we get a proportionality constant of about ~0.75. I.e. damage = 0.75 * √(Ke). Then we would have the following damage for a falling 87.5 kg rigid body with a z-level being 2.5 m:
Calculated with a z-level being 14 ft (~4.3 m), the average height of a floor in in the US, the damage table would look like this:
|
Realistic
I recommend adding this to the calculation: substracting the target height from the distance of the falling object. Then small insects would get more crushed than hulks. Especially in the OP's case:
I believe that the OP's case would be the most common. So it definitely should be considered as the most important. Sensible Alternatively. If you kill with a mele weapon something over your head, it is in reach regardless if you are 2m50cm or 20cm tall. So just substracting a whole tile might be the most bug-prone way. Making the feature not totally broken but still viable strategy. Just get a floor higher to throw the piano on the shocker's head to achieve the same result. But don't kill hulk by placing something on their head. I read somewhere:
|
That's just some dumb shit which has nothing to do with CDDA development. |
idk it's relevant here isn't it? semi buoyant wasps falling 50 cm after dying should just not kill you. |
No, it is not relevant. 90 kg (wasp or not) falling onto your head can easily break your neck and kill you. |
The wasp is not a bowling ball. It is a flexible articulated body with a high surface area. Even if it lands squarely on top of you, it is not going to transfer all of its energy into your head. If a 100kg bowling ball landed on your head you would definitely be in trouble. Most wasps also should not be 100kg. That is way heavier than makes sense for a roughly man-sized insect that is supposed to be flying partially aided by hydrogen sacs. |
The dynamic kinetic energy of a moving object is defined by its mass and velocity. Its surface area would affect drag force, but not that much, so we can ignore it. When an object is dropped onto something it would lose its kinetic energy to do some work until fully stopped. If stopped by the head it would do that work deforming the head (and possibly itself).
100 kg is 100 kg whether it is a wasp or a bowling ball or anything else, so you are in trouble either way.
All monsters of specific monster type have exactly the same weight in DDA - 81500 g. It might be a wrong value (and that is a separate issue), but it does not matter for calculation - formulas would be the same no matter the values used. |
Quotes from thread on discord to more appropriate place: so I think the correct thing to do might be to add a perception test as well as the existing dodge roll. dodging a falling object is different from dodging an attack, the first major question is "do you see it coming". If you do, we should significantly buff your dodge. You should auto-pass this test if the falling object is something you killed or launched yourself. also I think:
is incorrect, since that's 60% if the drop is totally random. If you drop an item randomly into a ~1-2m square region, there's not a 60% chance you'll hit a person-sized target. We should drop it to at most 25%, and probably more like 10%. We could consider making it partially influenced by the item's volume. The chance of it hitting your head is already modified by your dodge. The more you successfully dodge the more likely it is to hit your arms, so if we drop the base hit rate and add a perception test, it should be very hard to hit yourself with a falling wasp unless you are otherwise unable to defend yourself. |
@I-am-Erk beat me to it, but my approach is a bit different... When a sufficiently heavy thing lands on you, you could fall down. Is that simulated? Your neck is bent as you are looking up at the thing you just fought. If you don't manage to dodge, no, rather either the simulation picks your action, or you should be able to pick one. It is based on dodging skill, and strength. If you didn't yet notice, then on your trap skill to check if you do notice. Defend Leaping Better with dodging skill and dexterity. The more time you have, the easier it is / the further you get. Catch / push away |
I would like it if the player could choose. It would say what increases the chances, Like surgery or something I don't remember. |
Your diagrams are wonderful. Generally we try to avoid player input on these things for a couple reasons; first, it represents the kind of split moment decision that feels like the opposite of pausing the action to pull up a dialogue, and second, because we still have to code in all the behaviour trees for what to do anyway for NPCs, so it means doing all that and also doing an optional dialogue that interrupts the action. Your general summary is correct but I think honestly that most of that can be modelled by "if you see it coming and try to get out of the way, chances are it either misses you or hits your arms rather than your squishy parts". It would be nice if your helmet and shoulder armour had higher coverage against falling attacks, idk how tough that is We should also highly increase the chance of getting knocked down by these attacks. That's naturally modified by strength. |
I was going for a DnD feeling, that's why I wanted the choice. But simple Something is falling on you!
Would do. I would prefer if you could choose a direction of the leap. I would like the flavour text, |
Random thought: We have some info from the monsters that we could use to approximate rigidity, such as armor. A skeletal zombie, giant wasp or Exodii with a high stab armor to bash armor ratio is going to be more rigid than a slug, slime or fat zombie with low stab armor to bash armor ratio. Also bodytype, material, phase and weakpoint families provide some info. |
This is patently incorrect. The wasp is a large, partly soft, and most importantly articulated body with a very large surface area. When it impacts with the top of your head, it does not transfer all of its energy into your body because the rest of the wasp is still falling down around you. Your head is a stop on the way down, not the end of the fall. A bowling ball is much more dangerous because it is denser. It comes at least momentarily to a full stop on top of your head and delivers much more force into your body. One Z-level is a single floor. It's maybe 2.5 meters tops. 100kg is the size of an adult man. Adult men fly into each other at moderate speeds all the time - police, football players, etc. This occasionally results in injury, but to say that your uncle jumping out a second story window and landing on top of you should instantly and invariably squash your head like a melon is ridiculous. As mentioned above, a human body is also not an immobile post buried in the ground. A lot of what energy the body does receive, even on a direct hit, is absorbed when the body moves in response to the impact. Knees bend, the person tips over, they cover their head or duck so that part of the impact hits their arms or back, etc. Lastly the calculations are obviously broken because you can kill bosses by dropping water or sand on them. Mass and velocity might be the only thing you need to think about when you're describing small projectiles like bullets (and even then ballistic performance is actually a lot more complicated than that), but things obviously get a lot more complicated when you're dealing with anything bigger. |
100 kg is 100 kg |
As I said in discord, damage calcs are very much secondary. First see what a far less accurate hit roll does since it will then be smacking secondary body parts. Then let's review damage based on that. |
This comment was marked as abuse.
This comment was marked as abuse.
This comment was marked as off-topic.
This comment was marked as off-topic.
I am affraid this will have to be settled with a physics experiment. |
One thing that has not been explicitely brought up yet is that most monster masses and their densities are likely vastly wrong. There is no method to determine a somewhat correct value for most of our (mutated) critters yet. Wasps are just one example. That could benefit from a seperate issue if someone wants to look into that. And folks, please cease the hostilities. Especially when you happen to have a badge due to being in the CleverRaven organization. |
I've been working on how the weight carried cache is handled, and I noticed something that's relevant here, in
This function is called from This code is also responsible for the player's weight carried cache getting invalidated every time any item is loaded to the map, so I'll probably fix it up as part of my PR. This is a separate topic to the damage discussion going on here, note, I just thought it was funny and technically related. |
For what it's worth, this is my stance. I think ZhilkinSerg is correct that a 100kg bug falling on you should probably be very damaging, even taking elasticity/dodging/air resistance into account, but... the mutant wasp being 100kg and yet still able to fly around seems like the real unbelievable thing, here. The largest flying bird in the world is only 15kg. If we want mutant bugs to stay heavy, maybe we could say they have, like, hydrogen/helium sacs that keep them light despite their size? |
This does not have to be an abstract problem. Like I've said before, the problem we are discussing can be easily replicable real life and is hardly fatal. 85kg is weight of an average adult man. Human body is not made of glass, most likely you will end up with some bruises if someone will fall on you. Not saying it can't be fatal, but it is lot lethal by definition or physics. We have joints that will absorb the fall, we have instinct and we do lean backward to not be hit at 90 angle. I would say that if we talk about imaginary realism, 99% of time you would fall on your back. This is not bullet headshot or 100kg bowling ball scenario by any means. |
This is going around in circles. The first step to the solution has been covered a few times: reduce the way overcharged hit rate, ideally add more weight to perception and make it almost impossible to hit yourself with a falling object. This should inherently reduce a lot of damage concerns because the design already models a lot of the basics (cover your head with your arms, get out of the way). Once that's implemented, and basic bugs like liquids not being excluded are also fixed, we should assess if there are other concerns and address them as they exist at that time, because the core balance will have changed and most of this long circular discussion will be irrelevant. Given that the ongoing circular discussion is drowning out how to fix the bug, I'm gonna lock this to contributors if we can't get off it, k? |
I have to disagree - falling will need to correctly account for wind resistance, strike surface area, and hardness of the falling object before it can be called a decent simulation. It's a fine first step, but dodge alone will not be sufficient, and I feel like you're trying to set up the expectation that it will solve the argument. |
No, I'm trying to set up the assumption that the overall play balance is going to be dramatically different when it's far harder to nail people in the vitals and when we can assume almost every falling item that hits is hitting with intent. Much of what you're describing is the (long desired) revamp of all thrown items, and well out of scope of the problem at hand - which is people killing themselves by shooting an enemy on the z level above. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. Please do not bump or comment on this issue unless you are actively working on it. Stale issues, and stale issues that are closed are still considered. |
Here's a huge issue, in addition to Kamayana's excellent point. The drop damage always assumes it falls the full distance, regardless of how far it possibly could drop. Line 2881 in f243a09
I have prepared a I believe the first z-level (for arbitrary dropping of items) and final z-level (only when impacting a creature) should be greatly reduced in effect. Right now it's assuming that dropped item had an entire z-level to fall, even though that clearly can't be the case with an enormous flying wasp which occupies a large area of the tile (and is engaged in melee with you, etc). As an example, here's the formula and some results with hypothetical values. |
Describe the bug
Due to the way items cause falling damage from #65125 any given item does damage equal to (Mass in KG x Z-levels fallen x Its density). A giant wasp weighs 87.5kg and has a density of 1.1. I killed a wasp directly above my head and it fell on me, doing 99 damage.
This is a problem for every other flying enemy too but this is pretty silly in particular since it's a oneshot.
Attach save file
n/a
Steps to reproduce
Expected behavior
Falling damage should be based solely on density and not on weight to prevent ridiculous situations like this (and preventing you from doing ridiculous things like oneshotting mutants and the MTF by dropping an engine block on them)
Also, things probably shouldn't do damage this way, if it's close enough for you to shank it with a sword it's not going to fall fast enough to hurt you.
Screenshots
Versions and configuration
Dark Days Ahead [dda],
Disable NPC Needs [no_npc_food],
Portal Storms Ignore NPCs [personal_portal_storms],
Slowdown Fungal Growth [no_fungal_growth],
Bionic Slots [cbm_slots],
Stats Through Kills [stats_through_kills]
]
Additional context
THE WASPS DID IT AGAIN
The text was updated successfully, but these errors were encountered: