So, I have this figure in which you talk to him to buy the weapons. Now when you buy it you receive it fine, but when you die or reset, it's gun and to get it again you have to buy it again. How can I fix this? Thanks!
script.Parent.DialogChoiceSelected:connect(function(player, choice) if (choice:findFirstChild("Cost")) then if (player.leaderstats.Money.Value >= choice.Cost.Value) then if (game.Lighting:findFirstChild(choice.Name)) then player.leaderstats.Money.Value = player.leaderstats.Money.Value - choice.Cost.Value local gun = game.Lighting:findFirstChild(choice.Name):clone() if (gun.className == "Panzerfaust") then gun.Parent = player.Backpack else gun.Parent = player.Character end end end end end)
script.Parent.DialogChoiceSelected:connect(function(player, choice) if (choice:findFirstChild("Cost")) then if (player.leaderstats.Money.Value >= choice.Cost.Value) then if (game.Lighting:findFirstChild(choice.Name)) then player.leaderstats.Money.Value = player.leaderstats.Money.Value - choice.Cost.Value local gun = game.Lighting:findFirstChild(choice.Name):clone() if (gun.className == "Panzerfaust") then gun.Parent = player.StarterGear else gun.Parent = player.Character end end end end end)
StarterGear Will hold if they reset