I made a script for change the Local Player shirt and doesn’t work, please, if you know how to make it work reply this message.
The code:
--Variables:
local P = game.Players.LocalPlayer
local PN = P.Name
local PNS = PN.Shirt
local MarketplaceService = game:GetService("MarketplaceService")
local Players = game:GetService("Players")
local comprar = script.Parent.Comprar
local costeP = script.Parent.CosteP
local nombreP = script.Parent.NombreP
local prenda = script.Parent.Prenda
local productID = 7337672531 -- ID de tu prenda
local CerrarG = script.Parent.CerrarGUI
local probarP = script.Parent.ProbarP
--
--Codigo:
-- Borrar GUI con la " X "
CerrarG.MouseButton1Click:Connect(function()
script.Parent:Destroy()
end)
--
---
-- Mostrar ropa en ImagenLabel:
probarP.MouseButton1Click:Connect(function()
game.Workspace[PNS].ShirtTemplate = "http://www.roblox.com/asset/?id=7337672531"
end)
--
---
--
Yeah, if you know what is the error of " invalid argument #2 (string expected, got nil) " please reply this message.
error:
–