74 lines
1014 B
C#
74 lines
1014 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using Frontend;
|
|
|
|
namespace WorldOfPeacecraft
|
|
{
|
|
public abstract class Entity : IPositionable
|
|
{
|
|
public int Id;
|
|
public int PosX;
|
|
public int PosY;
|
|
public string Desc;
|
|
public bool Busy;
|
|
|
|
public Entity (int id, int posX, int posY, string desc, bool busy)
|
|
{
|
|
this.SetId (id);
|
|
this.SetPosX (posX);
|
|
this.SetPosY (posY);
|
|
this.SetDesc (desc);
|
|
this.SetBusy (busy);
|
|
}
|
|
|
|
public void SetId (int id)
|
|
{
|
|
this.Id = id;
|
|
}
|
|
|
|
public int GetId ()
|
|
{
|
|
return Id;
|
|
}
|
|
|
|
public void SetPosX (int x)
|
|
{
|
|
this.PosX = x;
|
|
}
|
|
|
|
public int getXPosition ()
|
|
{
|
|
return PosX;
|
|
}
|
|
|
|
public void SetPosY (int y)
|
|
{
|
|
this.PosY = y;
|
|
}
|
|
|
|
public int getYPosition ()
|
|
{
|
|
return PosY;
|
|
}
|
|
|
|
public void SetDesc (string desc)
|
|
{
|
|
this.Desc = desc;
|
|
}
|
|
|
|
public void SetBusy (bool busy)
|
|
{
|
|
this.Busy = busy;
|
|
}
|
|
|
|
public bool GetBusy ()
|
|
{
|
|
return Busy;
|
|
}
|
|
|
|
}
|
|
}
|