Glixtr
|
  |
| Joined: 03 Jul 2011 |
| Total Posts: 174 |
|
|
| 20 May 2016 06:23 AM |
local Player = game.Players.LocalPlayer local Avatar = Player.Character local Humanoid = Avatar:WaitForChild("Humanoid") local cam = game.Workspace.CurrentCamera
Humanoid.Health.Changed:connect(function() if (Humanoid.Health <= 25) and (Humanoid.Health >= 20) then print("Low health!") end end)
Local script The output says this: "Workspace.Player1.HealthEffects:6: attempt to index field 'Health' (a number value)"
I can tell it's an error, and I don't know how to fix it.
|
|
|
| Report Abuse |
|
xshot23
|
  |
| Joined: 17 Oct 2014 |
| Total Posts: 4873 |
|
|
| 20 May 2016 06:56 AM |
| Humanoid.health.changed is ur problem |
|
|
| Report Abuse |
|
chimmihc
|
  |
| Joined: 01 Sep 2014 |
| Total Posts: 17143 |
|
|
| 20 May 2016 07:28 AM |
Humanoid.HealthChanged:connect(function()
|
|
|
| Report Abuse |
|