generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Re: Increase health script

Previous Thread :: Next Thread 
kidchaos24 is not online. kidchaos24
Joined: 02 Feb 2011
Total Posts: 169
17 Oct 2015 12:29 AM
Reached a stalemate with this script...
Any suggestions as to how to fix it?
As always thank you in advance scripters!

local Player= game.Players.LocalPlayer
local defaulthp= Player.humanoid.Maxhealth
local i=1
while true do
wait (1)
if i==1 then
maxhealth = defaulthp + 100*Player.leaderstats.Level.Value
end
end
Report Abuse
alphaboy299 is not online. alphaboy299
Joined: 15 Jun 2013
Total Posts: 1496
17 Oct 2015 12:33 AM
ocal Player= game.Players.LocalPlayer.Character
local defaulthp= Player.humanoid.Maxhealth
local i=1
while true do
wait (1)
if i==1 then
maxhealth = defaulthp + 100*Player.leaderstats.Level.Value
end
end
Report Abuse
kidchaos24 is not online. kidchaos24
Joined: 02 Feb 2011
Total Posts: 169
17 Oct 2015 01:12 AM
For some odd reason this script will not work. It doesn't return an error either. Any idea what might be the problem?
Report Abuse
SwagCuzYolo is not online. SwagCuzYolo
Joined: 31 Oct 2013
Total Posts: 1224
17 Oct 2015 01:16 AM
When you save maxhealth, it's saving the value. Do humanoid.MaxHealth =
Report Abuse
alphaboy299 is not online. alphaboy299
Joined: 15 Jun 2013
Total Posts: 1496
17 Oct 2015 01:16 AM
If you're talking about the one I just posted then it has a 'l' missing.

Also if may not be working since the script is prob executed before the player's character is loaded.
Report Abuse
SwagCuzYolo is not online. SwagCuzYolo
Joined: 31 Oct 2013
Total Posts: 1224
17 Oct 2015 01:18 AM
local Player= game.Players.LocalPlayer
local defaulthp= Player.Character.Humanoid.Maxhealth
local i=1
while true do
wait (1)
if i==1 then
Player.Character.Humanoid.MaxHealth = defaulthp + 100*Player.leaderstats.Level.Value
end
end

This is what you want
Report Abuse
kidchaos24 is not online. kidchaos24
Joined: 02 Feb 2011
Total Posts: 169
17 Oct 2015 01:33 AM
Awesome scripting skills guys! Thank you both for your help.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image