| 267 | } |
| 268 | |
| 269 | void SystemTimer::start(float duration, const std::function<void()>& callback) { |
| 270 | _time = 0.0f; |
| 271 | _duration = std::max(0.0f, duration); |
| 272 | _callback = callback; |
| 273 | SharedDirector.getSystemScheduler()->schedule(&_scheduledItem); |
| 274 | } |
| 275 | |
| 276 | void SystemTimerBase::stop() { |
| 277 | _time = _duration = 0.0f; |
nothing calls this directly
no test coverage detected