Hidden planet gets attacked every turn.

Describe your experience with the latest version of FreeOrion to help us improve it.

Moderator: Oberlus

Forum rules
Always mention the exact version of FreeOrion you are testing.

When reporting an issue regarding the AI, if possible provide the relevant AI log file and a save game file that demonstrates the issue.
Post Reply
Message
Author
User avatar
Oberlus
Cosmic Dragon
Posts: 5713
Joined: Mon Apr 10, 2017 4:25 pm

Hidden planet gets attacked every turn.

#1 Post by Oberlus »

I'm playing Sly, stealth and distributed. Trying to fish for stealth bugs. Maybe got one:

My hidden GGs with 85 stealth are attacked every turn a combat between two other factions goes on in the system.
I have no planetary defences, so my planets aren't attacking at all.
Combat log does not show that they are detected after or before anything, they're just attacked.
PS: detection strength of all other empires is 30.

Maybe tangentially related: viewtopic.php?f=28&t=11016
Attachments
hiddenPlanetAttacked.png
hiddenPlanetAttacked.png (446.74 KiB) Viewed 3570 times

Ophiuchus
Programmer
Posts: 3433
Joined: Tue Sep 30, 2014 10:01 am
Location: Wall IV

Re: Hidden planet gets attacked every turn.

#2 Post by Ophiuchus »

Oberlus wrote: Sun Nov 03, 2019 5:43 pm Combat log does not show that they are detected after or before anything, they're just attacked.
That certainly sounds like a targeting issue. Your planet is probably not detected.
Any code or patches in anything posted here is released under the CC and GPL licences in use for the FO project.

Look, ma... four combat bouts!

User avatar
Oberlus
Cosmic Dragon
Posts: 5713
Joined: Mon Apr 10, 2017 4:25 pm

Re: Hidden planet gets attacked every turn.

#3 Post by Oberlus »

Ophiuchus wrote: Sun Nov 03, 2019 6:57 pm That certainly sounds like a targeting issue. Your planet is probably not detected.
I opened an issue 2630.

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 13587
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Hidden planet gets attacked every turn.

#4 Post by Geoff the Medio »

As far as I recall, and seemingly consistent with combat visibility initialization, planets are always at least basically visible... In the main game / galaxy map, you can always tell a planet is there, but unless you have enough detection strength, you won't be able to see its details, like meter levels. That basic visibility carries over to the combat code, where planets are always basically visible, unless you have adequate detection strength to overcome their stealth.

https://github.com/freeorion/freeorion/ ... m.cpp#L197

The combat conditions that check what are valid targets just require and object to be basically visible to be targetable (and not partially visible, which would require passing the detection / stealth check).

https://github.com/freeorion/freeorion/ ... m.cpp#L259
https://github.com/freeorion/freeorion/ ... .cpp#L7107

Thus planets are targetable in combat, as long as they have a shield, defense, or construction meter > 0.

It should be possible to make planets initially non-visible in combat only, until they fire, if they aren't detected due to stealth, though.

JonCST
Space Kraken
Posts: 157
Joined: Sat Dec 15, 2018 4:28 am

Re: Hidden planet gets attacked every turn.

#5 Post by JonCST »

Geoff the Medio wrote: Sat Nov 09, 2019 12:22 pm It should be possible to make planets initially non-visible in combat only, until they fire, if they aren't detected due to stealth, though.
That would be my preference. Otherwise what's the point of stealth?

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 13587
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Hidden planet gets attacked every turn.

#6 Post by Geoff the Medio »

JonCST wrote: Sat Nov 09, 2019 2:12 pmOtherwise what's the point of stealth?
Various other non-planet and non-combat applications.

If planets can be initially stealthed in combat and attacking reveals them, so they can be attacked in later combat rounds, then there will been desire from players to control whether planets should attack in combat, so that they don't reveal themselves. This is also a missing feature for ships in combat, but seemingly less consequential, since one can make unarmed ships more easily than unarmed planets...

User avatar
Oberlus
Cosmic Dragon
Posts: 5713
Joined: Mon Apr 10, 2017 4:25 pm

Re: Hidden planet gets attacked every turn.

#7 Post by Oberlus »

Geoff the Medio wrote: Sun Nov 10, 2019 11:20 am
JonCST wrote: Sat Nov 09, 2019 2:12 pmOtherwise what's the point of stealth?
Various other non-planet and non-combat applications.

If planets can be initially stealthed in combat and attacking reveals them, so they can be attacked in later combat rounds, then there will been desire from players to control whether planets should attack in combat, so that they don't reveal themselves. This is also a missing feature for ships in combat, but seemingly less consequential, since one can make unarmed ships more easily than unarmed planets...
I sometimes miss a planetary toggle for aggressiveness. But that's problematic. Maybe just: if defence focused, they are aggressive, if not, they behave like passive fleets (only shot if combat triggers due to other's actions).

JonCST
Space Kraken
Posts: 157
Joined: Sat Dec 15, 2018 4:28 am

Re: Hidden planet gets attacked every turn.

#8 Post by JonCST »

Geoff the Medio wrote: Sun Nov 10, 2019 11:20 am If planets can be initially stealthed in combat and attacking reveals them, so they can be attacked in later combat rounds, then there will been desire from players to control whether planets should attack in combat, so that they don't reveal themselves.
I have in fact not researched planetary defense when building stealth planets in order for them not to reveal themselves, not realizing that they can be attacked anyway...

J

defaultuser
Juggernaut
Posts: 854
Joined: Wed Aug 26, 2015 6:15 pm

Re: Hidden planet gets attacked every turn.

#9 Post by defaultuser »

Geoff the Medio wrote: Sat Nov 09, 2019 12:22 pm As far as I recall, and seemingly consistent with combat visibility initialization, planets are always at least basically visible... In the main game / galaxy map, you can always tell a planet is there, but unless you have enough detection strength, you won't be able to see its details, like meter levels.
I think the Experimenter planet won't show up at all at very low detection levels. Of course, players aren't at that stealth level.

User avatar
Geoff the Medio
Programming, Design, Admin
Posts: 13587
Joined: Wed Oct 08, 2003 1:33 am
Location: Munich

Re: Hidden planet gets attacked every turn.

#10 Post by Geoff the Medio »

defaultuser wrote: Wed Nov 13, 2019 10:37 pmI think the Experimenter planet won't show up at all at very low detection levels. Of course, players aren't at that stealth level.
To be more precise, I should have written "you can always tell a planet is there if you have a ship or planet in the same system". Distant objects don't have a similar exception to give planets basic visibility. The relevant case here is combat though, in which case objects do need to be in the same system and my previous statement applies.

Post Reply