File diff r7744:dee94ea8f01a → r7745:31fac36516c6
src/newgrf.cpp
Show inline comments
 
@@ -1881,26 +1881,25 @@ static bool IndustriesChangeInfo(uint in
 

	
 
				for (byte j = 0; j < indsp->num_table; j++) {
 
					for (int k = 0;; k++) {
 
						itt[k].ti.x = grf_load_byte(&buf); // Offsets from northermost tile
 

	
 
						if (itt[k].ti.x == 0xFE && k == 0) {
 
							/* This means we have to borrow the layout from an old industry */
 
							IndustryType type = grf_load_byte(&buf);  //industry holding required layout
 
							byte laynbr = grf_load_byte(&buf);        //layout number to borrow
 

	
 
							copy_from = (IndustryTileTable*)_origin_industry_specs[type].table[laynbr];
 
							for (size = 1;; size++) {
 
								if (_origin_industry_specs[type].table[laynbr + (size - 1)]->ti.x == -0x80 &&
 
										_origin_industry_specs[type].table[laynbr + (size - 1)]->ti.y == 0) break;
 
								if (copy_from[size - 1].ti.x == -0x80 && copy_from[size - 1].ti.y) break;
 
							}
 
							break;
 
						}
 

	
 
						itt[k].ti.y = grf_load_byte(&buf); // Or table definition finalisation
 

	
 
						if (itt[k].ti.x == 0 && itt[k].ti.y == 0x80) {
 
							/*  Not the same terminator.  The one we are using is rather
 
							 x= -80, y = x .  So, adjust it. */
 
							itt[k].ti.x = -0x80;
 
							itt[k].ti.y =  0;
 
							itt[k].gfx  =  0;