new adjustments
This commit is contained in:
@@ -122,9 +122,9 @@ void GuiHandSelf::Repos()
|
||||
{
|
||||
float dist = 180.0f / cards.size();
|
||||
if (dist > 20)
|
||||
dist = 20.0;
|
||||
dist = 18.0;//20.0
|
||||
else
|
||||
y = 40.0;
|
||||
y = 35.0;//40.0
|
||||
for (vector<CardView*>::iterator it = cards.begin(); it != cards.end(); ++it)
|
||||
{
|
||||
(*it)->x = ClosedRowX;
|
||||
|
||||
@@ -62,12 +62,20 @@ void GuiPlay::HorzStack::Enstack(CardView* card)
|
||||
{
|
||||
card->x = x + baseX;
|
||||
card->y = y + baseY;
|
||||
if (total < 8)
|
||||
/*if (total < 8)
|
||||
x += CARD_WIDTH;
|
||||
else if (total < 16)
|
||||
x += (SCREEN_WIDTH - 200 - baseX) / total;
|
||||
else
|
||||
x += (SCREEN_WIDTH - 50 - baseX) / total;
|
||||
x += (SCREEN_WIDTH - 50 - baseX) / total;*/
|
||||
|
||||
// new adjustment
|
||||
if (total < 8)
|
||||
x += CARD_WIDTH;
|
||||
else if (total < 24)
|
||||
x += (SCREEN_WIDTH - 200 - baseX) / total;
|
||||
else
|
||||
x += (SCREEN_WIDTH - 70 - baseX) / total;
|
||||
}
|
||||
|
||||
void GuiPlay::VertStack::Enstack(CardView* card)
|
||||
@@ -83,9 +91,10 @@ void GuiPlay::VertStack::Enstack(CardView* card)
|
||||
|
||||
card->x = x + baseX;
|
||||
card->y = y + baseY;
|
||||
y += 12;
|
||||
if (++count == total - 1 && y == 12)
|
||||
y += 12;
|
||||
y += 8;
|
||||
if (++count == total - 1 && y == 8)
|
||||
y += 8;
|
||||
//last value += 12...
|
||||
}
|
||||
|
||||
void GuiPlay::VertStack::Render(CardView* card, iterator begin, iterator end)
|
||||
@@ -124,13 +133,13 @@ void GuiPlay::BattleField::reset(float x, float y)
|
||||
void GuiPlay::BattleField::EnstackAttacker(CardView* card)
|
||||
{
|
||||
//card->x = CARD_WIDTH + 20 + (currentAttacker * (HORZWIDTH) / (attackers+1));
|
||||
card->x = x + baseX;
|
||||
card->x = x-12 + baseX;
|
||||
if (attackers+1 < 8)
|
||||
x += CARD_WIDTH;
|
||||
else if (attackers+1 < 16)
|
||||
else if (attackers+1 < 24)
|
||||
x += (SCREEN_WIDTH - 200 - baseX) / attackers+1;
|
||||
else
|
||||
x += (HORZWIDTH - 50 - baseX) / attackers+1;
|
||||
x += (HORZWIDTH - baseX) / attackers+1;
|
||||
|
||||
card->y = baseY + (card->card->getObserver()->getView()->getRenderedPlayer() == card->card->controller() ? 20 + y : -20 - y);
|
||||
++currentAttacker;
|
||||
|
||||
Reference in New Issue
Block a user