using UnityEngine;
using System.Collections;

public class Box_Rotate : MonoBehaviour {

	public float movmentSpeed = 20f;

	public CharacterController Player;



	// Use this for initialization
	void Start () {

	
	}
	
	// Update is called once per frame
	void Update () {


		if(Input.GetAxis("Horizontal") != 0 || Input.GetAxis("Vertical") != 0 || !Player.isGrounded ){

			transform.Rotate(0,movmentSpeed * Time.deltaTime ,0);
		}

	
	}
}
