Interface ILoopTickerFactory
Creates ILoopTicker's.
public interface ILoopTickerFactory
Methods
CreateTicker(TimeSpan, bool, bool, TickerCallback<ILoopTicker>?)
Create a new ticker.
ILoopTicker CreateTicker(TimeSpan periodicDelay, bool invokeImmediately, bool queueOnGameThread, TickerCallback<ILoopTicker>? onTick = null)
Parameters
periodicDelayTimeSpanHow often to invoke the ticker.
invokeImmediatelyboolIf the ticker should be invoked now or wait a period.
queueOnGameThreadboolCallback will always be fired on the game thread (if it exists).
onTickTickerCallback<ILoopTicker>Callback since the event being invoked now would mean you couldn't subscribe to the event first.
Returns
CreateTicker(TimeSpan, TimeSpan, bool, TickerCallback<ILoopTicker>?)
Create a new ticker.
ILoopTicker CreateTicker(TimeSpan initialDelay, TimeSpan periodicDelay, bool queueOnGameThread, TickerCallback<ILoopTicker>? onTick = null)
Parameters
initialDelayTimeSpanHow long to wait to initially invoke the ticker.
periodicDelayTimeSpanHow often to invoke the ticker.
queueOnGameThreadboolCallback will always be fired on the game thread (if it exists).
onTickTickerCallback<ILoopTicker>Callback since the event being invoked now would mean you couldn't subscribe to the event first.
Returns
CreateTicker<TState>(TimeSpan, bool, TState?, bool, TickerCallback<ILoopTicker<TState>>?)
Create a new ticker.
ILoopTicker<TState> CreateTicker<TState>(TimeSpan periodicDelay, bool invokeImmediately, TState? state, bool queueOnGameThread, TickerCallback<ILoopTicker<TState>>? onTick = null)
Parameters
periodicDelayTimeSpanHow often to invoke the ticker.
invokeImmediatelyboolIf the ticker should be invoked now or wait a period.
stateTStatequeueOnGameThreadboolCallback will always be fired on the game thread (if it exists).
onTickTickerCallback<ILoopTicker<TState>>Callback since the event being invoked now would mean you couldn't subscribe to the event first.
Returns
- ILoopTicker<TState>
Type Parameters
TState
CreateTicker<TState>(TimeSpan, TimeSpan, TState?, bool, TickerCallback<ILoopTicker<TState>>?)
Create a new ticker.
ILoopTicker<TState> CreateTicker<TState>(TimeSpan initialDelay, TimeSpan periodicDelay, TState? state, bool queueOnGameThread, TickerCallback<ILoopTicker<TState>>? onTick = null)
Parameters
initialDelayTimeSpanHow long to wait to initially invoke the ticker.
periodicDelayTimeSpanHow often to invoke the ticker.
stateTStatequeueOnGameThreadboolCallback will always be fired on the game thread (if it exists).
onTickTickerCallback<ILoopTicker<TState>>Callback since the event being invoked now would mean you couldn't subscribe to the event first.
Returns
- ILoopTicker<TState>
Type Parameters
TState