2019-05-14 14:12:04 +02:00
|
|
|
|
using System;
|
|
|
|
|
using CzokoŚmieciarka.MonoGameView.DataModels.Interfaces;
|
2019-04-22 09:24:16 +02:00
|
|
|
|
using CzokoŚmieciarka.MonoGameView.DataModels.Interfaces.TrashCans;
|
|
|
|
|
using CzokoŚmieciarka.MonoGameView.DataModels.Models;
|
2019-04-22 16:50:40 +02:00
|
|
|
|
using Microsoft.Xna.Framework;
|
|
|
|
|
using Microsoft.Xna.Framework.Graphics;
|
|
|
|
|
using MonoGameView.DataModels.Models;
|
2019-04-22 09:24:16 +02:00
|
|
|
|
|
|
|
|
|
namespace CzokoŚmieciarka.MonoGameView.DataModels.GeneralModels.Models
|
|
|
|
|
{
|
2019-04-22 16:50:40 +02:00
|
|
|
|
public class Dump : ADump, IDrawables
|
2019-04-22 09:24:16 +02:00
|
|
|
|
{
|
|
|
|
|
public Dump(ITypeOfGarbage typeOfGarbage, int maxVolume, Coords localization) : base(typeOfGarbage, maxVolume, localization)
|
|
|
|
|
{
|
|
|
|
|
}
|
2019-04-22 16:50:40 +02:00
|
|
|
|
|
|
|
|
|
public void Draw(SpriteBatch batch, int size)
|
|
|
|
|
{
|
|
|
|
|
batch.Draw(ImageContainer.GetImage(TypeOfGarbage.GarbageType.ToString()), new Rectangle(Coords.X * 500 / size, Coords.Y * 500 / size, 500 / size, 500 / size), Color.White);
|
2019-05-14 14:12:04 +02:00
|
|
|
|
batch.Draw(ImageContainer.GetImage(TypeOfGarbage.GarbageType.ToString()+"Bar"), new Rectangle(Coords.X * 500 / size, Coords.Y * 500 / size, (int)Math.Round(FillPercent * 500) / size, 50 / size), Color.White);
|
2019-04-22 16:50:40 +02:00
|
|
|
|
}
|
2019-04-23 06:32:35 +02:00
|
|
|
|
|
|
|
|
|
public override object Clone()
|
|
|
|
|
{
|
|
|
|
|
return new Dump((ITypeOfGarbage)TypeOfGarbage.Clone(), MaxVolume, (Coords)Coords.Clone());
|
|
|
|
|
|
|
|
|
|
}
|
2019-04-22 09:24:16 +02:00
|
|
|
|
}
|
|
|
|
|
}
|