Hello, I have just made this script but when it ends, it just stays on the last message and never goes away..
Please can someone help? :)
Thanks!
001 | local p = Instance.new( "Hint" ,game.Workspace) |
002 |
003 | function onClick() |
004 | p.Text = 90 |
005 | Wait ( 1 ) |
006 | p.Text = 89 |
007 | Wait ( 1 ) |
008 | p.Text = 88 |
009 | Wait ( 1 ) |
010 | p.Text = 87 |
011 | Wait ( 1 ) |
012 | p.Text = 86 |
013 | Wait ( 1 ) |
014 | p.Text = 85 |
015 | Wait ( 1 ) |
Just a small side note onto both question and answer. You can actually simplify the lines of code in this script. This is just in-case you want to use a simplified version.
01 | local p = Instance.new( "Hint" ,game.Workspace) |
02 |
03 | function onClick() |
04 | for countdown = 90 , 0 ,- 1 do |
05 | p.Text = (countdown) |
06 | wait( 1 ) |
07 | end |
08 | p.Text = "The results have been verified!" |
09 | wait( 5 ) |
10 | p:Destroy() |
11 | end |
12 |
13 | script.Parent.ClickDetector.MouseClick:connect(onClick) |
001 | local p = Instance.new( "Hint" ,game.Workspace) |
002 |
003 | function onClick() |
004 | p.Text = 90 |
005 | Wait ( 1 ) |
006 | p.Text = 89 |
007 | Wait ( 1 ) |
008 | p.Text = 88 |
009 | Wait ( 1 ) |
010 | p.Text = 87 |
011 | Wait ( 1 ) |
012 | p.Text = 86 |
013 | Wait ( 1 ) |
014 | p.Text = 85 |
015 | Wait ( 1 ) |
Hope this helps!