Changeset - r16192:37c376b1e9b4
[Not reviewed]
master
0 1 0
frosch - 14 years ago 2010-10-04 20:20:50
frosch@openttd.org
(svn r20902) -Fix [FS#4032]: Make IsProductionAlterable() work for most NewGRF industries.
The NewGRF either has to use properties 12/13, or it needs to set property 0B to 'primary industry'.
So it will not work for bank-like industries which use pure production-callback production.
1 file changed with 2 insertions and 1 deletions:
0 comments (0 inline, 0 general)
src/industry_gui.cpp
Show inline comments
 
@@ -624,8 +624,9 @@ static void UpdateIndustryProduction(Ind
 

	
 
static inline bool IsProductionAlterable(const Industry *i)
 
{
 
	const IndustrySpec *is = GetIndustrySpec(i->type);
 
	return ((_game_mode == GM_EDITOR || _cheats.setup_prod.value) &&
 
			(i->accepts_cargo[0] == CT_INVALID || i->accepts_cargo[0] == CT_VALUABLES));
 
			(is->production_rate[0] != 0 || is->production_rate[1] != 0 || is->IsRawIndustry()));
 
}
 

	
 
/** Names of the widgets of the view industry gui */
0 comments (0 inline, 0 general)