﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using UnityEngine;
using Verse;

namespace Rimworld_Animations
{
    public class ExtendedAnimatorAnchor_Vector3 : BaseExtendedAnimatorAnchor
    {

        public ExtendedAnimatorAnchor_Vector3() : base() { }

        private Vector3 position;
        public ExtendedAnimatorAnchor_Vector3(Vector3 position) : base()
        {
            //default to altitude for layer for y
            this.position = new Vector3(position.x, AltitudeLayer.Pawn.AltitudeFor(), position.z);
        }

        public override Vector3 getDrawPos()
        {
            return position;
        }

        public override void ExposeData()
        {
            base.ExposeData();
            Scribe_Values.Look<Vector3>(ref position, "animations_anchor_position", Vector3.zero);
        }
    }
}
