Developer Diary 14 – Fog of War

Playing a full game turn is now within our sights, save for the plus-sized hurdle that has to be dealt with first: enemy unit visibility. The game now features Fog of War, so all the game rules need to be re-checked for visibility. Moves and attacks will obviously change FoW, but there are also new mechanics like air reconnaissance, and HQ abilities play an important role as well.

But even before that, there’s the basic question of who actually sees what.

For example, in the screenshot below, I’m playing as the Allies, and any Axis units in FoW are hidden from me. Once the game ends though, I can watch the replay (history mode) and, in the replay, I do want to see what the opponent was doing behind FoW. So, the FoW overlay is still turned ON in replay, but the enemy units are not hidden any more.

Except, you can watch the replay even before the game has been completed. In this case, enemy units must stay hidden, otherwise it would be a glaring exploit. Um hm… In multiplayer, an observer can watch an ongoing game. But observer’s visibility is limited to what both players can see, so that’s yet another visibility mode. There are further visibility modes for scenario designers (see all units, plus both friendly and enemy FoW) and others.

To cut a long story short, we’ve decided that if this is to be done right™, it calls for a separate visibility layer that lives on top of game state and that’s we’re busying ourselves with currently.

Screenie Time

The screen below shows the game in something close to its final shape. We’ve added unit drop shadows, anti-aliasing (FXAA/SSAA), reflections and bloom effect. It’s not final final yet, as there is still a good amount of color-juggling left to be done – color coding has to work in all environments, in any weather and with all possible faction colors. It’s getting there, though.

You can see that FoW is an overlay that tints the map in enemy colors – similar to how we tinted all enemy hexes in UoC1. It’s important that the player can see the precise extent of FoW while playing. This makes it possible to distinguish between an empty hex and a hex in FoW, where an enemy unit may be hiding. The player should never be counting hexes to figure this out.

Fun FoW-related fact: a unit hidden in FoW can extend its Zone of Control into a visible hex. That means you can get caught up in a ZoC by surprise, while moving through visible territory. We may place some sort of a reminder/warning for this on the move arrow, though I’m still not sure.

(click image for full size)

Technical Developments

We’ve added a Level of Detail (LOD) system for terrain, and this improves the frame rate considerably on older graphics cards. Our reference toaster is a 2011 GTX 560 and we’re trying to get that to work at 60FPS with medium settings. The game still looks very decent while the performance is almost, but not quite, there.

If you have a more recent card, LOD enables totally epic zoom-out, up to a point where you can still kinda, maybe, see what’s going on, but hexes are definitely too small to play meaningfully. This will not be the default option, but it will be available either in the settings or via mods.

We’re about halfway through UI work at this time. It’s an intricate design, and it takes a while to sort out all the bevels and gradients and whatnot. The end result should look good – on par with the game world, as it should. This is not done yet so no screenies, but it looks like it will be a topic for the next post.

We’ve also upgraded tree-planting in the map editor, added labels for city names and improved hex grid rendering (this was a problem specifically for older cards which don’t handle GL_LINES well). There’s now a way to rotate turrets on tanks, but no squealing noise yet. Tweaks and fixes abound.

The work continues! 🙂

This entry was posted in News. Bookmark the permalink.

