Skip to content

peterMcP/FOW-research

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fog of War research

I am José Antonio Prieto, student of the Bachelor’s Degree in Video Games by UPC at CITM. This content is generated for the second year’s subject Project 2, under supervision of lecturer Ricard Pillosu.

About the project

On this research of theory and code, i tried to compact the most relevant information that i found after a lot of internet diving. I explain the most used approachs of Fog Of War on some succesfull videogames, why uses them and how implement the selected approach capable of:

  • Smooth Fog of War.
  • Put players with providing visibility sight based on radius.
  • Put example "Wards" that provides visibility on larger area with life time.
  • Capable of hide desired game entities outside player visibility sight range.
  • Manage multiple spots of visibility without uggly hacks and workarounds.

Expected final result:

You can found the full article on this research website

Installing

  • Download executable demo from here
  • Unzip the downloaded file.
  • Execute the .exe inside the uncompressed folder.

Controls

  • Mouse left click: Put new players on desired position
  • Mouse right click: Put wards that provides you a larger visibility zone on desired position.
  • Keyboard W,A,S,D:: Moves instantiated player/s.
  • Keyboard UP,DOWN,LEFT,RIGHT: Moves camera around.

Debug keys

  • F1: View debug fog tile draw

Build with

Author

José Antonio Prieto

License

This project is licensed under the MIT license, see the LICENSE.md file for more details.

Acknowledgements and Webgraphy

Riot Games Article of how they implemented new Fog Of War

Fog of War - Wikipedia

Fog of War and 2D grid - StackOverflow

How efficiently implement Fog of War in realtime- Post StackExchange gamedev

Iron Marines Fog of War implementation part1

Iron Marines Fog of War implementation part2

How to implement a Fog of War chunky System

How to implement a Fog of War smooth System

Efficient Fog Of War - GameDev.net

Implementing Fog Of War throught render to texture

Implementing Fog Of War throught marching squares

"Drawing negative circles" how to draw onto texture to simulate Fog of War - StackOverFlow

Neighbour Aware tile selection

Extense list of how comercial games uses Fog of War

Fog of War on comercial games - list -

Very interesting and useful articles

2D visibility

Field of View

Roguelike vision algorithms

Dynamic 2D shadow casting

Gaussian Blurr with linear sampling

The HqX pixel art scaling algorithm

HqX scaling filter more in deepth

Upscaling pixel art with extra smooth quality

Fast circle algorithm- Bresenhams, also "midpoint" circle - StackOverFlow

Bresenham's algorithm - wikipedia

Implementing Fog of War on Unity

Marching squares - wikipedia

Fog of War on strategy games on general

Blurring on graphic carts without shaders

SDL - Blurring with texture render target trick