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

Outfit Script Change, how to make the script where it gives the option to buy it 1st?

Asked by 6 years ago
Edited 6 years ago
debounce = true

function onTouched(hit)
    local h = hit.Parent:findFirstChild("Humanoid")
    if (h ~= nil and debounce == true) then
        local g = script.Parent.Parent:findFirstChild("Suit") -- the name of your template
        debounce = false
        p = g.Pants:clone()
        s = g.Shirt:clone()
        p.Parent = hit.Parent --delete if you dont want pants on the costume
        s.Parent = hit.Parent --delete if you dont want pants on the costume
        wait(1)
        debounce = true
    end
end

script.Parent.Touched:connect(onTouched)

Like I've been trying various things out all day.. I hope you can help me!

When buy it I mean Robux by the way!

0
Side Note: That script is inside of a brick. 2Westy2 2 — 6y

Answer this question