|
| 02 Dec 2015 04:23 PM |
Ok so im currently learning scripting and heres the script: debounce = false function onTouched(hit) if debounce == false then debounce = true msg = Instance.new("Message", Workspace) msg.Text = "Hi im Metology(My main)." wait(3) msg:Destroy() debounce = false end |
|
|
| Report Abuse |
|
|
Bagel4536
|
  |
| Joined: 11 Sep 2014 |
| Total Posts: 40 |
|
|
| 02 Dec 2015 04:24 PM |
| Is there a problem with it? |
|
|
| Report Abuse |
|
|
|
| 02 Dec 2015 04:25 PM |
| I just need to know anyway to simplify it. |
|
|
| Report Abuse |
|
|
QJD1996
|
  |
| Joined: 20 Jan 2009 |
| Total Posts: 1472 |
|
|
| 02 Dec 2015 04:33 PM |
| That's as simple as you can make it.. atleast I think? |
|
|
| Report Abuse |
|
|
cgjnm
|
  |
| Joined: 22 Dec 2011 |
| Total Posts: 2347 |
|
|
| 02 Dec 2015 04:36 PM |
That's pretty much the simplest way it gets...
db = false script.Parent.Touched:connect(function(hit) if db == false then db = true local msg = Instance.new("Message",workspace) msg.Text = "Hi I'm Metology (my main)." wait(3) msg:Destroy() end end)
-- I did it again because of "im", "Workspace" and also the local |
|
|
| Report Abuse |
|
|
|
| 02 Dec 2015 04:43 PM |
| Ok thanks. Just needed review. |
|
|
| Report Abuse |
|
|
025110
|
  |
| Joined: 23 Nov 2012 |
| Total Posts: 57661 |
|
|
| 02 Dec 2015 04:56 PM |
d = false function t(h) if not d then d = true m = Instance.new("Message", workspace) m.Text = "Hi im Metology(My main)." wait(3) msg:Destroy() d = false end
|
|
|
| Report Abuse |
|
|
| |
|
supernavo
|
  |
| Joined: 21 Jul 2012 |
| Total Posts: 1850 |
|
|
| 02 Dec 2015 06:54 PM |
| You were missing an end and nothing was calling the script. |
|
|
| Report Abuse |
|
|
supernavo
|
  |
| Joined: 21 Jul 2012 |
| Total Posts: 1850 |
|
|
| 02 Dec 2015 06:55 PM |
| My bad... nothing was calling the function* -_- |
|
|
| Report Abuse |
|
|