Is it possible to make a localscript that detects damage

is there a way to make a damage detection script for the player?

if there is please tell me how, or what to use to make it.

You can take a look at this post Humanoid | Documentation - Roblox Creator Hub to understand it better, hopefully your game comes out well.

1 Like

You can use the HealthChanged function of the Humanoid and compare the humanoid’s last health with their new health, and see if the last health is greater than the new health to say that the player has taken damage

Yes, but I would use a Server Sided script. This mainly to prevent exploiters from being able to change their health while they should be dead and stuff.

I’d recommend using Humanoid.HealthChanged
More info can be found here

1 Like

…You can’t use localplayer in a serverscript

If this helped, and your problem is solved, please mark this as solution!