Project

General

Profile

Actions

Bug #2453

open

autoworkers never plant or cultivate

Added by Sweet Tea Dorminy about 18 hours ago. Updated about 15 hours ago.

Status:
In Review
Priority:
Normal
Category:
AI
Target version:
Start date:
11/08/2026
Due date:
% Done:

0%

Estimated time:

Description

In 3.x the terrain half of irrigate and mine became two actions of their own.

But initialize_infrastructure_cache() still files the plant and cultivate valuations under ACTIVITY_MINE and ACTIVITY_IRRIGATE, while autoworkers.c reads them back by action_id_get_activity(), i.e. ACTIVITY_PLANT and ACTIVITY_CULTIVATE, which stay at -1. So the ">= 0" test fails on every tile, in every ruleset, for AI players and human auto-workers alike.

Patch uses the right keys, and verified that this results in cultivating and planting by AI.


Files

Actions #1

Updated by Marko Lindqvist about 17 hours ago

  • Status changed from New to In Review
  • Assignee set to Marko Lindqvist
  • Target version set to 3.2.8

In future patches (no need to resubmit already submitted ones - I'll change that myself before merging patches), please include "See RM #????" reference to redmine ticket to the commit message.

Actions #2

Updated by Marko Lindqvist about 17 hours ago

  • Category changed from Server to AI
Actions #3

Updated by Sweet Tea Dorminy about 15 hours ago

I was being too impatient to upload patch and bug together. Thanks!

Actions

Also available in: Atom PDF