|
| 13 Mar 2013 03:54 PM |
| I wanna do the kill script to kill like lava checkers in obbies. |
|
|
| Report Abuse |
|
|
UnAdmin
|
  |
| Joined: 10 Jul 2012 |
| Total Posts: 4706 |
|
|
| 13 Mar 2013 03:58 PM |
In response to this thread I say,
script.Parent.Touched:connect(function(hit) local human = hit.Parent:findFirstChild("Humanoid") if human then human.Health = 0 end end)
Big head master race. |
|
|
| Report Abuse |
|
|
velibor
|
  |
| Joined: 24 Nov 2009 |
| Total Posts: 1003 |
|
|
| 13 Mar 2013 03:59 PM |
1) Create a function called 'Kill with a Parameter called 'Obj''
function Kill(Obj) end
2) Create a Event that triggers our function
function Kill(Obj) end
script.Parent.Touched:connect(function(Obj) Kill(Obj) end)
3) Let's write our main function. We need to check the next : 1) Do we have a Player, is he alive ?
-- This is your job ;-) (I helped you out a lot)
Advice : Check or the Player exist in Game.Players and has a Humanoid in his Character.
|
|
|
| Report Abuse |
|
|
| |
|