local com = ";remove gear" players = game.Players:GetChildren() game.Players.PlayerAdded:connect(function(player) if player:GetRankInGroup(42142) >= 7 then player.Chatted:connect(function(message) if message == com then game.players.StarterGear:ClearAllChildren() end end) end end) local com2 = ";add SMG" players = game.Players:GetChildren() game.Players.PlayerAdded:connect(function(player) if player:GetRankInGroup(42142) >= 7 then player.Chatted:connect(function(message) if message == com2 then game.ServerStorage.Tools.SMG:Clone().Parent = game.players.StarterGear end end) end end)
On the ;remove gear command it removes starter gear. On the ;add SMG gear it adds the SMG gun to the starter gear. These commands don't work. Why is this?
Try to make it where it insert the tool into the backpack. Here's a code:
game.ServerStorage.Tools.SMG:Clone().Parent = game.Players.LocalPlayer.Backpack
If that doesn't work, then try capitalizing "players". You say game.players, that might not work because it's case-sensitive.
game.players.StarterGear --game.Players.StarterGear