Index: gui/climates.cc =================================================================== --- gui/climates.cc (revision 9169) +++ gui/climates.cc (working copy) @@ -165,16 +165,6 @@ sets->winter_snowline = (sint16)v.i; } - // climate border buttons - for( int i=desert_climate; iclimate_borders[i][0] = (sint16)v.i; - } - if( comp==&(climate_borders_ui[i-1][1]) ) { - sets->climate_borders[i][1] = (sint16)v.i; - } - } - // Update borders for( int i=desert_climate-1; i<=arctic_climate-1; i++ ) { climate_borders_ui[i][0].set_limits( sets->get_groundwater(), 127 ); @@ -181,6 +171,8 @@ climate_borders_ui[i][0].set_value( climate_borders_ui[i][0].get_value() ); climate_borders_ui[i][1].set_limits( climate_borders_ui[i][0].get_value(), 127 ); climate_borders_ui[i][1].set_value( climate_borders_ui[i][1].get_value() ); + sets->climate_borders[i+1][0] = climate_borders_ui[i][0].get_value(); + sets->climate_borders[i+1][1] = climate_borders_ui[i][1].get_value(); } summer_snowline.buf().printf("%d", sets->get_climate_borders(arctic_climate,1) ); Index: simworld.cc =================================================================== --- simworld.cc (revision 9169) +++ simworld.cc (working copy) @@ -1309,10 +1309,9 @@ factory_builder_t::distribute_attractions(settings.get_tourist_attractions()); dbg->message("karte_t::init()", "Preparing startup ..."); - if(zeiger == 0) { + if(zeiger == NULL) { zeiger = new zeiger_t(koord3d::invalid, NULL ); } - // finishes the line preparation and sets id 0 to invalid ... players[0]->simlinemgmt.finish_rd(); @@ -2070,7 +2069,7 @@ // standard prices goods_manager_t::set_multiplier( 1000 ); - zeiger = 0; + zeiger = NULL; plan = 0; grid_hgts = 0; @@ -4627,7 +4626,7 @@ */ bool karte_t::play_sound_area_clipped(koord const k, uint16 const idx, sound_type_t type ) const { - if(is_sound && zeiger) { + if(is_sound && zeiger!=NULL) { const uint32 dist = koord_distance( k, zeiger->get_pos() ); if(dist < 100) { @@ -6022,7 +6021,7 @@ if( climate_map.at( x, y ) > arctic_climate ) { // not assigned yet => start with a random allowed climate allowed.clear(); - sint8 hgt = lookup_hgt_nocheck( x, y )-groundwater; + sint8 hgt = lookup_hgt_nocheck( x, y ); for( int cl=1; cl= settings.get_climate_borders( cl, 0 ) && hgt <= settings.get_climate_borders( cl, 1 ) ) { allowed.append(cl);