29 Responses to Developer Diary 14 – Fog of War

  1. John P. McMenamin says:

    Looks awesome!

  2. Imbolg says:

    You guise are awesome. Any plans for early access?

  3. Marko Hladnik says:

    @Imbolg: No, they will deliver completed perfection when ready 😉 Beta testing, though, has been mentioned …

  4. Tschemo says:

    Looks great so far guys. I can’t wait to play it once it is available. 🙂

    Regarding FoW for observers I think you can take some inspiration from current RTS games where you can be an observer either on one side or the other or to see all. The last option should require some “approval” from the game creator (multiplayer game). Should be enough to let him/her have the option to open/close slot for the “global observer”.

    “Fun FoW-related fact:… We may place some sort of a reminder/warning for this on the move arrow, though I’m still not sure.”
    -> Please don’t do that! If the unit is hidden in FoW then also ZoC should be hidden allowing the unit to “ambush” enemy units moving nearby. I mean ambush in the meaning of locking the enemy unit and not allowing it to move any further. Exceptions might apply like if the locked unit is a reconnaissance unit, etc.

  5. Stian says:

    Great update you guys, the MP observer mode sounds interesting. This will be a thing of beauty, I’m sure.

    One little thing, the screenshot looks a little too contrast-heavy and dark, over-saturated, for my taste, like those fancy HDR shots that just look fake to me. Especially noticeable in the mountains. I guess maybe it’s bloom and hopefully something we can toggle?

  6. tom says:

    Cheers all! 🙂

    @Tschemo: I want to add a small warning icon that an “ambush” is possible (when you place the move arrow next to FoW). We do not tell you if there’s a unit there or not. This is just a helper so you don’t have to compute these things yourself. A counter-example: if FoW is across a river, then there’s no risk and we don’t place a warning – so you know you can move freely.

    @Stian: it might be the sun angle that’s doing it. I turned the camera so that it’s looking west-northwest, because that gave me the best shot with all the new stuff in it. But it means you’re looking toward the sun, and yeah maybe it appears to have more contrast.

    That said, we are actually de-saturating the terrain in post-processing so that the units stand out better. We could do more but the worry is that it will end up looking totally washed out. As I said in the post, colors are an ongoing concern in developing a game like this one 🙂

  7. John says:

    Looks fantastic! Thank you for sharing all this.

    I agree that spectators should choose to observe one side or the other.

    As cool as it looks, you may also consider making fog of war an option.

    And tank squeaking is a must!

  8. Dana Taylo says:

    I have a comment kind Sirs. The one thing I really don’t like on the previous games is that you are limited in turns.

    Once you beat the game, and get bored, it can be a bit fun to aimlessly play Taifun (example) for a hundred turns… but we can’t.

    I think after we have paid for the game we should be allowed to unlock turns, even if the AI can’t adjust.

    Just a comment.

    Thank you.

  9. tom says:

    @Dana: this will probably only be available as a mod (option). It may end up being more fun though, since the AI will play differently this time, i.e. there will be no more wipeouts (you can check previous diaries for details on that).

    @John: if you turn off FoW completely, parts of the game become meaningless (HQ intel, mostly). That said, it’s trivial to turn it off so again a mod perhaps?


  10. Harry.vdk says:


    If you with you can take a look at the forum and look within the modding section for “Changing Victory Level of the campaigns”.

    With this mod you can change the turn limitations for the current version.

    Let see how the new version works, but changing works the same way (i think).

  11. Harry.vdk says:


    With FOW on, is a undo still posable?

  12. tom says:

    @Harry: undo is still possible, but only if your action did not reveal FoW (made it visible) on any hex.

    This means it’s not a good idea to do the following any more: move unit, check attack odds, undo. To make up for this we are adding a map view where you can quickly see attack odds against all nearby units, simply by holding down CTRL (well, probably CTRL, actual hotkey may change).

  13. karis says:

    Hi Guys,
    just wanted to say this is really shaping up to be a master piece.
    Keep up the good work, the open-mindedness and being so detailed oriented.

  14. Dadasss says:

    Very cool!

  15. Dadasss says:

    Question :
    In new game we have only Western front? No East?

  16. tom says:

    @Dada: we are starting with western front this time, east should be coming later as an expansion (DLC)

  17. Dadasss says:

    Thx for answer! Good luck!

  18. Sourdust says:

    So… what’s the story with attachments? I notice:
    – you can have at least 3 per unit (max 3?)
    – some are solid and some are greyed out (active vs suppressed?)
    – you can double-up; at least one unit on the screenie has a doubled recon attachment
    – doesn’t look like there are any differences between the attachments available for Germany and Western Allies – both appear to have AT, Eng, Recon, Assault Gun or Tank, and Flak attachments. I always liked how UoC created a radically different feel for German and Russian armies through the different attachments for each. Would be a pity if this sense of playing very different armies was lost…

  19. tom says:

    @Sourdust: only US units get 3x specialists (=attachments).

    I am currently running some code that gives random characteristics to units, basically for testing purposes. This is is why the Germans can have multiple specialists in the screenshot, but the actual design doesn’t allow it. Other factions still get 1x specialist like before.

    Regarding “doubling up”: I have an interesting concept written up, where you can double (even triple) specialists. It’s hard to say whether this will survive testing though, so I don’t want to commit either way.

    Different armies play differently: this is still our core design goal, no worries! 🙂

  20. Jarin says:

    Looks very good.

  21. JohnMa says:

    I know the focus is on terrain and units but will the ownership (or capture) of certain towns/cities offer a unit or supply bonus?

    Looking forward to the final product 🙂

  22. Jigsawn says:

    Looking forward to the new game, the new additions should add a lot more depth whilst retaining the core fun. My only concern right now is the visuals, with the new 3d models for troops its way harder at a glance to read the battlefield based on your screenshots. The icons in UOC were great because it was so easy to identify different unit and infantry types quickly, helping you to plan your battle. Whilst I understand you want to go realistic and improve the graphics, you are sacrificing some of the originals simplicity and easiness to understand ( note I am just referring to the units, the terrain is fine.)

    Based on the screenshots it seems like infantry is the biggest problem, they make the screen look very busy. Tanks look ok to me though.

    Maybe a solution would be to have a view mode you can toggle, which shows unit icons like the first game. These would appear on top of the 3d models.

  23. Jigsawn says:

    Also as someone mentioned attachments above, I wanted to raise a problem I had with the original game which I hope you will address in this. The unit attachments were poorly communicated for new players. Although I did read the manual, I didn’t really appreciate how important those tiny icons were next to units, indicating an attached tank, artillery, etc. It took me quite a while to realise how significant they were, and learn the icons for each one. I kept having to click on every unit to double check what was attached. Of course your 3d models will help with this, which then contradicts my earlier post about reintroducing unit icons! But anyway, a better way to communicate unit attachments visually would be good. In those combat situations, I didn’t realise a lot of the time that I was taking extra damage because of the attachments, so maybe communicating their impact during combat would be a good idea too, via animation/messages/sound effects – the roll of tank treads, the boom of artillery.

    One note about fog of war, it might be interesting if hills blocked vision of fog of war beyond them, therefore making high ground extra important for scouting purposes. Also for front lines, perhaps hills or mountains should remain in enemy possession until you scale them, or capture hexes on opposite sides of them, reflecting the power that high ground had in ww2 battles.

  24. tom says:

    @Jarin, JohnMa: Cheers!

    @Jigsawn: sure busts are easier to read (which is why we used them in the first game) but I feel that full models are more immersive. We will be using colors and poses to distinguish between infantry types (or even small flags in the case of New Zealanders etc.) It should work – remember you’re only looking at a single infantry type at the moment.

    We plan to include specialist (=attachments) effects into the combat sequence, almost exactly as you described. The snag: combat sequence is around one second (or so… it varies) so there’s a limit to how much info can be added.

    Re: FoW, mountains indeed block FoW visibility. We hadn’t considered the other effects: the scale is 15km/hex and I feel the effect of high ground at that distance does not justify any further bonuses.

  25. Jigsawn says:

    Thanks for the reply Tom. Sounds good, for the unit visuals it’ll be easier for you to get folks feedback once you have final graphics anyway and they’re playing, rather than looking at screenshots.

    I’d imagine for the specialists even a short anim as you have might be enough, the main thing is knowing that its not just standard infantry you’re up against. For unite with specialists attached I would suggest if you are only using icons to reflect that, then make the icons relevant to the attachment, like a little tank icon or artillery gun. That way players don’t have to learn what different pips etc mean. I still struggle after lots of playtime to remember what icon is what specialist, which makes getting an overview of the battlefields true strength quite tricky.

    High ground, yep sounds good! Really looking forward to how it plays with fog of war. Will you be able to see supply lines through fog of war? If not then formulating early strategies will be much harder as I at least plan a lot around cutting off enemy supply, often in far off sections of the map that are poorly defended.

    Loved UOC, only picked it up a few weeks ago and played it esclusively until Id done both campaigns, now mopping up the brilliant victories. Kudos for the balancing and please keep the challenge in the new one. Stuff like Stalingrad which seems impossible is so satisfying when you figure out the best approach. I think your changes in the new game will help levels feel less like puzzles and force more on the fly strategizing, which is good. Although there is a good satisfaction when you finally figure out the right approach. I got stuck on getting a brilliant victory on 2nd Karkov for two days, but when I finally figured out the killing blows needed it was brilliant (I chopped the Soviets in two and forced my tanks north). My favourite strategy game of recent years, simple on the surface but with lots of depth! Good job!

  26. tom says:

    Thanks for the kudos 🙂

    There is a fairly elaborate set of rules that allow you to see some of the information about what’s behind the FoW. If we just blanked everything out, it would indeed be impossible to formulate strategies. It would also be unrealistic, because commanders would typically have at least some idea about the numbers and capabilities of the enemy forces facing them.

    A complete surprise (an operational-scale ambush!) should be a rare and exceptional thing, not an everyday occurence.

  27. Víctor García says:

    Thank you very much for the original game.
    Is it possible I am the only one (and Jigsawn ) that does not agree with the visual evolution?

    Do not lose the focus of what UOC really is .
    Unity of Command is a turn based strategy game and people who really like strategy game hate arcade like games.
    Arcade like appearance is a maketing matter that could drive away potential buyers looking for real strategic. Why do people name as strategic what really is tactical?
    I have played more than 4500 battles of Panzer and Peoples General (and lately Open General) in its different versions and times (yes, more than 4500).
    When I found Unity of Command I thouhgt, this is simply perfect, sorry not exactly perfect but has what General’s family lack.
    What is that UOC has? Supplies. WWII was more than anythig a supply war.
    The master keys of UOC are:
    1- Supplies
    2- 20Km hexagons (Any attempt to model a strategy game with a smaller hexagon is a tactical game not possible to simulate)
    3- Units reorganization capacity.

    What are the main UOC shortcomings?

    1-Clearly and in the first place the capacity to hide units and mask their strenght. The so called Fog of War. But Beware! Do not converts UOC in an arcade game again. Discovering a hide unit is a real strange situation when we use a 20Km hexagon and the size of unit that ocupies that territory. Yes, reconnaissance did exist in 1940’s. So add reconnaissance and manage with care the Fog of war. General’s family of games treats very badly the discovering of hiden units, those situations are treated like you discover a thief in a dark roon in your house. The thief hurts you without choice. No, in that size of territory it could not happend. Do it better than General’s family.

    2- Reconnaissance. Not only special army units (ground and air), you should add some kind of information from (intelligence) spies. Genral

    3- Unit reorganization should have the ability to preserve the experience of troops (steps in UOC) and calculate the right result for the resulting unit.

    4- The ability of using an even more symbolic representation of terrain and units. It will gave the game a more professional feel. Or add an optión to change from thoses giant dolls to a more serios icons.

    Again, of course all this is a matter of marketing but implemet those features and you will win the battle for a war simulator. Undestand who is your target market, perhaps I am only an specialized customer, an army man.

    In all cases, tank you very much for this wonderful game.

  28. karis says:

    Hey Tom,
    no news for the last 3 month 😉
    how are you guys doing ?

  29. tom says:

    @karis: there’s actually a lot of new stuff to show. I will be posting next week, was on a ski trip until yesterday 🙂

    @Victor: I agree on FoW, there is no point in simply “turning the lights off”.

    There are several ways to peek through FoW in UoC2 but, specifically, we *do not* use PG-style reconnaissance units (we do keep the recon specialists though). The intel mechanics try to be more realistic and model air recon, signals intel, prisoners etc.