Character only moves on world axis

Trying to get the character to move with the camera but for some reason it only moves on the world coordinates.

using UnityEngine;
using System.Collections;

public class NewBehaviourScript : MonoBehaviour {

    public float speed = 6.0f;
    public float jumpSpeed = 8.0f;
    public float gravity = 20.0f;

    private Quaternion Rotation;

    private Vector3 moveDirection = Vector3.zero;
    private CharacterController controller;

    void Awake()
    {
        controller = GetComponent<CharacterController>() as CharacterController;
        TP_Camera.UseExistingOrCreateNewMainCamera ();
    }

    void Update()
    {
        RotateTowardsMoveDirection ();
        ProcessMotion ();
    }

    void ProcessMotion()
    {
        if (controller.isGrounded)
        {
            moveDirection = new Vector3 (Input.GetAxis ("Horizontal"), 0, Input.GetAxis ("Vertical"));
            moveDirection *= speed;

            if (Input.GetButton ("Jump"))
                moveDirection.y = jumpSpeed;
        }

        moveDirection.y -= gravity * Time.deltaTime;
        controller.Move (moveDirection * Time.deltaTime);
    }

    public void RotateTowardsMoveDirection()
    {
        if (moveDirection.x != 0 || moveDirection.z != 0)
        {
            if (moveDirection.z > 0)
            {
                if (moveDirection.x > 0)
                    Rotation = Quaternion.Euler (0, Camera.main.transform.rotation.eulerAngles.y + 45, 0);
                else if (moveDirection.x < 0)
                    Rotation = Quaternion.Euler (0, Camera.main.transform.rotation.eulerAngles.y + 305, 0);
                else
                    Rotation = Quaternion.Euler (0, Camera.main.transform.rotation.eulerAngles.y, 0);
            }

            else if (moveDirection.z < 0)
            {
                if (moveDirection.x > 0)
                    Rotation = Quaternion.Euler (0, Camera.main.transform.rotation.eulerAngles.y + 135, 0);
                else if (moveDirection.x < 0)
                    Rotation = Quaternion.Euler (0, Camera.main.transform.rotation.eulerAngles.y + 225, 0);
                else
                    Rotation = Quaternion.Euler (0, Camera.main.transform.rotation.eulerAngles.y + 180, 0);
            }

            else
            {
                if (moveDirection.x > 0)
                    Rotation = Quaternion.Euler (0, Camera.main.transform.rotation.eulerAngles.y + 90, 0);
                else if (moveDirection.x < 0)
                    Rotation = Quaternion.Euler (0, Camera.main.transform.rotation.eulerAngles.y + 270, 0);
                else
                    Rotation = transform.rotation;
            }
        }

        transform.rotation = Quaternion.Lerp (transform.rotation, Rotation, 0.25f);

        moveDirection = transform.TransformDirection (moveDirection);

        if (moveDirection.magnitude > 1)
            moveDirection = Vector3.Normalize (moveDirection);
    }

}

You can use transform.forward etc… these are the local axis directions of the transform.