Taken into account current ToD when modifying turn number.
(Fix for bug #14995.)
This commit is contained in:
parent
339e97884c
commit
b95e4b475c
1 changed files with 1 additions and 1 deletions
|
@ -301,7 +301,7 @@ void tod_manager::set_turn(unsigned int num)
|
|||
VALIDATE(times_.size(), _("No time of day has been defined."));
|
||||
const unsigned int old_num = turn_;
|
||||
// Correct ToD
|
||||
int current_time = (num - 1) % times_.size();
|
||||
int current_time = (currentTime_ + num - old_num) % times_.size();
|
||||
if (current_time < 0) {
|
||||
current_time += times_.size();
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue