|
| 29 Nov 2015 03:09 AM |
| How would I make a block disappear after taking enough damage? |
|
|
| Report Abuse |
|
|
|
| 29 Nov 2015 03:12 AM |
Assuming you have a health value in the block, and the bomb damages it...
HealthValue.Changed:connect(function() if HealthValue.Value <= 0 then
--One of these. Block:Destroy(); Block.Transparency = 1;
end end)
Enjoying your stay at the Scripters Forum? Join this! http://www.roblox.com/My/Groups.aspx?gid=2582784 |
|
|
| Report Abuse |
|
|
|
| 29 Nov 2015 04:10 AM |
| I can't seem to get it to work, here's a screen shot of how I have it set up. https://i.gyazo.com/5ffd590d149f739b21c1df6595d667a1.png Thanks! |
|
|
| Report Abuse |
|
|
|
| 29 Nov 2015 04:19 AM |
Maybe you should change the body to "Can anyone give me a script" instead of "How"
|
|
|
| Report Abuse |
|
|
| |
|
|
| 29 Nov 2015 04:28 AM |
while true do wait()
if script.Parent.Humanoid.Health <= 0 then script.Parent.Transparency = 0 script.Parent:Destroy() end end |
|
|
| Report Abuse |
|
|
|
| 29 Nov 2015 04:31 AM |
Remove the transparency part, doesnt do nothing
while true do wait()
if script.Parent.Humanoid.Health <= 0 then script.Parent:Destroy() end end
Should work |
|
|
| Report Abuse |
|
|
|
| 29 Nov 2015 05:08 PM |
| Tried and it didn't work, not sure why, It looks fine to me. |
|
|
| Report Abuse |
|
|