So the hit function has this :
script.Parent.Touched:connect(function(hit)
end)
If the hit.Parent touches it,Then the part acesses its CHARACTER,How do i make it access the Player?
So the hit function has this :
script.Parent.Touched:connect(function(hit)
end)
If the hit.Parent touches it,Then the part acesses its CHARACTER,How do i make it access the Player?
script.Parent.Touched:connect(function(Part)
local Char=Part.Parent
if Char then
local Player=game.Players:GetPlayerFromCharacter(Char)
if Player then
--Code goes here
end
end
end)
This discussion is preserved as it was. New answers, comments, and votes are closed.
1 comment
Thanks!