Im trying to set the health and armor of a job and currently its only setting the armor. This is what I have:
[CODE]
PlayerSpawn = function(ply) ply:SetHealth(150) return CLIENT end,
PlayerDeath = function(ply) ply:SetHealth(0) return CLIENT end,
PlayerSpawn = function(ply) ply:SetArmor(100) return CLIENT end,
PlayerDeath = function(ply) ply:SetArmor(0) return CLIENT end,[/CODE]
Wrong section, try the actual garrysmod lua section
You can't define two keys of the same name in a table. Put both Set calls in one PlayerSpawn/PlayerDeath key and don't return anything.
How would that look?
[code]PlayerSpawn = function(ply) ply:SetHealth(150) ply:SetArmor(100) end,[/code]
You don't need the PlayerDeath stuff you put since the game automatically handles resetting health and armor there.
ok thank you
Sorry, you need to Log In to post a reply to this thread.