| 263 | } |
| 264 | |
| 265 | void SceneController::removeOffscreenGears() |
| 266 | { |
| 267 | float windowHeightMeters = pointsToMeters( app::getWindowHeight() ); |
| 268 | |
| 269 | for( auto &gear : mGears ) { |
| 270 | if( gear->mBody->GetPosition().y > windowHeightMeters ) |
| 271 | gear->mBody.reset(); |
| 272 | } |
| 273 | |
| 274 | mGears.erase( remove_if( mGears.begin(), mGears.end(), |
| 275 | []( const shared_ptr<Gear> &gear ) { return ! gear->mBody; } ), |
| 276 | mGears.end() ); |
| 277 | } |
| 278 | |
| 279 | void SceneController::scrollIslands( float deltaTime ) |
| 280 | { |
nothing calls this directly
no test coverage detected