local axe = "Draco Axe"
local price = 30
local currency = "Gems"
script.Parent.ClickDetector.MouseClick:Connect(function(plr)
wait()
local GuiClone = game:WaitForChild("ServerStorage"):FindFirstChild("limitedEditionGui"):Clone()
Gui:WaitForChild("Axe").Value = axe
Gui:WaitForChild("Price").Value = price
Gui:WaitForChild("Currency").Value = currency
Gui.Parent = game.StarterGui
end)
U should use :Clone() if u are trying to put the Gui in Player's Gui.
Also
Gui:WaitForChild("Axe").Value = axe
Gui:WaitForChild("Price").Value = price
Gui:WaitForChild("Currency").Value = currency
U shouldnt try to use Guis to label the Name of the Axe, Price or Currency.
Use a TextLabel for the Name of the axe and TextButton for the price(30 Gems) instead so that when the Gui is cloned into the Player's Gui, it is already there and so u wont have to change anything.
Reason for TextButton is because u can just put a LocalScript, which is included in the Gui when its cloned, into the TextButton and when a player tries to buy the axe, he/she can just click the TextButton and buy it. Also, with TextButton, u can label the price of the axe as well.
IMPORTANT [EDIT]
Also dude u can just put the Gui into StarterGui straight, so when the player spawns, u dont need to clone anything from ServerStorage and it will be in Player's Gui, just change the Value to TextLabel and TextButton.
I hope this helps!
If theres any error, comment below.
7 comments
Put the script you tried in your message.
done
you're trying to clone a GUI from server storage. use replicated storage if you're dealing with client sided stuff.
ClickDetector allows Server Sided events.
And no that didn't work, it returned the same error.
i didnt say that was your only issue, just that you should not use server storage for GUI's.
uh, i've done it before and it worked perfectly.