mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-07-19 00:59:18 +02:00
work
This commit is contained in:
@@ -107,6 +107,13 @@ driver_mode::update() {
|
||||
|
||||
if (deltatime != 0.0)
|
||||
{
|
||||
static uint32_t fcount = 0;
|
||||
fcount ++;
|
||||
if (fcount > 500) {
|
||||
fcount = 0;
|
||||
WriteLog(std::to_string(Random(1.0, 100.0)));
|
||||
}
|
||||
|
||||
// jak pauza, to nie ma po co tego przeliczać
|
||||
simulation::Time.update( deltatime );
|
||||
|
||||
@@ -722,12 +729,14 @@ driver_mode::OnKeyDown(int cKey) {
|
||||
|| ( tmp->MoverParameters->Vel <= 5.0 ) ) {
|
||||
TTrain *train = request_train(tmp);
|
||||
if (train != nullptr) {
|
||||
/*
|
||||
if( simulation::Train ) {// jeśli mielismy pojazd
|
||||
if( simulation::Train->Dynamic()->Mechanik ) { // na skutek jakiegoś błędu może czasem zniknąć
|
||||
simulation::Train->Dynamic()->Mechanik->TakeControl( true ); // oddajemy dotychczasowy AI
|
||||
}
|
||||
}
|
||||
train->Dynamic()->Mechanik->TakeControl( false );
|
||||
*/
|
||||
simulation::Train = train;
|
||||
InOutKey();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user