#include "stdafx.h"
#include "SelectionCircle.h"

#include "CellWarsGameManager.h"
#include "Bacterium.h"

SelectionCircle::SelectionCircle(Bacterium *belongsToThisBacterium) : Actor()
{
	belongsToThis = belongsToThisBacterium;

	SetColor(1,1,1,1);
	ClearSpriteInfo();
	SetSize(belongsToThis->GetSize());
	SetPosition(belongsToThis->GetPosition());
	SetName("SelectionCircle");
	SetSprite("Resources/Images/selectionCircle.png");
	theWorld.Add(this, LayerEnum::SelectionCircle);

	//std::cout << "SelectionCircle " << _name << std::endl;
}

SelectionCircle::~SelectionCircle()
{
	//std::cout << "~SelectionCircle " << _name << std::endl;
}

void SelectionCircle::PreDestroy()
{
	//std::cout << "predestroy SelectionCircle " << _name << std::endl;
}

void SelectionCircle::ReceiveMessage(Message *m)
{
	Actor::ReceiveMessage(m);
}

void SelectionCircle::Render()
{
	Actor::Render();
}

void SelectionCircle::Update(float dt)
{
	Actor::Update(dt);
	
	SetSize(belongsToThis->GetSize());
	SetPosition(belongsToThis->GetPosition());
}