generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripting Helpers
Home Search
 

Re: How to make a Killing Block Script

Previous Thread :: Next Thread 
trevorandshaesn1 is not online. trevorandshaesn1
Joined: 29 Apr 2012
Total Posts: 1411
08 Oct 2012 04:55 PM
The TAS SN1 is always right! To make a killing block Script, put a script in a block, and type this.

1. function onTouch(part)
2. local humanoid = part.Parent:findFirstChild("Humanoid")
3. if (humanoid ~= nil) then-- if a humanoid exists, then
4. humanoid.Health = 0-- Damage the humanoid
5. end
6. end
7.
8. script.Parent.Touched:connect(onTouch)

And if you're in build mode, you'll have to save and leave, and when you come back on, touch it, and you will hear an "Ouugghhh" sound effect. If you're in edit mode, save and leave, come back on, build or play, and you will hear an "Ouugghhh" sound effect.

Congrats! You just made a script!

Thnx! Trevor
Report Abuse
AdvorsusDuo is not online. AdvorsusDuo
Joined: 17 May 2012
Total Posts: 5265
08 Oct 2012 04:59 PM
>Workspace.Part.Script.1: unexpected symbol near 'onTouch'
Report Abuse
blackboy167thst is not online. blackboy167thst
Joined: 22 Jul 2011
Total Posts: 2468
08 Oct 2012 05:04 PM
script.Parent.Touched:connect(function(hit)
if hit.Parent:findFirstChild("Humanoid") then
hit.Parent.Humanoid.Health = 0
end
end)
Report Abuse
trevorandshaesn1 is not online. trevorandshaesn1
Joined: 29 Apr 2012
Total Posts: 1411
08 Oct 2012 05:43 PM
mine's better
Report Abuse
hamsterloverboy3 is not online. hamsterloverboy3
Joined: 26 Jul 2012
Total Posts: 185
08 Oct 2012 05:44 PM
No, black's script is better. You do a useless if statement..
Report Abuse
hamsterloverboy3 is not online. hamsterloverboy3
Joined: 26 Jul 2012
Total Posts: 185
08 Oct 2012 05:45 PM
Nevermind about the if statement...

But do this:

humanoid.MaxHealth = nil -- (Better way of killing)
Report Abuse
thedeathmaster01 is not online. thedeathmaster01
Joined: 14 Mar 2010
Total Posts: 6331
08 Oct 2012 05:47 PM
@op, No yours is really bad an inefficient, blackboy's script is way better.
Report Abuse
dog456pop248 is not online. dog456pop248
Joined: 24 Aug 2008
Total Posts: 3977
08 Oct 2012 05:49 PM
I understand you might think this helpful, but it would take less effort for someone to look at a script in a free model.
Report Abuse
dog456pop248 is not online. dog456pop248
Joined: 24 Aug 2008
Total Posts: 3977
08 Oct 2012 05:50 PM
Or infeact, just use a free model.
Report Abuse
dog456pop248 is not online. dog456pop248
Joined: 24 Aug 2008
Total Posts: 3977
08 Oct 2012 06:02 PM
@op "my script is better"

I found this EXACT script in a free model seeing if you do it better. The tags are worded exactly the same, with the same punctuation. http://www.roblox.com/Killing-Lava-Brick-FREE-item?id=9569681

Report Abuse
thedeathmaster01 is not online. thedeathmaster01
Joined: 14 Mar 2010
Total Posts: 6331
08 Oct 2012 06:03 PM
@dog, typical stupid OBC op

~I'm a prosperous superhero!~
Report Abuse
corto713 is not online. corto713
Joined: 12 Dec 2009
Total Posts: 962
08 Oct 2012 06:05 PM
@dog, lol nice you just owned this wanna be scripter XD
Report Abuse
dog456pop248 is not online. dog456pop248
Joined: 24 Aug 2008
Total Posts: 3977
08 Oct 2012 06:09 PM
OP's description:

"Hey Everyone! You can call me Trev!
Stop calling me a girl cuz' I'm not a girl! I'm a boy!"

Wut

"Stop calling me a girl cuz' I'm not a girl! I'm a boy!"

What.

"I'm a boy!"

"I'm a boy!"

"I'm a boy!"
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image