public void animateEntity(Entity entity, int x, int y)
	{
		// this.game.stroke(0, 0, 255);
		// this.game.rect(x * this.game.c_tilesize, y * this.game.c_tilesize, this.game.c_tilesize,
		// this.game.c_tilesize);

		// moving
		if (entity.busy > 0 && entity.center < 2)
		{
			entity.xold = x - entity.dx;
			entity.yold = y - entity.dy;

			float progress = ((float) entity.speed - entity.busy) / entity.speed;
			entity.xprogress = (int) (entity.dx * progress * this.game.c_tilesize);
			entity.yprogress = (int) (entity.dy * progress * this.game.c_tilesize);

			this.game.image(this.get(entity.resourceId), entity.xold * this.game.c_tilesize + entity.xprogress,
			        entity.yold * this.game.c_tilesize + entity.yprogress, this.game.c_tilesize, this.game.c_tilesize);
		}
		// standing around
		else
		{
			entity.xprogress = 0;
			entity.yprogress = 0;

			this.game.image(ResourceLoader.getImg(entity.resourceId), x * this.game.c_tilesize, y
			        * this.game.c_tilesize, this.game.c_tilesize, this.game.c_tilesize);
		}
	}