--What I want is when the event is fired it will make a clone of the gui and put it in the players playergui but not even the function called when the event is fired will work. please help--
Server:
local remote = game.ReplicatedStorage.Remotes.pp
local this = script.Parent
this.CD.MouseClick:Connect(function(plrc)
remote:FireClient(plrc,"EmeraldAxe")
end)
Local:
local remote = script.Parent.pp
local stats = game.ReplicatedStorage.Axestats
local hasgui = false
local lplr = game.Players.LocalPlayer
local function makegui(plr1,axe,price)
print("function started")
local gui = game.ReplicatedStorage.PurchaseGUI
local ngui = gui:Clone()
ngui.Parent = lplr.PlayerGui
ngui.f1.bl1.Text = ("Buy" .. axe .. "for" .. " $" .. price .. "?")
end
remote.OnClientEvent:Connect(function(plr,axe)
print("remote fired")
if axe == "EmeraldAxe" then
print("emerald fired")
hasgui = true
local ap = stats.EmeraldAxe.Price
makegui(plr,axe,ap)
end
end)

1 comment
use a remote event instead of a bindable