|
| 20 Jul 2015 12:32 PM |
function() if script.Parent.Health = 0 then Juff = Instance.new("Part") Juff.Colour = "Red" end end
--Made by ShieldOfStone |
|
|
| Report Abuse |
|
|
Clxver
|
  |
| Joined: 19 Oct 2014 |
| Total Posts: 727 |
|
|
| 20 Jul 2015 12:32 PM |
function juff() if script.Parent.Health == 0 then local juff = Instance.new("Part", game.Workspace) juff.BrickColor = BrickColor.new("Bright red") end end
juff() |
|
|
| Report Abuse |
|
|
| |
|
Clxver
|
  |
| Joined: 19 Oct 2014 |
| Total Posts: 727 |
|
|
| 20 Jul 2015 12:33 PM |
| Oh wait, I think you should rename the local variable inside of the function. I don't know if that would affect the function itself because it's the same name as the function. Sorry. |
|
|
| Report Abuse |
|
|
| |
|
rayk999
|
  |
| Joined: 18 Feb 2011 |
| Total Posts: 4705 |
|
|
| 20 Jul 2015 12:39 PM |
| I don't think it'll matter since it'll overwrite the global variable (the function) |
|
|
| Report Abuse |
|
|
KAAK82
|
  |
| Joined: 06 May 2014 |
| Total Posts: 1166 |
|
|
| 21 Jul 2015 07:11 AM |
function test() if script.Parent.Health == 0 then juff = Instance.new('Part', workspace) juff.BrickColor = BrickColor.new('Red') end end |
|
|
| Report Abuse |
|
|
fret13103
|
  |
| Joined: 15 Mar 2010 |
| Total Posts: 881 |
|
|
| 21 Jul 2015 07:26 PM |
local humanoid = script.Parent:findFirstChild("Humanoid")
humanoid.HealthChanged:connect(function(health) Blood() end)
function Blood() if humanoid.Health == 0 then local Blood = Instance.new("Part", Workspace) Blood.Color, Blood.Size = "Red", Vector3.new(1,1,1) end end
--ready to copy+paste, script goes inside character of player. |
|
|
| Report Abuse |
|
|