I’m in the process of creating a game which involves players setting up their own clothing stores, changing their mannequins’ clothes to the ones of their desire, ideally being the shirts they have created.
I am currently having problems getting the right asset ids due to them being automatically updated whenever you put them in the ‘‘ShirtTemplate’’ property.
I know there is a solution for this using a normal script, but I am using a LocalScript, because the user should be able to put the ID on a TextBox and then press enter, as in this script i wrote:
--Variables
local TextBox = script.Parent
local Mannequin = workspace.Dummy
--Functions
TextBox.FocusLost:Connect(function(enterPressed)
if enterPressed then
Mannequin.Pants.PantsTemplate = "http://www.roblox.com/asset/?id=" .. TextBox.Text
end
end)
It does work, however, it doesn’t auto update to the actual asset id, and is instead left blank.
Thank you for your time,
Piero.