local Door = script.Parent
local owned = false
Door.Touched:Connect(function(i)
print(i.Parent)
if not owned and i.Parent:FindFirstChild("Humanoid") then
Door.Transparency = 1
Door.CanCollide = false
Door.Parent.Name = i.Parent.Name.."'s Tycoon"
end
end)
✓ ANSWER ACCEPTED
How do i Allow the player to touch the part and claim it?
1 answer
✓ Accepted answer
you need to set the owned
local player = game.Players:GetPlayerFromCharacter(i.Parent)
if player then
owned = player
end
This discussion is preserved as it was. New answers, comments, and votes are closed.

1 comment
this doesnt really tell us anything, are there any errors when you run this script?