Quote:
Originally Posted by WizenedEE
I think with the timers, you have to define them outside of the loop or else they'll get recreated each time and lose their value.
Like:
Code:
Timer timer1 = new Timer();
while (...) {
// use timer1
}
not
Code:
while(...) {
Timer timer1 = new Timer();
// use timer1
}
In c++ you could make it static, but that doesn't exist in Java:
Code:
while(...) {
static Timer timer1 = new Timer();
// use timer1
}
|
yeah, that might be a problem. Thanks