/// <summary>
        /// Determines if the position is in vision of this object.
        /// </summary>
        /// <param name="tick">The tick to check</param>
        /// <param name="positionManager">The position manager</param>
        /// <returns>If the object is in the vision range.</returns>
        public bool IsInVisionRange(GameTick tick, PositionManager positionManager)
        {
            var pos = position.GetPositionAt(tick);

            return(Vector2.Distance(pos.ToVector2(), positionManager.GetPositionAt(tick).ToVector2()) < _visionRange);
        }
 public VisionManager(IEntity parent, float visionRange) : base(parent)
 {
     this._visionRange = visionRange;
     this.position     = parent.GetComponent <PositionManager>();
 }