A Roblox Community
Would you like to react to this message? Create an account in a few clicks or log in to continue.

A Roblox Community

A community of Robloxians who want to learn to script and build on Roblox Studio.
 
HomeLatest imagesRegisterLog in
If you're a experienced coder make some tutorials! It would really help the site grow.
Make sure you read the rules(Which can be found by clicking here)
If you're a beginner at coding, try some tutorials.
We have many Moderators/Admins watching this site. Contact them with Questions.
Let us know what your favorite sport is. By clicking here to vote (Click here)
This site is becoming inactive. Lets make it active.
Log in
Username:
Password:
Log in automatically: 
:: I forgot my password
Top posters
blueymaddog
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
naknak
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
Supernapalm
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
m27frogy
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
slayer9365
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
myrco919
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
branefreez
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
ninga95
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
CloneTrooper787
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
raboy117
Simple Button Vote_lcapSimple Button Voting_barSimple Button Vote_rcap 
Top posting users this month
No user
Latest topics
» Where to go from here.
Simple Button EmptySeptember 14th 2020, 1:20 pm by MrNicNac

» Send me an Email
Simple Button EmptySeptember 14th 2020, 1:16 pm by MrNicNac

» [v1.6.0.0] Lua Script Obfuscator [No Bytecode]
Simple Button EmptyJuly 6th 2015, 7:38 pm by m27frogy

» New Site Possibly
Simple Button EmptyJuly 6th 2015, 4:16 pm by m27frogy

» Ambassador!
Simple Button EmptyApril 15th 2015, 11:40 pm by naknak

» Boop - Tag
Simple Button EmptyApril 13th 2015, 9:46 pm by naknak

» Vip Class Script
Simple Button EmptyApril 13th 2015, 4:54 pm by naknak

» Who's active?!
Simple Button EmptyApril 13th 2015, 4:52 pm by naknak

» Genesis Point
Simple Button EmptyJuly 17th 2014, 7:04 pm by branefreez

» Reward System
Simple Button EmptyJuly 17th 2014, 5:41 am by m27frogy

» Script Request
Simple Button EmptyJuly 10th 2014, 11:43 am by naknak

» local scripts?
Simple Button EmptyJuly 10th 2014, 11:39 am by naknak

» Project: Reconstruction [Died]
Simple Button EmptyJuly 10th 2014, 11:36 am by naknak

» Hi. I am new here
Simple Button EmptyApril 26th 2014, 4:01 pm by altshiftkey

» What's your favorite sport?
Simple Button EmptyJanuary 1st 2014, 2:13 pm by m27frogy

» FlashLight Script
Simple Button EmptyJanuary 1st 2014, 2:11 pm by m27frogy

» Gun Making! [READ DESC]
Simple Button EmptyJanuary 1st 2014, 2:10 pm by m27frogy

» Hi, I am new here!
Simple Button EmptyNovember 26th 2013, 3:33 pm by Keanu73

» Improve Coding
Simple Button EmptyOctober 26th 2013, 1:12 pm by pook03

» Simple Button
Simple Button EmptySeptember 1st 2013, 6:19 pm by branefreez


 

 Simple Button

Go down 
2 posters
AuthorMessage
recnic
Novice Scripter
Novice Scripter
recnic


Posts : 2
Join date : 2013-06-20

Simple Button Empty
PostSubject: Simple Button   Simple Button EmptyJune 20th 2013, 6:53 am

Code:
local button = script.Parent
function hit()
   
   print("hit")
      
end
script.Parent.Touched:connect(hit)
Back to top Go down
branefreez
Intermediate Scripter
Intermediate Scripter
branefreez


Posts : 143
Join date : 2012-07-14

Simple Button Empty
PostSubject: Re: Simple Button   Simple Button EmptySeptember 1st 2013, 6:19 pm

That would only run when you touch the button. If you want it to only run when clicked put a ClickDetector in it and put the following script in it:
Code:
button = script.Parent button.ClickDetector.MouseClick:connect(function(playerWhoClicked)
  print("Clicked");
end)
Back to top Go down
http://www.roblox.com/User.aspx?ID=22724483
 
Simple Button
Back to top 
Page 1 of 1

Permissions in this forum:You cannot reply to topics in this forum
A Roblox Community :: Tutorials and Resources :: Free Scripts-
Jump to: