Functions | |
| std::vector< game_tip > | load (const config &cfg) |
| Loads the tips from a config. | |
| std::vector< game_tip > | shuffle (const std::vector< game_tip > &tips) |
| Shuffles the tips. | |
Loads the tips from a config.
| cfg | A config with the tips. |
Definition at line 37 of file tips.cpp.
References cfg, and config::child_range().
Shuffles the tips.
This routine shuffles the tips and filters out the unwanted ones.
| tips | The tips. |
Definition at line 43 of file tips.cpp.
References randomness::rng::default_instance(), prefs::encountered_units(), utils::erase_if(), prefs::get(), and gui2::game_tip::unit_filter.
Referenced by gui2::dialogs::title_screen::init_callbacks().