- What’s the problem?
I have this script where if you click your mouse your clothing will change into the scripts clothing, but it only shows in my screen and not anyone else’s.
- What do you want to achieve
I want to try and make it so the script will make everyone be able to see the clothes it gave you when you clicked your mouse.
local Pants = script.Parent.Pants
local Shirt = script.Parent.Shirt
local localPlayer = game.Players.LocalPlayer -- get the localPlayer
local mouse = localPlayer:GetMouse()
local Clicks = 0
Suit.Equipped:Connect(function()
mouse.Button1Down:Connect(function()
Clicks = Clicks + 1
if Clicks == 1 then
local character = localPlayer.Character or workspace:FindFirstChild(localPlayer.name)
if character then
for i,part in pairs(character:GetChildren())do
if part:IsA("Pants") or part:IsA("Shirt") then
part:Destroy()
end
end
local NewPants = Pants:Clone()
local NewShirt = Shirt:Clone()
NewPants.Parent = character
NewShirt.Parent = character
local Sound = script.Parent["Shirt 2 (SFX)"]
Sound:Play()
end
end
if Clicks >= 2 then
local character = localPlayer.Character or workspace:FindFirstChild(localPlayer.name)
if character then
for i,part in pairs(character:GetChildren())do
if part:IsA("Pants") or part:IsA("Shirt") then
part:Destroy()
end
end
local OP = script.Parent.OPant
local OS = script.Parent.OShirts
local OldPants = OP:Clone()
local OldShirt = OS:Clone()
OldPants.Parent = character
OldShirt.Parent = character
local Sound = script.Parent["Shirt 2 (SFX)"]
Sound:Play()
script.Parent.Parent:Destroy()
end
end
end)
end)
If anyone can help I’d very appreciate it!