|
|
|
@ -81,14 +81,23 @@ public:
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (found && !bookkeeping) {
|
|
|
|
|
if (found) {
|
|
|
|
|
// Entice the bookkeeper to spend less time update records.
|
|
|
|
|
ui->bookkeeper_precision += ui->bookkeeper_precision >> 3;
|
|
|
|
|
if (!bookkeeping) {
|
|
|
|
|
command_method("start_bookkeeping", out);
|
|
|
|
|
bookkeeping = true;
|
|
|
|
|
} else if (bookkeeping && !found) {
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
// Entice the bookkeeper to update records more often.
|
|
|
|
|
ui->bookkeeper_precision -= ui->bookkeeper_precision >> 5;
|
|
|
|
|
ui->bookkeeper_cooldown -= ui->bookkeeper_cooldown >> 2;
|
|
|
|
|
if (bookkeeping) {
|
|
|
|
|
command_method("finish_bookkeeping", out);
|
|
|
|
|
bookkeeping = false;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void init() {
|
|
|
|
|
stockpile_id = -1;
|
|
|
|
|