Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Inability to place a colony/outpost should produce a sitrep #1456

Open
l29ah opened this issue Apr 1, 2017 · 2 comments
Open

Inability to place a colony/outpost should produce a sitrep #1456

l29ah opened this issue Apr 1, 2017 · 2 comments
Labels
category:feature The Issue/PR describes or implements a new game feature. component:content scripting The Issue/PR deals with the FOCS language, turn events or the universe generator.

Comments

@l29ah
Copy link
Contributor

l29ah commented Apr 1, 2017

When an colony/outpost base is produced on a system where enemy is present and ordered to place a colony/outpost it won't get destroyed and silently ignore its orders. It should bug the player as one would easily forget about it.

@Vezzra Vezzra added category:feature The Issue/PR describes or implements a new game feature. component:content scripting The Issue/PR deals with the FOCS language, turn events or the universe generator. labels Apr 2, 2017
@Vezzra Vezzra added this to the optional for v0.4.7 milestone Apr 2, 2017
@Dilvish-fo
Copy link
Member

I don't think that this is something that could currently be handled via scripting a sitrep, and I think the best solution for this problem is not a sitrep, or at least not just a sitrep. The constraint against colonizing when an armed aggressive enemy is present is enforced by c++ engine code in ServerApp.cpp, HandleColonization(), not the scripts, and from a quick review it looks to me like the scripts currently do not have access to the info that a ship has been ordered to colonize (it looks to me like the only current similar type status that is exposed to scripts is the OrderedBombarded condition, but that exposing the same thing for colonization wouldn't really help here anyways).

I think that to cover this well we would need a couple things done:

  1. Button Disabling: The UI code that enables the colonize button should also check for armed aggressive enemies, and not enable itself in if they are present. This button enablement is dealt with by SidePanel::PlanetPanel::Refresh(), and it checks for a number of other things but for some reason doesn't check for enemy presence.
  2. Failure SitRep: The server checks are a bit more broad than the client can reliably check-- the client will only know about visible enemies, but stealthed armed aggressive enemies will also block colonization (and I think would not necessarily have been revealed by a previous round of combat), and also colonization will fail if multiple empires try to colonize the same planet at the same time. I see several problems with trying to handle a sitrep via scripting, and I think that the best thing will be to generate a failure sitrep in ServerApp.cpp HandleColonization() the same way that the colonization success sitrep is generated.

@Vezzra Vezzra modified the milestones: optional for v0.4.7, v0.4.8 May 1, 2017
@Vezzra Vezzra modified the milestones: v0.4.8 (optional), post 0.4.8 Jun 6, 2018
@Vezzra Vezzra removed this from the Next Release milestone Sep 22, 2019
@Oberlus
Copy link
Contributor

Oberlus commented Aug 30, 2022

I would like this to be fixed someday.
Either by having a SitRep or (better) by disabling the colonize/outpost button when there are enemies, as suggested by @Dilvish-fo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:feature The Issue/PR describes or implements a new game feature. component:content scripting The Issue/PR deals with the FOCS language, turn events or the universe generator.
Projects
None yet
Development

No branches or pull requests

4 participants