File diff r25549:fb65768b27a1 → r25550:35330ff774a6
src/newgrf_config.cpp
Show inline comments
 
@@ -273,33 +273,31 @@ void GRFParameterInfo::Finalize()
 
	this->complete_labels = true;
 
	for (uint32 value = this->min_value; value <= this->max_value; value++) {
 
		if (!this->value_names.Contains(value)) {
 
			this->complete_labels = false;
 
			break;
 
		}
 
	}
 
}
 

	
 
/**
 
 * Update the palettes of the graphics from the config file.
 
 * Called when changing the default palette in advanced settings.
 
 * @param p1 Unused.
 
 * @return Always true.
 
 * @param new_value Unused.
 
 */
 
bool UpdateNewGRFConfigPalette(int32 p1)
 
void UpdateNewGRFConfigPalette(int32 new_value)
 
{
 
	for (GRFConfig *c = _grfconfig_newgame; c != nullptr; c = c->next) c->SetSuitablePalette();
 
	for (GRFConfig *c = _grfconfig_static;  c != nullptr; c = c->next) c->SetSuitablePalette();
 
	for (GRFConfig *c = _all_grfs;          c != nullptr; c = c->next) c->SetSuitablePalette();
 
	return true;
 
}
 

	
 
/**
 
 * Get the data section size of a GRF.
 
 * @param f GRF.
 
 * @return Size of the data section or SIZE_MAX if the file has no separate data section.
 
 */
 
size_t GRFGetSizeOfDataSection(FILE *f)
 
{
 
	extern const byte _grf_cont_v2_sig[];
 
	static const uint header_len = 14;