(dt float32)
| 161 | func (*SceneSwitcherSystem) Remove(ecs.BasicEntity) {} |
| 162 | |
| 163 | func (s *SceneSwitcherSystem) Update(dt float32) { |
| 164 | s.secondsWaited += dt |
| 165 | if float64(s.secondsWaited) > s.WaitTime.Seconds() { |
| 166 | s.secondsWaited = 0 |
| 167 | |
| 168 | // Change the world to s.NextScene, and don't override / force World re-creation |
| 169 | engo.SetSceneByName(s.NextScene, false) |
| 170 | |
| 171 | log.Println("Switched to", s.NextScene) |
| 172 | } |
| 173 | } |
| 174 | |
| 175 | type scaleEntity struct { |
| 176 | *ecs.BasicEntity |
nothing calls this directly
no test coverage detected