I have this bag giver script and it doesn’t work, anyone help me with this, sometimes when I load it, I will see it just fall through the world, and then sometimes it will stay on my character, I want a permenant solution to this, anyone help? here is the script.
local BlackBag = game.ServerStorage.Bags.BlackBag
game.Players.PlayerAdded:connect(function(player)
player.CharacterAdded:connect(function(character)
if player:WaitForChild("leaderstats").Bag.Value == 1 then
wait(1.5)
local newRadio = BlackBag:Clone()
newRadio.Parent = character
newRadio.CFrame = character:WaitForChild("UpperTorso").CFrame * CFrame.Angles(0,3.14,6) -- or Torso if you use R6
local weld = Instance.new("Weld")
weld.Part0 = newRadio
weld.Part1 = character:WaitForChild("UpperTorso")
weld.C0 = newRadio.CFrame:inverse()
weld.C1 = character:WaitForChild("UpperTorso").CFrame:inverse()
weld.Parent = newRadio
print("Black Bag Successfully Given")
end
end)
end)
could you post a screenshot of what it should look like?
and a potential issue is that the if then statement is only executed each time the character is (re)loaded, not each time the Bag value changes, and why must the bag value equal 1? what if they have a bit more?