what i need do to in StarterPlayerScripts for to do inf health or something
how i need to do health only one player? [BEGGINER]
3 answers
Your question is very non-descriptive, so I assuming you want to change people's health. Best way to do this is a ServerScript in ServerScriptService, in which waits for a Character to be added to modify the Humanoid.
-- [[ SERVICES ]] --
Players = game:GetService('Players')
-- [[ VARIABLES ]] --
local healthValue = 9999 -- how much you want the health to be modified to, if you want them **godded**, change to **math.huge**
-- [[ MAIN SCRIPT ]] --
Players.PlayerAdded:Connect(function(Player) -- Fire function when player joins.
Player.CharacterAdded:Connect(function(Character) -- Fire function when character is added to workspace
local Humanoid = Character:WaitForChild('Humanoid') -- wait for the humanoid to load in
if Player.Name == 'Noob123' then
Humanoid.MaxHealth = healthValue -- change maxhealth first, always
Humanoid.Health = healthValue -- now change the health
end
end)
end)
5 comments
can u say how to do it only for one player but in all be normal health
but it works perfect thanks
game.Workspace.wattome.Humanoid.MaxHealth = 1500
That's stupid, all you need is to put a Humanoid named StarterHumanoid with the properties you want and players will always have that humanoid
I have edited it accordingly for one player. @programmer. I have done it server side to prevent exploiters, since they can abuse LocalScripts.
Hey hello there!
There a script to make it changes everyone's health become infinite.
This is the script, place it anywhere you like!
script.Parent = workspace
game.Players.PlayerAdded:Connect(function(plr)
plr:FindFirstChild("Humanoid").MaxHealth = 99999999999999
plr:FindFirstChild("Humanoid").Health = 99999999999999
end)
Hope I helped, bye!
If my code was incorrect, comment below! Bye:)
5 comments
thanks for fast responding
Yeah, this is wrong.
That doesn't work. do plr:FindFirstChild("Character").Humanoid.MaxHealth = 999999999999
That doesn't work either
That's stupid, all you need is to put a Humanoid named StarterHumanoid with the properties you want and players will always have that humanoid
can somebody say how to do it only for one player
This discussion is preserved as it was. New answers, comments, and votes are closed.

2 comments
Can your question be more descriptive?
^