MCPcopy Index your code
hub / github.com/dev7355608/perfect-vision

github.com/dev7355608/perfect-vision @v4.1.20

Chat with this repo
repository ↗ · DeepWiki ↗ · release v4.1.20 ↗ · + Follow
752 symbols 1,794 edges 58 files 328 documented · 44% updated 2y agov4.1.20 · 2023-04-10★ 521 open issues
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Latest Version Foundry Version Forge Installs License

Perfect Vision (Foundry VTT Module)

Perfect Vision provides additional lighting and vision settings and lets allows you to control lighting and vision locally within the shape of a drawing. It gives you the ability to control the maximum vision and detection ranges within the area of drawings, lights, templates, and scenes.

Perfect Vision adds/exposes the following lighting and vision settings. - Global Illumination: The global light source is fully configurable with all the usual light options. - Animation Resolution: Controls the scale of the animation of the light source. - Daylight/Darkness Color: The illumination colors at Darkness Level 0 and 1 respectively. - Reveal Fog of War: Reveal the fog of war for all users. This does not override the saved fog exploration progress. - Vision Limitation: Configure the maximum range that tokens can see. - Vision Range (In light): Controls the maximum distance a token can see in illuminated areas.

A drawing allows you to change the lighting within the shape of the drawing; see Lighting tab of the drawing config. With the Fit To Walls option you can quickly fit the shape to the underlying wall structure; this is a lot faster than tracing the boundary of the structure with the polygon tool. For polygon drawings I recommend the Advanced Drawing Tools module, which makes it possible to modify polygons in case you make a mistake or need to change the shape. Each roof/level tile inherits the lighting settings of the drawing linked to it; see the Lighting setting in the Overhead tab of the tile config. By default roofs/levels use the lighting settings of the scene.

Perfect Vision improves the token visibility test such that tokens close to a wall won't be visible through the wall on the other side it. It also includes multiple performance improvements; most notably fog exploration optimizations, which eliminate lags/freezes almost entirely that occur when the fog exploration is saved.

Core symbols most depended-on inside this repo

get
called by 57
scripts/core/visibility.js
set
called by 53
scripts/utils/framebuffer.js
min
called by 51
scripts/core/ray-casting-system.js
max
called by 47
scripts/core/ray-casting-system.js
replace
called by 38
scripts/utils/shader-patcher.js
apply
called by 32
scripts/utils/texture-blur.js
from
called by 30
scripts/utils/shape.js
bind
called by 28
scripts/utils/framebuffer.js

Shape

Method 437
Function 192
Class 123

Languages

TypeScript100%

Modules by API surface

libs/glsl-optimizer.js83 symbols
scripts/core/ray-casting-system.js78 symbols
scripts/core/lighting-system.js51 symbols
libs/sskelmesh.js46 symbols
scripts/utils/smooth-mesh.js41 symbols
scripts/core/canvas-framebuffer.js33 symbols
scripts/utils/extract.js31 symbols
scripts/utils/sprite.js30 symbols
scripts/utils/shape.js28 symbols
scripts/core/point-source-shader.js24 symbols
scripts/utils/shader-patcher.js22 symbols
libs/tess2.js21 symbols

For agents

$ claude mcp add perfect-vision \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact