~ubuntu-branches/ubuntu/raring/simutrans/raring-proposed

« back to all changes in this revision

Viewing changes to gui/settings_stats.cc

  • Committer: Bazaar Package Importer
  • Author(s): Ansgar Burchardt
  • Date: 2010-03-12 09:23:35 UTC
  • mfrom: (1.2.4 upstream)
  • Revision ID: james.westby@ubuntu.com-20100312092335-nb88gufrs0nfi4pv
Tags: 102.2.2~ds1-1
* New upstream release.
  + debian/rules: Update get-orig-source target.
  + debian/rules: Add build-dep on libbz2-dev.
  + debian/rules: Bump dependency on simutrans-pak64 to 102.2.1.
    See also #565493.
  + Refresh patches.
* Update translations.
  + debian/rules: Update list of excluded languages.
* Correct spelling errors.
  + new patch: spelling.patch
* Bump Standards-Version to 3.8.4 (no changes).

Show diffs side-by-side

added added

removed removed

Lines of Context:
173
173
void settings_economy_stats_t::init(einstellungen_t *sets)
174
174
{
175
175
        INIT_INIT
176
 
        INIT_COST( "starting_money", sets->get_starting_money(), 1, 0x7FFFFFFFul, 10000, false );
 
176
        INIT_COST( "starting_money", sets->get_starting_money(sets->get_starting_year()), 1, 0x7FFFFFFFul, 10000, false );
177
177
        INIT_NUM( "pay_for_total_distance", sets->get_pay_for_total_distance_mode(), 0, 2, gui_numberinput_t::AUTOLINEAR, true );
178
178
        INIT_BOOL( "first_beginner", sets->get_beginner_mode() );
179
179
        INIT_NUM( "beginner_price_factor", sets->get_beginner_price_factor(), 1, 25000, gui_numberinput_t::AUTOLINEAR, false );
212
212
void settings_economy_stats_t::read( einstellungen_t *sets )
213
213
{
214
214
        EXIT_INIT
215
 
        EXIT_COST( sets->set_starting_money );
 
215
        if(  sets->get_starting_money(sets->get_starting_year())!=((sint64)(numinp.at(read_numinp)->get_value())*100)  ) {
 
216
                // because this will render the table based values invalid, we do this only when needed
 
217
                EXIT_COST( sets->set_starting_money );
 
218
        }
 
219
        else {
 
220
                // skip this
 
221
                read_numinp++;
 
222
        }
216
223
        EXIT_NUM( sets->set_pay_for_total_distance_mode );
217
224
        EXIT_BOOL( sets->set_beginner_mode );
218
225
        EXIT_NUM( sets->set_beginner_price_factor );