Skip to content

joscanper/unity_coneofsightfx

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Commandos cone of sight in Unity3D

This project shows how to implement Commandos cone of sight fx in Unity3D.

This effect is also present in other games such as Desperados, Shadow Tactics or Brawl Stars.

It is implemented using a secondary camera depth texture instead of raycasting. This camera is attached to the soldier, which allows the effect to be accurate in terms of what the character could actually see.

The cone angle can be tweaked on the ConeOfSightRenderer component (which is on the ConeOfSight object, in the Soldier prefab).

The shader works like a deferred decal so this effect would work with different terrain heights if the cube (rendered by ConeOfSight) is tall enough.

Cone of Sight demo

Assets

ToonSolider WW2 by PolygonBlacksmith

Tank by Game-Ready Studios

Oil Tank by Rakshi Games

Industrial Building by ReinforcedCC

About

Commandos cone of sight implemented in Unity3D

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published