Kodewerx
https://www.kodewerx.org/forum/

Small basics help with timers
https://www.kodewerx.org/forum/viewtopic.php?f=24&t=7098
Page 1 of 1

Author:  DarkLegend [ Sun Nov 15, 2009 10:39 am ]
Post subject:  Small basics help with timers

I wrote this:
Code:
Start:
TextWindow.WriteLine(".")
TextWindow.Clear()
Timer.Interval = 1000
TextWindow.WriteLine(" .")
TextWindow.Clear()
Timer.Interval = 1000
TextWindow.WriteLine("  .")
TextWindow.Clear()
Timer.Interval = 1000
Goto start


You can see what I'm trying to do.
The only problem is that it does it really fast. Even when I add more zero's.
Is there any other way to slow it down to about a second?


Edit : This is one of my first scripts, so I'm noob with this.

Author:  HyperHacker [ Mon Nov 16, 2009 12:57 am ]
Post subject:  Re: Small basics help with timers

You've mistaken setting the Timer.Interval attribute for a delay. The timer probably has some kind of callback when the interval passes that you should use. You're also inserting a line into the box, then immediately removing it again.

You might also note what language this is.

Author:  DarkLegend [ Mon Nov 16, 2009 11:30 am ]
Post subject:  Re: Small basics help with timers

I want it to clear everything, I just want to delay the clearing and the showing of the dots.

EDIT: I used small basic's. It's like a learner version of visual basics.

Author:  HyperHacker [ Mon Nov 16, 2009 10:30 pm ]
Post subject:  Re: Small basics help with timers

But what you're doing is:

1) Draw dots
2) Erase dots
3) Delay
4) Repeat

The dots will only be on the screen for a tiny fraction of a second. Steps 2 and 3 need to be swapped.

That alone won't help though, because you're not actually delaying. You're just repeatedly configuring some timer somewhere to fire at 1000ms intervals.

Author:  DarkLegend [ Tue Nov 17, 2009 10:29 am ]
Post subject:  Re: Small basics help with timers

O.k. then thanks.

But, How do I delay the dots from showing up?

Author:  HyperHacker [ Tue Nov 17, 2009 9:27 pm ]
Post subject:  Re: Small basics help with timers

Look up how to actually use the timer instead of just changing its attributes.

Author:  DarkLegend [ Wed Nov 18, 2009 11:59 am ]
Post subject:  Re: Small basics help with timers

Ok, I'll try and see If google can do that, hopefully it can.

Page 1 of 1 All times are UTC - 8 hours [ DST ]
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/