|
YUNO WORK?! Posted: 22 Mar 2012 09:56 AM |
No output was outputted in the making of this script: function onTouched(hit) char = hit.Parent.Character ha = script.Parent["BillboardGui"].Something normal = ha.Text if char ~= nil then ha.Text = "I said DO NOT TOUCH!" wait(2) ha.Text = "YUNOLISTEN!?!?" wait(2) z = char:children() for x = 1,#z do if z[x]:IsA("BasePart") then for num, 0,1,.1 do z[x].Transparency = num wait(.1) end end end h.Health = 0 ha.Text = normal end end script.Parent.Touched:connect(onTouched)
|
|
|
| Post ReplyReport Abuse |
|
| |
|
Re: YUNO WORK?! Posted: 22 Mar 2012 02:15 PM |
-- Hope this works.
script.Parent.Touched:connect(function(hit) if hit.Parent and hit.Parent.Character then char = hit.Parent.Character ha = script.Parent["BillboardGui"].Something if char ~= nil then ha.Text = "I said DO NOT TOUCH!" wait(2) ha.Text = "YUNOLISTEN!?!?" wait(2) z = char:GetChildren() for x = 1, #z do if z[x]:IsA("BasePart") then for num, 0, 1, .1 do z[x].Transparency = num wait(.1) end end end hit.Parent.Health = 0 ha.Text = "normal" end)
-- Some of your for loops were rather annoying, due to their.. Messiness. Hopefully I solved your problem. |
|
|
| Post ReplyReport Abuse |
|