Skip to content

Commit

Permalink
let vanilla blinking take over when possible
Browse files Browse the repository at this point in the history
  • Loading branch information
myk002 committed Sep 11, 2023
1 parent 73b5f0c commit 70b48df
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions plugins/pathable.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@

#include "modules/EventManager.h"
#include "modules/Gui.h"
#include "modules/Job.h"
#include "modules/Maps.h"
#include "modules/Screen.h"
#include "modules/Textures.h"
Expand Down Expand Up @@ -255,9 +256,13 @@ class Designations {

df::tile_designation td;
df::tile_occupancy to;
bool keep_if_taken = false;

switch (job->job_type) {
case df::job_type::SmoothWall:
case df::job_type::SmoothFloor:
keep_if_taken = true;
// fallthrough
case df::job_type::CarveFortification:
td.bits.smooth = 1;
break;
Expand All @@ -272,9 +277,10 @@ class Designations {
to.bits.carve_track_east = (job->item_category.whole >> 21) & 1;
break;
default:
break;
continue;
}
designations.emplace(job->pos, designation(job->pos, td, to));
if (keep_if_taken || !Job::getWorker(job))
designations.emplace(job->pos, designation(job->pos, td, to));
}
}

Expand Down

0 comments on commit 70b48df

Please sign in to comment.