using System;
using System.Collections.Generic;
using System.Windows;
using System.Windows.Controls;

namespace PlantDemo
{
    public class EntityShower
    {
        public Entity Entity { get; set; }
        public FrameworkElement Shower { get; set; }

        protected Canvas Canvas
        {
            get { return Shower.Parent as Canvas; }
        }

        public EntityShower(Entity entity)
        {
            Entity = entity;
        }

        public EntityShower(Entity entity, FrameworkElement shower)
        {
            Entity = entity;
            Shower = shower;
        }

        public virtual void UpdateShow()
        {
            Canvas.SetLeft(Shower, Entity.X);
            Canvas.SetTop(Shower, Entity.Y);
        }
    }
}
