public interface ILoop extends ILaunchable
Modifier and Type | Method and Description |
---|---|
void |
attach(IUpdateable updatable)
Attaches the update method of the specified IUpdatable instance to be called
every tick.
|
void |
detach(IUpdateable updatable)
Detaches the specified instance from the game loop.
|
long |
getDeltaTime()
Gets the total time in milliseconds that passed since the last tick.
|
double |
getProcessTime()
Gets the actual process time in milliseconds that was required during the last tick.
|
int |
getTickRate()
Gets the rate at which this loop performs its updates.
|
long |
getTicks()
Gets the total amount of ticks performed by this loop since it was started.
|
start, terminate
void attach(IUpdateable updatable)
updatable
- The instance that will be registered for the update event.void detach(IUpdateable updatable)
updatable
- The instance that will be unregistered for the update event.long getTicks()
ILaunchable.start()
int getTickRate()
long getDeltaTime()
getProcessTime()
double getProcessTime()
getDeltaTime()