// SSCLightMap is the equivalent of SSCVisionMap with several sources.
SSCLightMap is the equivalent of SSCVisionMap with several sources.
// SSCLightMap is the equivalent of SSCVisionMap with several sources .
func (fov *FOV) SSCLightMap(srcs []gruid.Point, maxDepth int, passable func(p gruid.Point) bool, diags bool) []gruid.Point {
	if fov.ShadowCasting == nil {
		fov.ShadowCasting = make([]bool, fov.Capacity)
	}
	for i := range fov.ShadowCasting {
		fov.ShadowCasting[i] = false
	}
	fov.passable = passable
	fov.Visibles = fov.Visibles[:0]
	for _, src := range srcs {
		if !src.In(fov.Rg) {
			continue
		}
		fov.sscVisionMap(src, maxDepth, diags)
	}
	return fov.Visibles
}
func ( fov * FOV ) SSCLightMap ( srcs [ ] gruid . Point , maxDepth int , passable func ( p gruid . Point ) bool , diags bool ) [ ] gruid . Point { if fov . ShadowCasting == nil { fov . ShadowCasting = make ( [ ] bool , fov . Capacity ) } for i := range fov . ShadowCasting { fov . ShadowCasting [ i ] = false } fov . passable = passable fov . Visibles = fov . Visibles [ : 0 ] for _ , src := range srcs { if ! src . In ( fov . Rg ) { continue } fov . sscVisionMap ( src , maxDepth , diags ) } return fov . Visibles }
SSCLightMap is the equivalent of SSCVisionMap with several sources.
SSCLightMap is the equivalent of SSCVisionMap with several sources .