Changeset - r28440:782a8277fbf1
[Not reviewed]
master
0 1 0
Jonathan G Rennison - 11 months ago 2024-01-12 21:53:31
j.g.rennison@gmail.com
Fix #11696: Graphics set parameters missing from survey data (#11764)
1 file changed with 6 insertions and 0 deletions:
0 comments (0 inline, 0 general)
src/survey.cpp
Show inline comments
 
@@ -245,12 +245,18 @@ void SurveyConfiguration(nlohmann::json 
 
	if (VideoDriver::GetInstance() != nullptr) {
 
		survey["video_driver"] = VideoDriver::GetInstance()->GetName();
 
		survey["video_info"] = VideoDriver::GetInstance()->GetInfoString();
 
	}
 
	if (BaseGraphics::GetUsedSet() != nullptr) {
 
		survey["graphics_set"] = fmt::format("{}.{}", BaseGraphics::GetUsedSet()->name, BaseGraphics::GetUsedSet()->version);
 
		const GRFConfig *extra_cfg = BaseGraphics::GetUsedSet()->GetExtraConfig();
 
		if (extra_cfg != nullptr && extra_cfg->num_params > 0) {
 
			survey["graphics_set_parameters"] = span<const uint32_t>(extra_cfg->param.data(), extra_cfg->num_params);
 
		} else {
 
			survey["graphics_set_parameters"] = span<const uint32_t>();
 
		}
 
	}
 
	if (BaseMusic::GetUsedSet() != nullptr) {
 
		survey["music_set"] = fmt::format("{}.{}", BaseMusic::GetUsedSet()->name, BaseMusic::GetUsedSet()->version);
 
	}
 
	if (BaseSounds::GetUsedSet() != nullptr) {
 
		survey["sound_set"] = fmt::format("{}.{}", BaseSounds::GetUsedSet()->name, BaseSounds::GetUsedSet()->version);
0 comments (0 inline, 0 general)