- world->play_music(LEVEL_MUSIC);
-
- global_frame_counter++;
- tux->key_event((SDLKey) keymap.right,DOWN);
-
- if(random_timer.check())
- {
- if(walking)
- tux->key_event((SDLKey) keymap.jump,UP);
- else
- tux->key_event((SDLKey) keymap.jump,DOWN);
- }
- else
- {
- random_timer.start(rand() % 3000 + 3000);
- walking = !walking;
- }
-
- // Wrap around at the end of the level back to the beginnig
- if(world->solids->get_width() * 32 - 320 < tux->base.x)
- {
- tux->level_begin();
- world->camera->reset(Vector(tux->base.x, tux->base.y));
- }