コード例 #1
0
void Menu::moveToCity(CityButton city, bool clicked) {
	uint32 time = (uint32)_cityButtonsInfo[city].time;

	// TODO Check if we have access (there seems to be more checks on some internal times) - probably : current_time (menu only) / game time / some other?
	if (_lowerTime < time || _time == time || _currentTime == time) {
		hideOverlays();
		return;
	}

	// Show city overlay
	showFrame((StartMenuOverlay)((_cityButtonsInfo[city].index >> 6) + 3), _cityButtonsInfo[city].index & 63, true);

	if (clicked) {
		showFrame(kOverlayTooltip, -1, true);
		getSound()->playSound(kEntityPlayer, "LIB046");
		goToTime(time);

		_handleTimeDelta = true;

		return;
	}

	// Special case of first and last cities
	if (city == kParis || city == kConstantinople) {
		showFrame(kOverlayTooltip, (city == kParis) ? kTooltipRewindParis : kTooltipForwardConstantinople, true);
		return;
	}

	showFrame(kOverlayTooltip, (_time <= time) ? _cityButtonsInfo[city].forward : _cityButtonsInfo[city].rewind, true);
}
コード例 #2
0
uint8_t AVDMBufferedAudioStream::goTo(uint32_t newoffset) {
        ADM_assert(!newoffset);
        goToTime(0);
        return 1;
}
コード例 #3
0
void fc_scoreManager::goToSection5() {
    goToTime(sectionStartTimes[4]);
}