How do I make a Simple Fall Damage Script?

Like it says in the title, I am wondering how to make a fall damage script. Yes, I know their is lots out their and I tried a few, and just did not like the way they worked.
I just want it so that when the player falls, as long a they fall above a minimum distance, then they get damaged a certain amount depending on the distance.

Thanks.

You can check when they fall by seeing when the HumanoidState changes to fall and when it does record the start Vector3 and then when it stops get the end Vector3 and calculate the magnitude of them subtracted then that will be the fall distance, with that you can divide or multiply it and subtract that from humanoid health.

Realism Mod (plugin) has a good fall damage script.

2 Likes

I just got the realism mod like you said, and sometimes when I fall, it reads WAY wrong numbers, I jumped off a 200 high part and it only read 3 for fall Hight, any way to fix that?

Screenshot 2023-07-01 at 6.06.21 PM
Click the settings button and edit it.

I did and It did not work, it is still outputting wrong numbers.