Field of View

An asset by luisboch
The page banner background of a mountain and forest
Field of View thumbnail image
Field of View thumbnail image
Field of View thumbnail image
Field of View thumbnail image
Field of View hero image

Quick Information

0 ratings
Field of View icon image
luisboch
Field of View

Node that allow use of "view area", can be used with IA to identify enemy, used with security camera etc, check the Demo (Demo.tscn and Camera.tscn under demo folder).

Supported Engine Version
3.4
Version String
v2.3.1
License Version
MIT
Support Level
community
Modified Date
1 year ago
Git URL
Issue URL

Godot Field Of View

Godot script that allow use of Field of View in (currently) 2d game.

Features

  • Hight customizable
  • Multiple targets
  • Target defined by groups
  • Precision can be defined
  • Update delay (faster will use more cpu)

How to install

Can be installed from asset lib

How to use

  • Enable plugin under project settings
  • Add Field of View node
  • Configure it (And add target groups to track, without it, plugin will not work as expected!)
  • From Character node read "in_danger_area" and "in_warn_area" properties to get the visible nodes, or,
  • Use events "target_enter" or "target_exit" to work;

Configurations

  • View Detail: Int, Indicates the number of rays created to check the Fov area, greater value will be more precise with cpu cost.
  • Field of View: In degrees, configure the view angle
  • Warn distance: Float, view distance
  • Danger distance: Float, view distance to consider danger, must be lower than Warn distance
  • Show Fov: Bool, use to view the rays created
  • Show Target line: Bool, draw line to target?
  • Fov Color: Color, when Show Fov is true, this define the color used to draw rays
  • Fov Warn Color: Color, when Show Fov is true, this define the color used to draw rays when is "warn" state
  • Fov Danger Color: Color, when Show Fov is true, this define the color used to draw rays when is "danger" state
  • Frequency: Float, frequency to update view area, lower will update fast with cpu cost, default value is 0.5
  • Target Groups Array groups to track, required at least one.
  • Collision Mask

Current state

README Screenshot 1

README Screenshot 2

README Screenshot 3

README Screenshot 4

README Screenshot 5

README Screenshot 6

README Screenshot 7

README Screenshot 8

Previews:

README Preview 1

README Preview 2

README Preview 3

README Preview 4

How-To from zero

A complete how to use this plugin.

README Youtube vídeo

Node that allow use of "view area", can be used with IA to identify enemy, used with security camera etc, check the Demo (Demo.tscn and Camera.tscn under demo folder).

Reviews

0 ratings

Your Rating

Headline must be at least 3 characters but not more than 50
Review must be at least 5 characters but not more than 500
Please sign in to add a review

Quick Information

0 ratings
Field of View icon image
luisboch
Field of View

Node that allow use of "view area", can be used with IA to identify enemy, used with security camera etc, check the Demo (Demo.tscn and Camera.tscn under demo folder).

Supported Engine Version
3.4
Version String
v2.3.1
License Version
MIT
Support Level
community
Modified Date
1 year ago
Git URL
Issue URL

Open Source

Released under the AGPLv3 license

Plug and Play

Browse assets directly from Godot

Community Driven

Created by developers for developers