These modules seek to provide the simplest possible solution to creeps getting stuck on eachother, typically when using high reusePath
values or ignoreCreeps: true
.
With these modules you should be able to use these options without issues.
The scripts provide good insight into a perfectly capable basic solution by being as simple and easy-to-use as possible.
However, they don't aim to be the most efficient solution. To be more efficient it is recommended to expand upon their capabilities in your own codebase. Suggestions for ideas on how to improve upon them yourself are given at the end of this readme. More efficient solutions can be reached simply by expanding upon the provided framework, but there are also entirely different systems and ways of doing it.
One of the giveWay
-scripts can be used, as well as stuckRepather
. It is up to you if you want to use stuckRepather
, giveWay
, or both.
Usage of each module is described in the files themselves.
Allows creeps to move out of the way of other creeps.
Two files are provided, a standard and a streamlined version. They cannot be used together.
The streamlined version is much simpler and more concise, but some uses of move
or moveTo
may cause problematic behavior if creeps accidentally try moving into walls.
The standard version is more forgiving to inefficient use of move
and moveTo
, but also includes more code at the bottom of the file which is more confusing and not really necessary to understand.
Implements a last-ditch effort to automatically repath around other creeps if they get stuck.
Ideally giveWay
aims to minimize the need for this, but ultimately if it fails, this module will take care of it.
move
into it.lookForAt
, ones that can be reused to make other behaviors in our codebase cheaper too.