using UnityEngine;
using System.Collections;

public class AnimateSpotlight : MonoBehaviour
{
    public Light spotlight;

    private float m_spotAngle;

    private void Awake()
    {
        m_spotAngle = spotlight.spotAngle;
    }

    private void Start()
    {
    }

    private void Update()
    {
        spotlight.spotAngle = m_spotAngle + Mathf.PingPong(Time.time, 5f);
    }

}
