newgrf.c
changeset 2628 3e7c4506346c
parent 2627 7a29af37b416
child 2645 841087328e0e
equal deleted inserted replaced
2627:7a29af37b416 2628:3e7c4506346c
  2342 
  2342 
  2343 static void InitializeGRFSpecial(void)
  2343 static void InitializeGRFSpecial(void)
  2344 {
  2344 {
  2345 	/* FIXME: We should rather reflect reality in _ttdpatch_flags[]. */
  2345 	/* FIXME: We should rather reflect reality in _ttdpatch_flags[]. */
  2346 
  2346 
  2347 	_ttdpatch_flags[0] = (1 << 0x1B); /* multihead */
  2347 	_ttdpatch_flags[0] = (_patches.always_small_airport ? (1 << 0x0C) : 0)  /* keepsmallairport */
  2348 	_ttdpatch_flags[1] = (1 << 0x08)  /* mammothtrains */
  2348 	                   | (1 << 0x0E)  /* largestations */
  2349 	                   | (1 << 0x0B)  /* subsidiaries */
  2349 	                   | (_patches.longbridges ? (1 << 0x0F) : 0)           /* longbridges */
       
  2350 	                   | (1 << 0x12)  /* presignals */
       
  2351 	                   | (1 << 0x13)  /* extpresignals */
       
  2352 	                   | (_patches.never_expire_vehicles ? (1 << 0x16) : 0) /* enginespersist */
       
  2353 	                   | (1 << 0x1B); /* multihead */
       
  2354 	_ttdpatch_flags[1] = (_patches.mammoth_trains ? (1 << 0x08) : 0)        /* mammothtrains */
       
  2355 	                   | (1 << 0x09)  /* trainrefit */
  2350 	                   | (1 << 0x14)  /* bridgespeedlimits */
  2356 	                   | (1 << 0x14)  /* bridgespeedlimits */
  2351 	                   | (1 << 0x16)  /* eternalgame */
  2357 	                   | (1 << 0x16)  /* eternalgame */
  2352 	                   | (1 << 0x17)  /* newtrains */
  2358 	                   | (1 << 0x17)  /* newtrains */
  2353 	                   | (1 << 0x18)  /* newrvs */
  2359 	                   | (1 << 0x18)  /* newrvs */
  2354 	                   | (1 << 0x19)  /* newships */
  2360 	                   | (1 << 0x19)  /* newships */
  2355 	                   | (1 << 0x1A)  /* newplanes */
  2361 	                   | (1 << 0x1A)  /* newplanes */
  2356 			               | (1 << 0x1B); /* signalsontrafficside */
  2362 	                   | (_patches.signal_side ? (1 << 0x1B) : 0);          /* signalsontrafficside */
  2357 	                   /* Uncomment following if you want to fool the GRF file.
  2363 	                   /* Uncomment following if you want to fool the GRF file.
  2358 	                    * Some GRF files will refuse to load without this
  2364 	                    * Some GRF files will refuse to load without this
  2359 	                    * but you can still squeeze something from them even
  2365 	                    * but you can still squeeze something from them even
  2360 	                    * without the support - i.e. USSet. --pasky */
  2366 	                    * without the support - i.e. USSet. --pasky */
  2361 			               //| (1 << 0x1C); /* electrifiedrailway */
  2367 			               //| (1 << 0x1C); /* electrifiedrailway */
  2362 
  2368 
  2363 	_ttdpatch_flags[2] = (1 << 0x0D)  /* buildonslopes */
  2369 	_ttdpatch_flags[2] = (_patches.build_on_slopes ? (1 << 0x0D) : 0)       /* buildonslopes */
       
  2370 	                   | (_patches.build_on_slopes ? (1 << 0x15) : 0)       /* buildoncoasts */
  2364 	                   | (1 << 0x16)  /* canals */
  2371 	                   | (1 << 0x16)  /* canals */
  2365 	                   | (1 << 0x17)  /* newstartyear */
  2372 	                   | (1 << 0x17)  /* newstartyear */
  2366 	                   | (_patches.wagon_speed_limits ? (1 << 0x1D) : 0); /* wagonspeedlimits */
  2373 	                   | (1 << 0x1A)  /* newbridges */
       
  2374 	                   | (_patches.wagon_speed_limits ? (1 << 0x1D) : 0);   /* wagonspeedlimits */
       
  2375 	_ttdpatch_flags[3] = (1 << 0x03)  /* pathbasedsignalling */
       
  2376 	                   | (1 << 0x0C)  /* enhancemultiplayer */
       
  2377 	                   | (1 << 0x0E)  /* irregularstations */
       
  2378 	                   | (1 << 0x10); /* autoreplace */
  2367 }
  2379 }
  2368 
  2380 
  2369 /**
  2381 /**
  2370  * Unload unused sprite groups from the specified GRF file.
  2382  * Unload unused sprite groups from the specified GRF file.
  2371  * Called after loading each GRF file.
  2383  * Called after loading each GRF file.