Gladii
|
  |
| Joined: 10 Mar 2012 |
| Total Posts: 1713 |
|
|
| 20 Dec 2014 01:00 PM |
| How do I identify if the parent has been hit when an explosion? |
|
|
| Report Abuse |
|
|
|
| 20 Dec 2014 01:03 PM |
local Create = LoadLibrary("RbxUtility").Create
local function explode(pos) local explosion = Create("Explosion")({ BlastRadius = 5, BlastPressure = 0, Position = pos }) explosion.Hit:connect(function(hit) print("hit") end) end
explode(workspace.Player1.Torso.Position) |
|
|
| Report Abuse |
|
|
Gladii
|
  |
| Joined: 10 Mar 2012 |
| Total Posts: 1713 |
|
|
| 20 Dec 2014 01:05 PM |
Is that just for finding if hit with the explosion?
|
|
|
| Report Abuse |
|
|
|
| 20 Dec 2014 01:15 PM |
Use .Hit event to find a part that it hit
explosion.Hit:connect(function(part)
print(part.Name.." was affected by an explosion!")
end) |
|
|
| Report Abuse |
|
|
Gladii
|
  |
| Joined: 10 Mar 2012 |
| Total Posts: 1713 |
|
| |
|
Gladii
|
  |
| Joined: 10 Mar 2012 |
| Total Posts: 1713 |
|
|
| 20 Dec 2014 01:46 PM |
| I can't have 1 function within another. |
|
|
| Report Abuse |
|
|