Part destroy character but not other things

Im making a part that destroy all that touch, but only destroy players characters

ServerScriptService(need to be in ServerScriptService)

local DVP = workspace:FindFirstChild("DVP")

function DVPF()
if not DVP then
	local DVP = workspace:WaitForChild("DVP") or workspace:FindFirstChild("DVP")



Firstly you don’t need all that code searching for DVP, you can just use workspace:WaitForChild("DVP")

Secondly, you can scan to see if what has touched a part is a character:

local DVP = workspace:WaitForChild("DVP")

     local Humanoid = hit.Parent:FindFirstChild("Humanoid") -- Search for Humanoid
     if Humanoid and Humanoid:IsA("Humanoid") then -- If Humanoid exists and is a Humanoid
          hit.Parent:Destroy() -- Destroy the Character

Hope this helps!

Yea, but i create a script to create the “DVP” so if script take long only one WaitForChild not will find it fast.

And the problem its the script only destroy the character and i need to destroy all that touch not only the character.

If this is the case, .Touched() does not fire when interacting with other anchored parts as Physics are not applied. Can you send a screen recording of what exactly the incorrect behavior is?

i want to destroy all that touch, but dont destory anything without character i tried change the anchor/cancollide, more but the part didnt destroy, i only need a part that destroy everything that touch.

Could you please send a screen recording so I can see how this is currently working?

this is the part(its invisible) and he is touching the baseplate, but the baseplate isnt destroyed

(The character is destroyed but the others parts not)

This is because the Baseplate is Anchored and does not trigger .Touched(), as physics are not being applied to the Baseplate.

ok, so its possible to make that part destroy the baseplate when touch?
or i need to see the position of the baseplate and when the part touch this position the baseplate has destroy?

.Touched() only fires on new touches, since these two parts are already in contact when you start your game, they are already considered to be touching, and .Touched() does not fire.

the parts arent already touching when start, the part change the size and touch the baseplate

Normal position (0,10,0) and the part its created with a script