using Intrepid.Integration.Persistence.DTOs;
using UnityEngine;

namespace Intrepid.Gameplay.Data.Conversion
{
    public class Vector3DTOConverter : Converter<Vector3DTO, Vector3>
    {   
        public Vector3DTO Marshal(Vector3 v)
        {
            return new Vector3DTO
            { 
                X = v.x,
                Y = v.y,
                Z = v.z
            };
        }
        
        public Vector3 Unmarshal(Vector3DTO v)
        {
            return new Vector3(v.X, v.Y, v.Z);
        }
    }
}