Type: Number
Default value: 500
Overview
The distance at which the ai object can see. For example, in the fog vision worse than on a clear day.
Examples
Сhange distance at which the ai object can see
local newAI = require('classes.SimpleAI').newAI -- enemy instance local enemy = newAI({group = mainGroup, img = "snailWalk1.png", x = halfW-50, y = display.contentHeight-500, ai_type = "patrol"}) enemy.visionLength = 100 -- change distance at which the ai object can see