I have a local script in the starterpack that puts a random weapon from a folder in replicated storage called "Weapons" but the weapons don't work when you spawn, the problem isn't in the weapon script because they do work when they are just in the starterpack
code:
Weapons = game.ReplicatedStorage.Weapons:GetChildren()
local Weapon = Weapons[math.random(1,#Weapons)]:Clone()
Weapon.Parent = game.Players.LocalPlayer.Backpack

8 comments
Line 11 Weapons is underlined and it does not work
Shouldn't it be a variable?
Also should It be a remote event or a bindable event?
remote event, do "function RWeapon(player)" without local and "local weapons = game.ReplicatedStorage.Weapons:GetChildren()
error code: 15:29:35.063 - Requested module experienced an error while loading
dont remove local on function
I fixed it thank you alot
np