using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class TitleOrbit : MonoBehaviour {
	public Transform target;
	public float speed;
	public float rotateSpeed;


	// Use this for initialization
	void Start () {
	}

	// Update is called once per frame
	void Update () {
		transform.Rotate(0f, -rotateSpeed * Time.deltaTime, 0f);
		//angle -= (speed * Time.deltaTime) * (distance / 1000f);
		//Vector3 newPos = new Vector3(Mathf.Sin(angle) * -distance, 0f, Mathf.Cos(angle) * -distance);
		transform.RotateAround(target.position, Vector3.up, -speed * Time.deltaTime);

	}
}
