Rene
2008-05-28 19:01:31 UTC
Hello to all,
I am doing a course in C++ and we use BC6++. Now we had to make a class to
paint a traffic light and a program that asks this class to do so. It also
should have a button that makes the light go green -> yellow -> red ->
green -> asf... , one step with each press. No problem so far.
However, I would like to add a feature to make it a bit more luxurious. In
my country, when traffic is low (that means, almost never :-( ), the light
will only show a flashing yellow. I would like to add a button to put my
light into that modus. Is there a way to do this without being "stuck" in
that function, I mean, something in the background that will continu to turn
on and off the yellow light without having to use wait loops?
Thank You very much in advance!
Yours sincerely,
Rene
P.S. I do not ask for a full solution, I would already be very happy if You
might give me some keywords what to look for on the web.
I am doing a course in C++ and we use BC6++. Now we had to make a class to
paint a traffic light and a program that asks this class to do so. It also
should have a button that makes the light go green -> yellow -> red ->
green -> asf... , one step with each press. No problem so far.
However, I would like to add a feature to make it a bit more luxurious. In
my country, when traffic is low (that means, almost never :-( ), the light
will only show a flashing yellow. I would like to add a button to put my
light into that modus. Is there a way to do this without being "stuck" in
that function, I mean, something in the background that will continu to turn
on and off the yellow light without having to use wait loops?
Thank You very much in advance!
Yours sincerely,
Rene
P.S. I do not ask for a full solution, I would already be very happy if You
might give me some keywords what to look for on the web.