I'm working on a saving system for my RPG. I've got the script below that is fired by an event.
game.Lighting.ServerEvents.SpawnWeaponShop.T1S1.OnServerEvent:connect(function(Player) game.Players[Player.Name].leaderstats.Gold.Value - 150 local Weapon = game.ReplicatedStorage.ITEMS.BrigandSword:Clone() Weapon.Parent = Player.StarterGear end)
It works in studio, but not in-game. What could I do to make it work in-game?
Hi, there.
Your script is using filtering enabled as seen by you remote event. I do suggest that you clone your weapon in the server script which activates this Server Event since I don't think you can clone in a local script. Also, it seems you have put your weapon into starter gear. I not very sure, but if you are trying to put the weapon into backpack, you should place inside Player.backpack.