using System;
using System.Text;

namespace ActionGame.GameResources.Models
{
    public class DoorDefinition
    {
        public Int32 X { get; set; }
        public Int32 Y { get; set; }
        public Int32 DestinationMapKey { get; set; }
        public Int32 DestinationCellX { get; set; }
        public Int32 DestinationCellY { get; set; }
        public Int32 DestinationTileX { get; set; }
        public Int32 DestinationTileY { get; set; }


        public String ToCsvString()
        {
            StringBuilder line = new StringBuilder();

            line.Append("Door");
            line.Append("|");
            line.Append(X);
            line.Append('|');
            line.Append(Y);
            line.Append('|');
            line.Append(DestinationMapKey);
            line.Append('|');
            line.Append(DestinationCellX);
            line.Append('|');
            line.Append(DestinationCellY);
            line.Append('|');
            line.Append(DestinationTileX);
            line.Append('|');
            line.Append(DestinationTileY);

            return line.ToString();
        }

    }
}
