local rs = game:GetService("ReplicatedStorage")
local serverStorage = game:GetService("ServerStorage")
rs.Events.Deploy.DeployPHANTOM.OnServerEvent:Connect(function(plr)
local char = plr.Character
for i, part in ipairs(char:GetChildren()) do
if part:IsA("Accessory") or part:IsA("Pants") or part:IsA("Shirt") then
part:Destroy()
end
end
char.Head:FindFirstChildOfClass("Decal").Texture = "rbxassetid://"..serverStorage.Accessories.PHANTOM.FaceID.Value
local pant = serverStorage.Accessories.PHANTOM.Pants:Clone()
pant.Parent = char
local shirt = serverStorage.Accessories.PHANTOM.Shirt:Clone()
shirt.Parent = char
end)
Uh I tried the code of someone in your source and nothing is happening :
local rs = game:GetService("ReplicatedStorage")
local serverStorage = game:GetService("ServerStorage")
rs.Events.Deploy.DeployPHANTOM.OnServerEvent:Connect(function(plr)
local char = plr.Character
for i, part in ipairs(char:GetChildren()) do
if part:IsA("Accessory") or part:IsA("Pants") or part:IsA("Shirt") then
part:Destroy()
end
end
local mesh : SpecialMesh = char.Head:FindFirstChild("Mesh")
if mesh then
if mesh.Scale.Magnitude <= Vector3.one.Magnitude then
mesh:Destroy()
mesh = Instance.new("SpecialMesh")
mesh.Name = "fixed mesh"
mesh.Scale = Vector3.one*1.25
mesh.MeshType = Enum.MeshType.Head
mesh.Parent = char.Head
end
end
local pant = serverStorage.Accessories.PHANTOM.Pants:Clone()
pant.Parent = char
local shirt = serverStorage.Accessories.PHANTOM.Shirt:Clone()
shirt.Parent = char
local glasses = serverStorage.Accessories.PHANTOM.Glasses:Clone()
local gilet = serverStorage.Accessories.PHANTOM.Gilet:Clone()
glasses.Parent = char
gilet.Parent = char
end)
local mesh = char.Head:FindFirstChildWhichIsA("SpecialMesh")
if mesh then
mesh.Scale = Vector.new(1.25,1.25,1.25)
mesh.MeshType = Enum.MeshType.Head
end
Awesome! Also as a suggestion, make sure that you run your code on the server and not the client unless it’s a singleplayer game since otherwise other players will appear uniform-less for you.