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 » Scripters
Home Search
 

Re: How do I Get This This Script To Work?

Previous Thread :: Next Thread 
MyDucklsOnQuack is not online. MyDucklsOnQuack
Joined: 27 Mar 2013
Total Posts: 1756
15 Jun 2017 07:21 PM
When someone steps on it I want the part that stepped on it to be put in message form then delete it self after 3 seconds

Leg =script.Parent

Leg.Touched:connect(function(Blox)
print(Blox)
local m =Instance.new("Message", workspace)
m.Text(Blox)
wait(3)
m:Remove()

end)
Report Abuse
MyDucklsOnQuack is not online. MyDucklsOnQuack
Joined: 27 Mar 2013
Total Posts: 1756
15 Jun 2017 07:23 PM
+ 1
Report Abuse
Jonah13249 is not online. Jonah13249
Joined: 09 Oct 2009
Total Posts: 2105
15 Jun 2017 07:28 PM
Leg =script.Parent


Leg.Touched:connect(function(Blox)
print(Blox)
local m =Instance.new("Message", workspace)
m.Text = Blox.Name
wait(3)
m:Remove()
end)

Report Abuse
Jonah13249 is not online. Jonah13249
Joined: 09 Oct 2009
Total Posts: 2105
15 Jun 2017 07:31 PM
However, I do think you should put a debounce variable because if you step on it, it will fill up your screen with messages. You might want to do it one at a time.

Leg =script.Parent
debounce = false
Leg.Touched:connect(function(Blox)
if debounce then
return
else
debounce = true
print(Blox)
local m =Instance.new("Message", workspace)
m.Text = Blox.Name
wait(3)
m:Remove()
end
debounce = false
end)
Report Abuse
HoodedBlack is not online. HoodedBlack
Joined: 04 May 2013
Total Posts: 2226
15 Jun 2017 07:54 PM
this wont fix it but use Destroy, not remove
Report Abuse
Jonah13249 is not online. Jonah13249
Joined: 09 Oct 2009
Total Posts: 2105
15 Jun 2017 07:55 PM
True, Remove is deprecated. Use Destroy.
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • 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