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

Why is my gasmask to hat not working? (part to tool to hat)

Asked by 5 years ago
Edited 5 years ago

You may think this maybe a silly question, but I was making a gas mask for SCP Breakout V.0.0.2 Alpha version, and i got this gasmask you click and it gives you a tool. You have to activate the tool and then you get the mask on your head, but it doesn't work without error. Why?

script.Parent.Parent.Activated:Connect(function(player)
    local h = Instance.new("Hat")
    print("hi") --Added to print if it works.
        h.Parent = game.Players.LocalPlayer.Character
        script.Parent:Clone()
        h.AttachmentPos = Vector3.new(-0.21, 0.35, 0.65)
        h.AttachmentRight = Vector3.new(1, 0, 0)
        h.AttachmentUp = Vector3.new(0, 1, 0)
        h.AttachmentForward = Vector3.new(-0, -0, -1)
end)
0
Are you using a localscript or a server script? maumaumaumaumaumau 98 — 5y
0
^ Localscript. Oh and it'll be a singeplayer game. User#22722 20 — 5y
0
make sure the meh or part is named handle also u don't need to all that attachment there is a plugin called hat grip iedtor helleric -3 — 5y
0
The Hat class is deprecated, use Accessory. Also, Activated does not pass the player. User#19524 175 — 5y
0
I just find it pointless, as it just spawns on the ground. User#22722 20 — 5y

Answer this question