hello , i want add a accessory remover inside this script at line 20 but i don't know how to do this can you help me please ? thanks you !
script (line 20)
local function ChangeClothes(char, shirtid, pantsid)
local shirt = char:FindFirstChildOfClass"Shirt" or Instance.new("Shirt", char)
local pants = char:FindFirstChildOfClass"Pants" or Instance.new("Pants", char)
shirt.ShirtTemplate = shirtid
pants.PantsTemplate = pantsid
end
local remote = game.ReplicatedStorage.Security
LVL5 = game.ReplicatedStorage["[SCP] Card-L5"]
Flashlight = game.ReplicatedStorage.Flashlight
P90 = game.ReplicatedStorage["P90 TR"]
function remote.OnServerInvoke(player, TeamName)
if #game:GetService("Teams"):FindFirstChild("Security Departement Head"):GetPlayers() == 0 then -- team check
player.TeamColor = BrickColor.new("Really blue") -- Team Change
player:LoadCharacter()
if game.Workspace[player.Name].ClassName == ("Accessory") then
-- I WANT ADD ACCESSORY REMOVER HERE
end
local char = player.Character or player.CharacterAdded:Wait()
ChangeClothes(char, "rbxassetid://129732937", "rbxassetid://175974404") --replace with your desired ids
LVL5:Clone().Parent = game.Players[player.Name].Backpack
Flashlight:Clone().Parent = game.Players[player.Name].Backpack
P90:clone().Parent = game.Players[player.Name].Backpack
else
print ("Team SECU is full") -- team is currently full
end
end

1 comment
https://wiki.roblox.com/index.php?title=API:Class/Humanoid/RemoveAccessories