Commit 94d1dc42 authored by nanahira's avatar nanahira

Merge branch 'master' into server

parents 99e53102 a9a19353
...@@ -408,7 +408,7 @@ void ClientField::ShowSelectCard(bool buttonok, bool chain) { ...@@ -408,7 +408,7 @@ void ClientField::ShowSelectCard(bool buttonok, bool chain) {
else if(conti_selecting) else if(conti_selecting)
mainGame->imageLoading.insert(std::make_pair(mainGame->btnCardSelect[i], selectable_cards[i]->chain_code)); mainGame->imageLoading.insert(std::make_pair(mainGame->btnCardSelect[i], selectable_cards[i]->chain_code));
else else
mainGame->btnCardSelect[i]->setImage(imageManager.tCover[0], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT)); mainGame->btnCardSelect[i]->setImage(imageManager.tCover[2], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT));
mainGame->btnCardSelect[i]->setRelativePosition(rect<s32>(startpos + i * 125, 55, startpos + 120 + i * 125, 225)); mainGame->btnCardSelect[i]->setRelativePosition(rect<s32>(startpos + i * 125, 55, startpos + 120 + i * 125, 225));
mainGame->btnCardSelect[i]->setPressed(false); mainGame->btnCardSelect[i]->setPressed(false);
mainGame->btnCardSelect[i]->setVisible(true); mainGame->btnCardSelect[i]->setVisible(true);
...@@ -494,7 +494,7 @@ void ClientField::ShowChainCard() { ...@@ -494,7 +494,7 @@ void ClientField::ShowChainCard() {
if(selectable_cards[i]->code) if(selectable_cards[i]->code)
mainGame->imageLoading.insert(std::make_pair(mainGame->btnCardSelect[i], selectable_cards[i]->code)); mainGame->imageLoading.insert(std::make_pair(mainGame->btnCardSelect[i], selectable_cards[i]->code));
else else
mainGame->btnCardSelect[i]->setImage(imageManager.tCover[0], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT)); mainGame->btnCardSelect[i]->setImage(imageManager.tCover[2], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT));
mainGame->btnCardSelect[i]->setRelativePosition(rect<s32>(startpos + i * 125, 55, startpos + 120 + i * 125, 225)); mainGame->btnCardSelect[i]->setRelativePosition(rect<s32>(startpos + i * 125, 55, startpos + 120 + i * 125, 225));
mainGame->btnCardSelect[i]->setPressed(false); mainGame->btnCardSelect[i]->setPressed(false);
mainGame->btnCardSelect[i]->setVisible(true); mainGame->btnCardSelect[i]->setVisible(true);
...@@ -549,7 +549,7 @@ void ClientField::ShowLocationCard() { ...@@ -549,7 +549,7 @@ void ClientField::ShowLocationCard() {
if(display_cards[i]->code) if(display_cards[i]->code)
mainGame->imageLoading.insert(std::make_pair(mainGame->btnCardDisplay[i], display_cards[i]->code)); mainGame->imageLoading.insert(std::make_pair(mainGame->btnCardDisplay[i], display_cards[i]->code));
else else
mainGame->btnCardDisplay[i]->setImage(imageManager.tCover[0], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT)); mainGame->btnCardDisplay[i]->setImage(imageManager.tCover[2], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT));
mainGame->btnCardDisplay[i]->setRelativePosition(rect<s32>(startpos + i * 125, 55, startpos + 120 + i * 125, 225)); mainGame->btnCardDisplay[i]->setRelativePosition(rect<s32>(startpos + i * 125, 55, startpos + 120 + i * 125, 225));
mainGame->btnCardDisplay[i]->setPressed(false); mainGame->btnCardDisplay[i]->setPressed(false);
mainGame->btnCardDisplay[i]->setVisible(true); mainGame->btnCardDisplay[i]->setVisible(true);
......
...@@ -1130,22 +1130,25 @@ void Game::DrawThumb(code_pointer cp, position2di pos, std::unordered_map<int, i ...@@ -1130,22 +1130,25 @@ void Game::DrawThumb(code_pointer cp, position2di pos, std::unordered_map<int, i
void Game::DrawDeckBd() { void Game::DrawDeckBd() {
wchar_t textBuffer[64]; wchar_t textBuffer[64];
//main deck //main deck
driver->draw2DRectangle(Resize(310, 137, 797, 157), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000); driver->draw2DRectangle(Resize(310, 137, 410, 157), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(309, 136, 797, 157)); driver->draw2DRectangleOutline(Resize(309, 136, 410, 157));
DrawShadowText(textFont, dataManager.GetSysString(1330), Resize(315, 137, 410, 157), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(textFont, dataManager.GetSysString(1330), Resize(315, 137, 410, 157), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.current_deck.main.size()], Resize(380, 138, 440, 158), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.current_deck.main.size()], Resize(380, 138, 440, 158), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true);
//type count 2DRectangle
driver->draw2DRectangle(Resize(638, 137, 797, 157), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(637, 136, 797, 157));
//monster count //monster count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1312)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 3) - (25 * 3), 137, 797 - (55 * 2) - (25 * 3), 157), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(645, 136, 645+14+3/8, 156), recti(0, 0, 23, 32), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.main, TYPE_MONSTER)], Resize(797 - (55 * 2) - (25 * 3), 138, 797 - (55 * 2) - (25 * 2), 158), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.main, TYPE_MONSTER)], Resize(670, 137, 690, 157), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
//spell count //spell count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1313)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 2) - (25 * 2), 137, 797 - (55 * 1) - (25 * 2), 157), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(695, 136, 695+14+3/8, 156), recti(23, 0, 46, 32), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.main, TYPE_SPELL)], Resize(797 - (55 * 1) - (25 * 2), 138, 797 - (55 * 1) - (25 * 1), 158), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.main, TYPE_SPELL)], Resize(720, 137, 740, 157), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
//trap count //trap count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1314)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 1) - (25 * 1), 137, 797 - (55 * 0) - (25 * 1), 157), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(745, 136, 745+14+3/8, 156), recti(46, 0, 69, 32), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.main, TYPE_TRAP)], Resize(797 - (55 * 0) - (25 * 1), 138, 797 - (55 * 0) - (25 * 0), 158), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.main, TYPE_TRAP)], Resize(770, 137, 790, 157), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
driver->draw2DRectangle(Resize(310, 160, 797, 436), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000); driver->draw2DRectangle(Resize(310, 160, 797, 436), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(309, 159, 797, 436)); driver->draw2DRectangleOutline(Resize(309, 159, 797, 436));
...@@ -1164,26 +1167,29 @@ void Game::DrawDeckBd() { ...@@ -1164,26 +1167,29 @@ void Game::DrawDeckBd() {
driver->draw2DRectangleOutline(Resize(313 + (i % lx) * dx, 163 + (i / lx) * 68, 359 + (i % lx) * dx, 228 + (i / lx) * 68)); driver->draw2DRectangleOutline(Resize(313 + (i % lx) * dx, 163 + (i / lx) * 68, 359 + (i % lx) * dx, 228 + (i / lx) * 68));
} }
//extra deck //extra deck
driver->draw2DRectangle(Resize(310, 440, 797, 460), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000); driver->draw2DRectangle(Resize(310, 440, 410, 460), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(309, 439, 797, 460)); driver->draw2DRectangleOutline(Resize(309, 439, 410, 460));
DrawShadowText(textFont, dataManager.GetSysString(1331), Resize(315, 440, 410, 460), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(textFont, dataManager.GetSysString(1331), Resize(315, 440, 410, 460), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.current_deck.extra.size()], Resize(380, 441, 440, 461), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.current_deck.extra.size()], Resize(380, 441, 440, 461), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true);
//type count 2DRectangle
driver->draw2DRectangle(Resize(582, 440, 797, 460), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(581, 439, 797, 460));
//fusion count //fusion count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1056)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 4) - (25 * 4), 440, 797 - (55 * 3) - (25 * 4), 460), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(595, 440, 595+14+3/8, 460), recti(0, 32, 23, 64), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.extra, TYPE_FUSION)], Resize(797 - (55 * 3) - (25 * 4), 441, 797 - (55 * 3) - (25 * 3), 461), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.extra, TYPE_FUSION)], Resize(620, 440, 640, 460), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
//synchro count //synchro count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1063)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 3) - (25 * 3), 440, 797 - (55 * 2) - (25 * 3), 460), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(645, 440, 645+14+3/8, 460), recti(23, 32, 46, 64), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.extra, TYPE_SYNCHRO)], Resize(797 - (55 * 2) - (25 * 3), 441, 797 - (55 * 2) - (25 * 2), 461), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.extra, TYPE_SYNCHRO)], Resize(670, 440, 690, 460), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
//xyz count //XYZ count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1073)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 2) - (25 * 2), 440, 797 - (55 * 1) - (25 * 2), 460), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(695, 440, 695+14+3/8, 460), recti(46, 32, 69, 64), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.extra, TYPE_XYZ)], Resize(797 - (55 * 1) - (25 * 2), 441, 797 - (55 * 1) - (25 * 1), 461), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.extra, TYPE_XYZ)], Resize(720, 440, 740, 460), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
//link count //link count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1076)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 1) - (25 * 1), 440, 797 - (55 * 0) - (25 * 1), 460), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(745, 440, 745+14+3/8, 460), recti(0, 64, 23, 96), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.extra, TYPE_LINK)], Resize(797 - (55 * 0) - (25 * 1), 441, 797 - (55 * 0) - (25 * 0), 461), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.extra, TYPE_LINK)], Resize(770, 440, 790, 460), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
driver->draw2DRectangle(Resize(310, 463, 797, 533), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000); driver->draw2DRectangle(Resize(310, 463, 797, 533), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(309, 462, 797, 533)); driver->draw2DRectangleOutline(Resize(309, 462, 797, 533));
...@@ -1196,22 +1202,25 @@ void Game::DrawDeckBd() { ...@@ -1196,22 +1202,25 @@ void Game::DrawDeckBd() {
driver->draw2DRectangleOutline(Resize(313 + i * dx, 465, 359 + i * dx, 531)); driver->draw2DRectangleOutline(Resize(313 + i * dx, 465, 359 + i * dx, 531));
} }
//side deck //side deck
driver->draw2DRectangle(Resize(310, 537, 797, 557), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000); driver->draw2DRectangle(Resize(310, 537, 410, 557), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(309, 536, 797, 557)); driver->draw2DRectangleOutline(Resize(309, 536, 410, 557));
DrawShadowText(textFont, dataManager.GetSysString(1332), Resize(315, 537, 410, 557), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(textFont, dataManager.GetSysString(1332), Resize(315, 537, 410, 557), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.current_deck.side.size()], Resize(380, 538, 440, 558), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.current_deck.side.size()], Resize(380, 538, 440, 558), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true);
//type count 2DRectangle
driver->draw2DRectangle(Resize(638, 537, 797, 557), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(637, 536, 797, 557));
//monster count //monster count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1312)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 3) - (25 * 3), 537, 797 - (55 * 2) - (25 * 3), 557), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(645, 537, 645+14+3/8, 557), recti(0, 0, 23, 32), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.side, TYPE_MONSTER)], Resize(797 - (55 * 2) - (25 * 3), 538, 797 - (55 * 2) - (25 * 2), 558), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.side, TYPE_MONSTER)], Resize(670, 537, 690, 557), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
//spell count //spell count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1313)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 2) - (25 * 2), 537, 797 - (55 * 1) - (25 * 2), 557), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(695, 537, 695+14+3/8, 557), recti(23, 0, 46, 32), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.side, TYPE_SPELL)], Resize(797 - (55 * 1) - (25 * 2), 538, 797 - (55 * 1) - (25 * 1), 558), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.side, TYPE_SPELL)], Resize(720, 537, 740, 557), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
//trap count //trap count
myswprintf(textBuffer, L"%ls:", dataManager.GetSysString(1314)); if(imageManager.tCardType)
DrawShadowText(textFont, textBuffer, Resize(797 - (55 * 1) - (25 * 1), 537, 797 - (55 * 0) - (25 * 1), 557), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); driver->draw2DImage(imageManager.tCardType, ResizeCardHint(745, 537, 745+14+3/8, 557), recti(46, 0, 69, 32), 0, 0, true);
DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.side, TYPE_TRAP)], Resize(797 - (55 * 0) - (25 * 1), 538, 797 - (55 * 0) - (25 * 0), 558), Resize(1, 1, 1, 1), 0xffffffff, 0xff000000, false, true); DrawShadowText(numFont, dataManager.numStrings[deckManager.TypeCount(deckManager.current_deck.side, TYPE_TRAP)], Resize(770, 537, 790, 557), Resize(0, 1, 2, 0), 0xffffffff, 0xff000000, true, false);
driver->draw2DRectangle(Resize(310, 560, 797, 630), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000); driver->draw2DRectangle(Resize(310, 560, 797, 630), 0x400000ff, 0x400000ff, 0x40000000, 0x40000000);
driver->draw2DRectangleOutline(Resize(309, 559, 797, 630)); driver->draw2DRectangleOutline(Resize(309, 559, 797, 630));
......
...@@ -855,7 +855,7 @@ bool ClientField::OnEvent(const irr::SEvent& event) { ...@@ -855,7 +855,7 @@ bool ClientField::OnEvent(const irr::SEvent& event) {
else if(conti_selecting) else if(conti_selecting)
mainGame->btnCardSelect[i]->setImage(imageManager.GetTexture(selectable_cards[i + pos]->chain_code)); mainGame->btnCardSelect[i]->setImage(imageManager.GetTexture(selectable_cards[i + pos]->chain_code));
else else
mainGame->btnCardSelect[i]->setImage(imageManager.tCover[0], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT)); mainGame->btnCardSelect[i]->setImage(imageManager.tCover[2], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT));
mainGame->btnCardSelect[i]->setRelativePosition(rect<s32>(30 + i * 125, 55, 30 + 120 + i * 125, 225)); mainGame->btnCardSelect[i]->setRelativePosition(rect<s32>(30 + i * 125, 55, 30 + 120 + i * 125, 225));
// text // text
wchar_t formatBuffer[2048]; wchar_t formatBuffer[2048];
...@@ -918,7 +918,7 @@ bool ClientField::OnEvent(const irr::SEvent& event) { ...@@ -918,7 +918,7 @@ bool ClientField::OnEvent(const irr::SEvent& event) {
if(display_cards[i + pos]->code) if(display_cards[i + pos]->code)
mainGame->btnCardDisplay[i]->setImage(imageManager.GetTexture(display_cards[i + pos]->code)); mainGame->btnCardDisplay[i]->setImage(imageManager.GetTexture(display_cards[i + pos]->code));
else else
mainGame->btnCardDisplay[i]->setImage(imageManager.tCover[0], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT)); mainGame->btnCardDisplay[i]->setImage(imageManager.tCover[2], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT));
mainGame->btnCardDisplay[i]->setRelativePosition(rect<s32>(30 + i * 125, 55, 30 + 120 + i * 125, 225)); mainGame->btnCardDisplay[i]->setRelativePosition(rect<s32>(30 + i * 125, 55, 30 + 120 + i * 125, 225));
wchar_t formatBuffer[2048]; wchar_t formatBuffer[2048];
if(display_cards[i + pos]->location == LOCATION_OVERLAY) { if(display_cards[i + pos]->location == LOCATION_OVERLAY) {
......
...@@ -474,14 +474,14 @@ bool Game::Initialize() { ...@@ -474,14 +474,14 @@ bool Game::Initialize() {
btnPSAU->setImageScale(core::vector2df(0.5, 0.5)); btnPSAU->setImageScale(core::vector2df(0.5, 0.5));
btnPSAD = irr::gui::CGUIImageButton::addImageButton(env, rect<s32>(155, 45, 295, 185), wPosSelect, BUTTON_POS_AD); btnPSAD = irr::gui::CGUIImageButton::addImageButton(env, rect<s32>(155, 45, 295, 185), wPosSelect, BUTTON_POS_AD);
btnPSAD->setImageScale(core::vector2df(0.5, 0.5)); btnPSAD->setImageScale(core::vector2df(0.5, 0.5));
btnPSAD->setImage(imageManager.tCover[0], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT)); btnPSAD->setImage(imageManager.tCover[2], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT));
btnPSDU = irr::gui::CGUIImageButton::addImageButton(env, rect<s32>(300, 45, 440, 185), wPosSelect, BUTTON_POS_DU); btnPSDU = irr::gui::CGUIImageButton::addImageButton(env, rect<s32>(300, 45, 440, 185), wPosSelect, BUTTON_POS_DU);
btnPSDU->setImageScale(core::vector2df(0.5, 0.5)); btnPSDU->setImageScale(core::vector2df(0.5, 0.5));
btnPSDU->setImageRotation(270); btnPSDU->setImageRotation(270);
btnPSDD = irr::gui::CGUIImageButton::addImageButton(env, rect<s32>(445, 45, 585, 185), wPosSelect, BUTTON_POS_DD); btnPSDD = irr::gui::CGUIImageButton::addImageButton(env, rect<s32>(445, 45, 585, 185), wPosSelect, BUTTON_POS_DD);
btnPSDD->setImageScale(core::vector2df(0.5, 0.5)); btnPSDD->setImageScale(core::vector2df(0.5, 0.5));
btnPSDD->setImageRotation(270); btnPSDD->setImageRotation(270);
btnPSDD->setImage(imageManager.tCover[0], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT)); btnPSDD->setImage(imageManager.tCover[2], rect<s32>(0, 0, CARD_IMG_WIDTH, CARD_IMG_HEIGHT));
//card select //card select
wCardSelect = env->addWindow(rect<s32>(320, 100, 1000, 400), false, L""); wCardSelect = env->addWindow(rect<s32>(320, 100, 1000, 400), false, L"");
wCardSelect->getCloseButton()->setVisible(false); wCardSelect->getCloseButton()->setVisible(false);
......
...@@ -13,6 +13,7 @@ bool ImageManager::Initial() { ...@@ -13,6 +13,7 @@ bool ImageManager::Initial() {
tCover[0] = NULL; tCover[0] = NULL;
tCover[1] = NULL; tCover[1] = NULL;
tCover[2] = NULL;
//tUnknown = NULL; //tUnknown = NULL;
tUnknown[0] = NULL; tUnknown[0] = NULL;
tUnknown[1] = NULL; tUnknown[1] = NULL;
...@@ -40,6 +41,7 @@ bool ImageManager::Initial() { ...@@ -40,6 +41,7 @@ bool ImageManager::Initial() {
tBackGround = NULL; tBackGround = NULL;
tBackGround_menu = NULL; tBackGround_menu = NULL;
tBackGround_deck = NULL; tBackGround_deck = NULL;
tCardType = driver->getTexture("textures/cardtype.png");
tField[0] = driver->getTexture("textures/field2.png"); tField[0] = driver->getTexture("textures/field2.png");
tFieldTransparent[0] = driver->getTexture("textures/field-transparent2.png"); tFieldTransparent[0] = driver->getTexture("textures/field-transparent2.png");
tField[1] = driver->getTexture("textures/field3.png"); tField[1] = driver->getTexture("textures/field3.png");
...@@ -193,6 +195,12 @@ void ImageManager::ResizeTexture() { ...@@ -193,6 +195,12 @@ void ImageManager::ResizeTexture() {
tCover[1] = GetRandomImage(TEXTURE_COVER_S, imgWidth, imgHeight); tCover[1] = GetRandomImage(TEXTURE_COVER_S, imgWidth, imgHeight);
if(!tCover[1]) if(!tCover[1])
tCover[1] = tCover[0]; tCover[1] = tCover[0];
if(!tCover[2])
tCover[2] = GetRandomImage(TEXTURE_COVER_S, CARD_IMG_WIDTH, CARD_IMG_HEIGHT);
if(!tCover[2])
tCover[2] = GetTextureFromFile("textures/cover.jpg", CARD_IMG_WIDTH, CARD_IMG_HEIGHT);
if(!tCover[2])
tCover[2] = tCover[0];
//driver->removeTexture(tUnknown); //driver->removeTexture(tUnknown);
//tUnknown = GetTextureFromFile("textures/unknown.jpg", imgWidth, imgHeight); //tUnknown = GetTextureFromFile("textures/unknown.jpg", imgWidth, imgHeight);
driver->removeTexture(tBackGround); driver->removeTexture(tBackGround);
......
...@@ -32,7 +32,7 @@ public: ...@@ -32,7 +32,7 @@ public:
std::unordered_map<int, irr::video::ITexture*> tFields; std::unordered_map<int, irr::video::ITexture*> tFields;
irr::IrrlichtDevice* device; irr::IrrlichtDevice* device;
irr::video::IVideoDriver* driver; irr::video::IVideoDriver* driver;
irr::video::ITexture* tCover[2]; irr::video::ITexture* tCover[3];
irr::video::ITexture* tUnknown[3]; irr::video::ITexture* tUnknown[3];
irr::video::ITexture* tAct; irr::video::ITexture* tAct;
irr::video::ITexture* tAttack; irr::video::ITexture* tAttack;
...@@ -51,6 +51,7 @@ public: ...@@ -51,6 +51,7 @@ public:
irr::video::ITexture* tBackGround; irr::video::ITexture* tBackGround;
irr::video::ITexture* tBackGround_menu; irr::video::ITexture* tBackGround_menu;
irr::video::ITexture* tBackGround_deck; irr::video::ITexture* tBackGround_deck;
irr::video::ITexture* tCardType;
irr::video::ITexture* tField[2]; irr::video::ITexture* tField[2];
irr::video::ITexture* tFieldTransparent[2]; irr::video::ITexture* tFieldTransparent[2];
irr::video::ITexture* tRScale[14]; irr::video::ITexture* tRScale[14];
......
Subproject commit ea1c4fe515a0822b92086af5473cda869f2e8e83 Subproject commit 08eccd453e00cfa4fbf9dc2024b2f16a1690e25a
...@@ -918,7 +918,7 @@ ...@@ -918,7 +918,7 @@
!setname 0x11b 自奏圣乐 オルフェゴール !setname 0x11b 自奏圣乐 オルフェゴール
!setname 0x11c 雷龙 サンダー·ドラゴン !setname 0x11c 雷龙 サンダー·ドラゴン
!setname 0x11d 禁忌的 禁じられた !setname 0x11d 禁忌的 禁じられた
!setname 0x11e 危险! Danger !setname 0x11e 危险! Danger!
!setname 0x11f 奈芙提斯 ネフティス !setname 0x11f 奈芙提斯 ネフティス
!setname 0x120 调皮宝贝 プランキッズ !setname 0x120 调皮宝贝 プランキッズ
!setname 0x121 魔妖 魔妖 !setname 0x121 魔妖
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment