Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How to make hat which you can't drop?

Asked by 8 years ago

How to make a hat which you can't drop? I tried welding but I'm just not good at it. Any ideas?

0
Remove the handle object from the hat object and delete the hat. Then weld the handle to the character and set the handle to unanchored. Uglypoe 557 — 8y
0
Ill try that now. airassassin99 0 — 8y

1 answer

Log in to vote
0
Answered by
BlackJPI 2658 Snack Break Moderation Voter Community Moderator
8 years ago

You could use the AncestoryChanged event on the hat to detect when the player drops it. As soon as this happens, re-parent the hat to the player who dropped it.

Assuming player is defined:

local hat = player.HAT_NAME_HERE

hat.AncestoryChanged:connect(function(child, parent)
    hat.Parent = player
end)
Ad

Answer this question