Subversion Repositories Games.Carmageddon

Rev

Rev 20 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 20 Rev 21
Line 248... Line 248...
248
        the_time = GetTotalTime() - gTime_bonus_start;
248
        the_time = GetTotalTime() - gTime_bonus_start;
249
        switch (gTime_bonus_state) {
249
        switch (gTime_bonus_state) {
250
        case eTime_bonus_initial_pause:
250
        case eTime_bonus_initial_pause:
251
            if (the_time >= 500) {
251
            if (the_time >= 500) {
252
                bonus = gCurrent_race.bonus_score[gRace_over_reason][gProgram_state.skill_level];
252
                bonus = gCurrent_race.bonus_score[gRace_over_reason][gProgram_state.skill_level];
253
                sprintf(the_text, "%s %d", GetMiscString(kMiscString_TimeBonus), bonus);
253
                sprintf(the_text, "%s %d", GetMiscString(kMiscString_CompletionBonusColon), bonus);
254
                DRS3StartSound(gPedestrians_outlet, 8015);
254
                DRS3StartSound(gPedestrians_outlet, 8015);
255
                ChangeHeadupText(gRace_bonus_headup, the_text);
255
                ChangeHeadupText(gRace_bonus_headup, the_text);
256
                gProgram_state.credits_earned += bonus;
256
                gProgram_state.credits_earned += bonus;
257
                gTime_bonus_state = eTime_bonus_race_bonus;
257
                gTime_bonus_state = eTime_bonus_race_bonus;
258
                gTime_bonus_start = GetTotalTime();
258
                gTime_bonus_start = GetTotalTime();
Line 466... Line 466...
466
        if (!gTimer || gNet_mode != eNet_mode_none) {
466
        if (!gTimer || gNet_mode != eNet_mode_none) {
467
            gRace_finished = 0;
467
            gRace_finished = 0;
468
            return 1;
468
            return 1;
469
        }
469
        }
470
        gRace_finished = 15 * gTimer + 4500;
470
        gRace_finished = 15 * gTimer + 4500;
471
        gRace_bonus_headup = NewTextHeadupSlot(9, 0, 0, -4, "");
471
        gRace_bonus_headup = NewTextHeadupSlot(eHeadupSlot_race_bonus, 0, 0, -4, "");
472
        gTime_bonus_headup = NewTextHeadupSlot(10, 0, 0, -4, "");
472
        gTime_bonus_headup = NewTextHeadupSlot(eHeadupSlot_time_bonus, 0, 0, -4, "");
473
        gTime_bonus = 0;
473
        gTime_bonus = 0;
474
        gTime_bonus_start = GetTotalTime();
474
        gTime_bonus_start = GetTotalTime();
475
        gTime_bonus_state = eTime_bonus_initial_pause;
475
        gTime_bonus_state = eTime_bonus_initial_pause;
476
    }
476
    }
477
    return PDKeyDown(KEY_RETURN) || PDKeyDown(KEY_KP_ENTER);
477
    return PDKeyDown(KEY_RETURN) || PDKeyDown(KEY_KP_ENTER);