Question

I basically want a method I can call that will set a boolean to true for 2 seconds, then reset it to false. How would I do this?

I'm using the Slick library which is dependent on LWJGL.

Was it helpful?

Solution

You want to look at the Timer class.

OTHER TIPS

check out the ScheduledExecutorService and the method schedule()

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top