How do I create a script that chooses one random player and gives them a sword, more health and walkspeed?
Also, it needs to teleport them to a position.
Here are some of the basics. You'll have to edit some things in order for it to work, but this is what it would look like for the most part.
function ChoosePlayer() -- declare function local players = Game:GetService("Players"):GetPlayers() -- player list local plr = players[math.random(#players)] -- random player local hum = plr.Character:WaitForChild("Humanoid") -- declare variable for Humanoid Game:GetService("ServerStorage"):FindFirstChild("Sword"):Clone().Parent = plr:FindFirstChild("Backpack") -- give sword hum.MaxHealth = 200 hum.Health = (hum.Health / 100) * hum.MaxHealth -- heal the character proportionally hum.WalkSpeed = 32 -- change walkspeed plr.Character:MoveTo(Vector3.new(0, 0, 0)) -- teleport return plr end local chosenPlr = ChoosePlayer() -- call function local msg = Instance.new("Message", Workspace) msg.Text = chosenPlr.Name .. " was chosen!" Game:GetService("Debris"):AddItem(msg, 3)