I'm also curious about this, in case I need to create a stealth unit that doesn't suck. Is it more complicated than giving a unit the "Partial_Invis" flag?How is stealth spotting configured, anyway? I've had some things I'd like to do with it — give Destroyers full spotting radius against Submarines so they have a reason to continue existing after Cruisers are developed, give AWACS longer spotting against Stealth {Fighters,Bombers} — but I haven't been able to find any documentation on how to do it.
Water, fire, air and dirt! Partial_Invis, how does that work?
-
FriendAtArms
- Posts: 34
- Joined: Thu Apr 16, 2026 9:35 pm
Water, fire, air and dirt! Partial_Invis, how does that work?
In another thread two weeks ago, I mentioned some trouble I was having with a custom stealth unit. It turns out my trouble was because I screwed up my Effects file, and also because my stealth unit was a bad idea anyway. But John Campbell asked:
-
John Campbell
- Posts: 20
- Joined: Wed Jan 18, 2023 6:57 pm
Re: Water, fire, air and dirt! Partial_Invis, how does that work?
Prior to 3.1, yeah, that was all there was to it.
3.1 changed how stealth works. It removed the Partial_Invis flag and added a vision_layer field and different vision layers: Main, Subsurface, and Stealth. Units that aren't vision_layer = "Main" are stealthy, but there's now a distinction between Submarines (Subsurface) and stealth aircraft (Stealth), which seems like a step towards allowing different handling of different kinds of stealth. However there doesn't appear to be any way to actually use that distinction, and least not without more in-depth hacking than just tinkering with the ruleset.
I was hoping you'd stumbled across a way to change spotting against stealth units that I hadn't been able to find, but it looks like your problem was that you'd reconfigured regular vision radius to be less than stealth visibility radius.
Also, I don't believe that stealth (or fog of war in general) has any actual effect on the AI. It's barely able to react in a halfway sensible way even when it knows where all your units are.
I've added stealth to Partisans in my ruleset, but my current game isn't far enough along to test it yet.
Out of curiosity, why are you still using 2.6? 3.x has added a bunch of features useful to ruleset modders, most notably (IMAO) actual requirement vectors for units in 3.2, which I need to keep my War Elephants under control.
3.1 changed how stealth works. It removed the Partial_Invis flag and added a vision_layer field and different vision layers: Main, Subsurface, and Stealth. Units that aren't vision_layer = "Main" are stealthy, but there's now a distinction between Submarines (Subsurface) and stealth aircraft (Stealth), which seems like a step towards allowing different handling of different kinds of stealth. However there doesn't appear to be any way to actually use that distinction, and least not without more in-depth hacking than just tinkering with the ruleset.
I was hoping you'd stumbled across a way to change spotting against stealth units that I hadn't been able to find, but it looks like your problem was that you'd reconfigured regular vision radius to be less than stealth visibility radius.
Also, I don't believe that stealth (or fog of war in general) has any actual effect on the AI. It's barely able to react in a halfway sensible way even when it knows where all your units are.
I've added stealth to Partisans in my ruleset, but my current game isn't far enough along to test it yet.
Out of curiosity, why are you still using 2.6? 3.x has added a bunch of features useful to ruleset modders, most notably (IMAO) actual requirement vectors for units in 3.2, which I need to keep my War Elephants under control.
-
FriendAtArms
- Posts: 34
- Joined: Thu Apr 16, 2026 9:35 pm
Re: Water, fire, air and dirt! Partial_Invis, how does that work?
I use v2.6 because it's the last version that works with a 32-bit processor. Of course I intend to upgrade to a computer that was built after 2011 at some point. But securing food, clothing, and shelter always has to take priority, and those haven't exactly been getting cheaper over these past five or six years. (For that matter, neither have computers!)
It should take me about a year, plus-or-minus a few months, to upgrade my computer and update to a post-3.0 Freeciv. Hopefully by then, all this "subsurface stealth isn't really stealth, it's a different thing that works exactly the same" stuff will have been sorted out.
It should take me about a year, plus-or-minus a few months, to upgrade my computer and update to a post-3.0 Freeciv. Hopefully by then, all this "subsurface stealth isn't really stealth, it's a different thing that works exactly the same" stuff will have been sorted out.
-
FriendAtArms
- Posts: 34
- Joined: Thu Apr 16, 2026 9:35 pm
Re: Water, fire, air and dirt! Partial_Invis, how does that work?
It's even dumber than that! As far as I can tell, I configured the vision radius for cities, specifically, to be zero. The game was still displaying everything normally, so the player (i.e., me) could see things just fine. Units behaved normally, given the limitations of the AI. But the cities were throwing sanity checks every turn.I was hoping you'd stumbled across a way to change spotting against stealth units that I hadn't been able to find, but it looks like your problem was that you'd reconfigured regular vision radius to be less than stealth visibility radius.
I think ultimately, the value of my ruleset is going to end up being "how many blocks can you pull out of the Freeciv Jenga tower before it falls down". Which is...a kind of contribution!
Re: Water, fire, air and dirt! Partial_Invis, how does that work?
Last freeciv version with 32-bit Windows ("win32") builds available is 3.0. For other OSes 32-bit builds should still work even from development version.FriendAtArms wrote: ↑Sun Jun 07, 2026 12:58 amI use v2.6 because it's the last version that works with a 32-bit processor.
https://sourceforge.net/projects/freeci ... .0/3.0.10/