@@ -25,8 +25,8 @@ struct GuiAvatar: public GuiStatic
|
|||||||
BOTTOM_RIGHT
|
BOTTOM_RIGHT
|
||||||
} Corner;
|
} Corner;
|
||||||
|
|
||||||
static const unsigned Width = 35;
|
static const unsigned Width = 32;//35
|
||||||
static const unsigned Height = 50;
|
static const unsigned Height = 45;//50
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
int avatarRed;
|
int avatarRed;
|
||||||
|
|||||||
@@ -20,16 +20,16 @@ GuiAvatars::GuiAvatars(DuelLayers* duelLayers) :
|
|||||||
Add(opponent = NEW GuiAvatar(0, 0, false, mpDuelLayers->getRenderedPlayerOpponent(), GuiAvatar::TOP_LEFT, this));
|
Add(opponent = NEW GuiAvatar(0, 0, false, mpDuelLayers->getRenderedPlayerOpponent(), GuiAvatar::TOP_LEFT, this));
|
||||||
opponent->zoom = 0.9f;
|
opponent->zoom = 0.9f;
|
||||||
//opponentExile
|
//opponentExile
|
||||||
Add(opponentExile = NEW GuiExile(-30 + GuiAvatar::Width * 1.2 - GuiGameZone::Width / 2, 35 + GuiGameZone::Height - 10,
|
Add(opponentExile = NEW GuiExile(-30 + GuiAvatar::Width * 1.2f - GuiGameZone::Width / 2, 35 + GuiGameZone::Height - 10,
|
||||||
false, mpDuelLayers->getRenderedPlayerOpponent(), this));
|
false, mpDuelLayers->getRenderedPlayerOpponent(), this));
|
||||||
//opponentGraveyard
|
//opponentGraveyard
|
||||||
Add(opponentGraveyard = NEW GuiGraveyard(5 + GuiAvatar::Width * 1.4 - GuiGameZone::Width / 2, 5, false,
|
Add(opponentGraveyard = NEW GuiGraveyard(5 + GuiAvatar::Width * 1.4f - GuiGameZone::Width / 2, 5, false,
|
||||||
mpDuelLayers->getRenderedPlayerOpponent(), this));
|
mpDuelLayers->getRenderedPlayerOpponent(), this));
|
||||||
//opponentHand
|
//opponentHand
|
||||||
Add(opponentHand = NEW GuiOpponentHand(-15 + GuiAvatar::Width * 1.4 - GuiGameZone::Width / 2, 35 + GuiGameZone::Height - 10, false,
|
Add(opponentHand = NEW GuiOpponentHand(-15 + GuiAvatar::Width * 1.4f - GuiGameZone::Width / 2, 35 + GuiGameZone::Height - 10, false,
|
||||||
mpDuelLayers->getRenderedPlayerOpponent(), this));
|
mpDuelLayers->getRenderedPlayerOpponent(), this));
|
||||||
//opponentLibrary
|
//opponentLibrary
|
||||||
Add(opponentLibrary = NEW GuiLibrary(5 + GuiAvatar::Width * 1.4 - GuiGameZone::Width / 2, 5 + GuiGameZone::Height + 5, false,
|
Add(opponentLibrary = NEW GuiLibrary(5 + GuiAvatar::Width * 1.4f - GuiGameZone::Width / 2, 5 + GuiGameZone::Height + 5, false,
|
||||||
mpDuelLayers->getRenderedPlayerOpponent(), this));
|
mpDuelLayers->getRenderedPlayerOpponent(), this));
|
||||||
|
|
||||||
observer->getCardSelector()->Add(self);
|
observer->getCardSelector()->Add(self);
|
||||||
@@ -145,12 +145,12 @@ void GuiAvatars::Update(float dt)
|
|||||||
void GuiAvatars::Render()
|
void GuiAvatars::Render()
|
||||||
{
|
{
|
||||||
JRenderer * r = JRenderer::GetInstance();
|
JRenderer * r = JRenderer::GetInstance();
|
||||||
float w = 54;
|
float w = 52;
|
||||||
float h = 54;
|
float h = 52;
|
||||||
if (opponent == active)
|
if (opponent == active)
|
||||||
{
|
{
|
||||||
r->FillRect(opponent->actX, opponent->actY, 40 * opponent->actZ, h+20 * opponent->actZ, ARGB(200,0,0,0));
|
r->FillRect(opponent->actX, opponent->actY, 34 * opponent->actZ, h+22 * opponent->actZ, ARGB(200,0,0,0));
|
||||||
r->FillRect(opponent->actX, opponent->actY, w * opponent->actZ, h * opponent->actZ, ARGB(200,0,0,0));
|
r->FillRect(opponent->actX, opponent->actY, (w * opponent->actZ)-1, (h * opponent->actZ)+2, ARGB(200,0,0,0));
|
||||||
}
|
}
|
||||||
else if (self == active)
|
else if (self == active)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -91,9 +91,9 @@ void GuiPlay::VertStack::Enstack(CardView* card)
|
|||||||
|
|
||||||
card->x = x + baseX;
|
card->x = x + baseX;
|
||||||
card->y = y + baseY;
|
card->y = y + baseY;
|
||||||
y += 10;
|
y += 9;
|
||||||
if (++count == total - 1 && y == 10)
|
if (++count == total - 1 && y == 9)
|
||||||
y += 10;
|
y += 9;
|
||||||
//last value += 12...
|
//last value += 12...
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -133,7 +133,7 @@ void GuiPlay::BattleField::reset(float x, float y)
|
|||||||
void GuiPlay::BattleField::EnstackAttacker(CardView* card)
|
void GuiPlay::BattleField::EnstackAttacker(CardView* card)
|
||||||
{
|
{
|
||||||
//card->x = CARD_WIDTH + 20 + (currentAttacker * (HORZWIDTH) / (attackers+1));
|
//card->x = CARD_WIDTH + 20 + (currentAttacker * (HORZWIDTH) / (attackers+1));
|
||||||
card->x = x-6 + baseX;
|
card->x = x-4 + baseX;
|
||||||
if (attackers+1 < 8)
|
if (attackers+1 < 8)
|
||||||
x += CARD_WIDTH;
|
x += CARD_WIDTH;
|
||||||
else if (attackers+1 < 24)
|
else if (attackers+1 < 24)
|
||||||
|
|||||||
@@ -88,11 +88,11 @@ void GuiAvatar::Render()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (player->getObserver()->currentPlayer == player)
|
if (player->getObserver()->currentPlayer == player)
|
||||||
r->DrawRect(x0 - 1, y0 - 1, 36 * actZ, 51 * actZ, ARGB((int)actA, 0, 255, 0));
|
r->DrawRect(x0 - 1, y0 - 1, (Width+1) * actZ, (Height+1) * actZ, ARGB((int)actA, 0, 255, 0));
|
||||||
else if (player->getObserver()->currentActionPlayer == player)
|
else if (player->getObserver()->currentActionPlayer == player)
|
||||||
r->DrawRect(x0, y0, 34 * actZ, 49 * actZ, ARGB((int)actA, 0, 0, 255));
|
r->DrawRect(x0, y0, (Width-1) * actZ, (Height-1) * actZ, ARGB((int)actA, 0, 0, 255));
|
||||||
if (player->getObserver()->isInterrupting == player)
|
if (player->getObserver()->isInterrupting == player)
|
||||||
r->DrawRect(x0, y0, 34 * actZ, 49 * actZ, ARGB((int)actA, 255, 0, 0));
|
r->DrawRect(x0, y0, (Width-1) * actZ, (Height-1) * actZ, ARGB((int)actA, 255, 0, 0));
|
||||||
|
|
||||||
//Life
|
//Life
|
||||||
char buffer[10];
|
char buffer[10];
|
||||||
|
|||||||
Reference in New Issue
Block a user