Skip to content

fix animals can block units#291

Open
LIFEfreedom wants to merge 1 commit into
reyandme:masterfrom
LIFEfreedom:feature/2226-animals-can-block-units
Open

fix animals can block units#291
LIFEfreedom wants to merge 1 commit into
reyandme:masterfrom
LIFEfreedom:feature/2226-animals-can-block-units

Conversation

@LIFEfreedom
Copy link
Copy Markdown

bug link

It occurs because the unit interaction logic inside TKMUnitActionWalkTo does not let citizens accumulate "timeout" status when blocked by animals, meaning they never try to reroute around them. Animals are ignored in the DoUnitInteraction method.
Regular units use the TKMUnitActionWalkTo action class, which has a complex "social interaction" system—units can negotiate.

Animals, however, use a completely different, simpler movement script—the TKMUnitActionSteer class.
TKMUnitActionWalkTo contains:

// Can't interact with animals
if opponent.IsAnimal then
    Exit;

@LIFEfreedom LIFEfreedom force-pushed the feature/2226-animals-can-block-units branch from a872703 to 7970165 Compare April 3, 2026 08:50
@LIFEfreedom LIFEfreedom changed the title animals can block units fix animals can block units Apr 3, 2026
@LIFEfreedom LIFEfreedom force-pushed the feature/2226-animals-can-block-units branch from 7970165 to 070d740 Compare April 3, 2026 09:16
@LIFEfreedom LIFEfreedom force-pushed the feature/2226-animals-can-block-units branch from 070d740 to bff3afa Compare April 3, 2026 09:59
@Kromster80
Copy link
Copy Markdown
Collaborator

New code around lines L:200 looks too dangerous to include before release without extensive testing.
I will leave this PR until after planned Release (and/or until we have another RC and/or testing framework in place).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants