local Players = game:GetService("Players") _G.BARRAGEDB = {} Players.PlayerAdded:Connect(function(plr) print(plr) plr = _G.player print(_G.player) --player returns as nil end)
Trying to use the player in different scripts but it returns as nil when i try to set plr to = _G.Player
You’re setting the plr value to _G.player which is nil. I believe you’re trying to set _G.player’s value instead which you can do by just reversing the spots of plr and _G.player like so: _G.player = plr.
plr
_G.player
_G.player = plr
oh my gosh, these simple errors are killing me, thanks again