Skip to content

Show AI allocations as regular ghost elements#3270

Merged
AaronVanGeffen merged 5 commits intoOpenLoco:masterfrom
AaronVanGeffen:ai-ghosts
Oct 27, 2025
Merged

Show AI allocations as regular ghost elements#3270
AaronVanGeffen merged 5 commits intoOpenLoco:masterfrom
AaronVanGeffen:ai-ghosts

Conversation

@AaronVanGeffen
Copy link
Copy Markdown
Member

@AaronVanGeffen AaronVanGeffen commented Sep 21, 2025

Experiment for @LeftofZen. Could be useful behind a viewport flag or game setting? Quite fascinating to see AI companies plan their routes -- seeing ghosts appear and disappear.

NB: these AI allocations currently do not invalidate their respective tiles, so things may glitch a little.

Screenshot (2) Screenshot (3)

@duncanspumpkin
Copy link
Copy Markdown
Contributor

Would this be useful as an overlay you could apply like underground? I'm not sure you would always want it on/off but you might want to peak at it occasionally.

@duncanspumpkin
Copy link
Copy Markdown
Contributor

duncanspumpkin commented Sep 24, 2025

NB: these AI allocations currently do not invalidate their respective tiles, so things may glitch a little.

In fact it goes out of the way to make sure it doesn't invalidate the area in each of the game commands.

@AaronVanGeffen
Copy link
Copy Markdown
Member Author

Would this be useful as an overlay you could apply like underground? I'm not sure you would always want it on/off but you might want to peak at it occasionally.

Agreed, this is probably best toggled with a viewport flag or some such.

NB: these AI allocations currently do not invalidate their respective tiles, so things may glitch a little.

In fact it goes out of the way to make sure it doesn't invalidate the area in each of the game commands.

Good, good. Let's make sure it still doesn't trigger if the option/flag is inactive, then.

@AaronVanGeffen AaronVanGeffen marked this pull request as ready for review October 23, 2025 13:44
@AaronVanGeffen AaronVanGeffen added the changelog Requires a changelog entry label Oct 23, 2025
@AaronVanGeffen
Copy link
Copy Markdown
Member Author

AaronVanGeffen commented Oct 23, 2025

I've extended this to make this 'AI planning reveal' optional; the checkbox is in the rendering tab in options window, off by default.

(NB: I've made it a config setting rather than a viewport flag, so the game commands involved don't have to bother with UI.)

Copy link
Copy Markdown
Contributor

@LeftofZen LeftofZen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Appears to work nicely!

Image Image

As expected, if you try to build there, you get the correct message:

Image

@AaronVanGeffen AaronVanGeffen merged commit 20e7be0 into OpenLoco:master Oct 27, 2025
11 checks passed
@AaronVanGeffen AaronVanGeffen deleted the ai-ghosts branch October 27, 2025 09:53
@AaronVanGeffen AaronVanGeffen added this to the v25.10+ milestone Oct 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog Requires a changelog entry

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants