Commit 95142a8b authored by fallenstardust's avatar fallenstardust

添加宣言卡名,等级,属性,种族的提示文字

parent db5df791
......@@ -3507,7 +3507,7 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
else myswprintf(textBuffer, dataManager.GetSysString(563));
select_hint = 0;
mainGame->gMutex.lock();
mainGame->wANRace->setText(textBuffer);
mainGame->stANRace->setText(textBuffer);
mainGame->PopupElement(mainGame->wANRace);
/*#ifdef _IRR_ANDROID_PLATFORM_
char* content;
......@@ -3560,7 +3560,7 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
else myswprintf(textBuffer, dataManager.GetSysString(562));
select_hint = 0;
mainGame->gMutex.lock();
mainGame->wANAttribute->setText(textBuffer);
mainGame->stANAttribute->setText(textBuffer);
mainGame->PopupElement(mainGame->wANAttribute);
/*#ifdef _IRR_ANDROID_PLATFORM_
char* content;
......@@ -3611,7 +3611,7 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
select_hint = 0;
mainGame->gMutex.lock();
mainGame->ebANCard->setText(L"");
mainGame->wANCard->setText(textBuffer);
mainGame->stANCard->setText(textBuffer);
mainGame->dField.UpdateDeclarableList();
mainGame->PopupElement(mainGame->wANCard);
mainGame->gMutex.unlock();
......@@ -3656,7 +3656,7 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
myswprintf(textBuffer, L"%ls", dataManager.GetDesc(select_hint));
else myswprintf(textBuffer, dataManager.GetSysString(565));
select_hint = 0;
mainGame->wANNumber->setText(textBuffer);
mainGame->stANNumber->setText(textBuffer);
mainGame->PopupElement(mainGame->wANNumber);
mainGame->gMutex.unlock();
return false;
......
......@@ -593,9 +593,9 @@ bool Game::Initialize(ANDROID_APP app) {
ChangeToIGUIImageWindow(wQuery, bgQuery, imageManager.tDialog_L);
stQMessage = env->addStaticText(L"", rect<s32>(20 * xScale, 20 * yScale, 390 * xScale, 100 * yScale), false, true, wQuery, -1, false);
stQMessage->setTextAlignment(irr::gui::EGUIA_UPPERLEFT, irr::gui::EGUIA_CENTER);
btnYes = env->addButton(rect<s32>(80 * xScale, 115 * yScale, 170 * xScale, 165 * yScale), wQuery, BUTTON_YES, dataManager.GetSysString(1213));
btnYes = env->addButton(rect<s32>(60 * xScale, 130 * yScale, 170 * xScale, 170 * yScale), wQuery, BUTTON_YES, dataManager.GetSysString(1213));
ChangeToIGUIImageButton(btnYes, imageManager.tButton_S, imageManager.tButton_S_pressed);
btnNo = env->addButton(rect<s32>(200 * xScale, 115 * yScale, 290 * xScale, 165 * yScale), wQuery, BUTTON_NO, dataManager.GetSysString(1214));
btnNo = env->addButton(rect<s32>(200 * xScale, 130 * yScale, 310 * xScale, 170 * yScale), wQuery, BUTTON_NO, dataManager.GetSysString(1214));
ChangeToIGUIImageButton(btnNo, imageManager.tButton_S, imageManager.tButton_S_pressed);
//surrender yes/no (310)
wSurrender = env->addWindow(rect<s32>(470 * xScale, 180 * yScale, 860 * xScale, 360 * yScale), false, dataManager.GetSysString(560));
......@@ -604,9 +604,9 @@ bool Game::Initialize(ANDROID_APP app) {
ChangeToIGUIImageWindow(wSurrender, bgSurrender, imageManager.tDialog_L);
stSurrenderMessage = env->addStaticText(dataManager.GetSysString(1359), rect<s32>(20 * xScale, 20 * yScale, 350 * xScale, 100 * yScale), false, true, wSurrender, -1, false);
stSurrenderMessage->setTextAlignment(irr::gui::EGUIA_UPPERLEFT, irr::gui::EGUIA_CENTER);
btnSurrenderYes = env->addButton(rect<s32>(80 * xScale, 115 * yScale, 170 * xScale, 165 * yScale), wSurrender, BUTTON_SURRENDER_YES, dataManager.GetSysString(1213));
btnSurrenderYes = env->addButton(rect<s32>(60 * xScale, 130 * yScale, 170 * xScale, 170 * yScale), wSurrender, BUTTON_SURRENDER_YES, dataManager.GetSysString(1213));
ChangeToIGUIImageButton(btnSurrenderYes, imageManager.tButton_S, imageManager.tButton_S_pressed);
btnSurrenderNo = env->addButton(rect<s32>(200 * xScale, 115 * yScale, 290 * xScale, 165 * yScale), wSurrender, BUTTON_SURRENDER_NO, dataManager.GetSysString(1214));
btnSurrenderNo = env->addButton(rect<s32>(200 * xScale, 130 * yScale, 310 * xScale, 170 * yScale), wSurrender, BUTTON_SURRENDER_NO, dataManager.GetSysString(1214));
ChangeToIGUIImageButton(btnSurrenderNo, imageManager.tButton_S, imageManager.tButton_S_pressed);
//options (350)
wOptions = env->addWindow(rect<s32>(470 * xScale, 180 * yScale, 860 * xScale, 360 * yScale), false, L"");
......@@ -693,9 +693,11 @@ bool Game::Initialize(ANDROID_APP app) {
ChangeToIGUIImageWindow(wANNumber, bgANNumber, imageManager.tWindow_V);
cbANNumber = CAndroidGUIComboBox::addAndroidComboBox(env, rect<s32>(30 * xScale, 180 * yScale, 270 * xScale, 240 * yScale), wANNumber, -1);
cbANNumber->setTextAlignment(irr::gui::EGUIA_CENTER, irr::gui::EGUIA_CENTER);
stANNumber = env->addStaticText(L"", rect<s32>(20 * xScale, 10 * yScale, 280 * xScale, 40 * yScale), false, false, wANNumber, -1, false);
stANNumber->setTextAlignment(EGUIA_CENTER, EGUIA_CENTER);
for(int i = 0; i < 12; ++i) {
myswprintf(strbuf, L"%d", i + 1);
btnANNumber[i] = env->addButton(rect<s32>((50 + 70 * (i % 3)) * xScale, (50 + 70 * (i / 3)) * yScale, (110 + 70 * (i % 3)) * xScale, (110 + 70 * (i / 3)) * yScale), wANNumber, BUTTON_ANNUMBER_1 + i, strbuf);
btnANNumber[i] = env->addButton(rect<s32>((50 + 70 * (i % 3)) * xScale, (60 + 70 * (i / 3)) * yScale, (110 + 70 * (i % 3)) * xScale, (120 + 70 * (i / 3)) * yScale), wANNumber, BUTTON_ANNUMBER_1 + i, strbuf);
ChangeToIGUIImageButton(btnANNumber[i], imageManager.tButton_C, imageManager.tButton_C_pressed, titleFont);
btnANNumber[i]->setIsPushButton(true);
}
......@@ -705,27 +707,33 @@ bool Game::Initialize(ANDROID_APP app) {
wANCard = env->addWindow(rect<s32>(500 * xScale, 50 * yScale, 800 * xScale, 550 * yScale), false, L"");
wANCard->getCloseButton()->setVisible(false);
wANCard->setVisible(false);
ChangeToIGUIImageWindow(wANCard, bgANCard, imageManager.tDialog_S);
ebANCard = CAndroidGUIEditBox::addAndroidEditBox(L"", true, env, rect<s32>(10 * xScale, 20 * yScale, 290 * xScale, 60 * yScale), wANCard, EDITBOX_ANCARD);
ChangeToIGUIImageWindow(wANCard, bgANCard, imageManager.tDialog_S);
stANCard = env->addStaticText(L"", rect<s32>(20 * xScale, 10 * yScale, 280 * xScale, 40 * yScale), false, false, wANCard, -1, false);
stANCard->setTextAlignment(EGUIA_CENTER, EGUIA_CENTER);
ebANCard = CAndroidGUIEditBox::addAndroidEditBox(L"", true, env, rect<s32>(10 * xScale, 50 * yScale, 290 * xScale, 90 * yScale), wANCard, EDITBOX_ANCARD);
ebANCard->setTextAlignment(irr::gui::EGUIA_CENTER, irr::gui::EGUIA_CENTER);
lstANCard = env->addListBox(rect<s32>(10 * xScale, 70 * yScale, 290 * xScale, 440 * yScale), wANCard, LISTBOX_ANCARD, true);
lstANCard = env->addListBox(rect<s32>(10 * xScale, 100 * yScale, 290 * xScale, 440 * yScale), wANCard, LISTBOX_ANCARD, true);
btnANCardOK = env->addButton(rect<s32>(95 * xScale, 450 * yScale, 205 * xScale, 490 * yScale), wANCard, BUTTON_ANCARD_OK, dataManager.GetSysString(1211));
ChangeToIGUIImageButton(btnANCardOK, imageManager.tButton_S, imageManager.tButton_S_pressed);
//announce attribute
wANAttribute = env->addWindow(rect<s32>(470 * xScale, 180 * yScale, 860 * xScale, 360 * yScale), false, dataManager.GetSysString(562));
wANAttribute->getCloseButton()->setVisible(false);
wANAttribute->setVisible(false);
ChangeToIGUIImageWindow(wANAttribute, bgANAttribute, imageManager.tDialog_L);
ChangeToIGUIImageWindow(wANAttribute, bgANAttribute, imageManager.tDialog_L);
stANAttribute = env->addStaticText(L"", rect<s32>(20 * xScale, 10 * yScale, 370 * xScale, 40 * yScale), false, false, wANAttribute, -1, false);
stANAttribute->setTextAlignment(EGUIA_CENTER, EGUIA_CENTER);
for(int filter = 0x1, i = 0; i < 7; filter <<= 1, ++i)
chkAttribute[i] = env->addCheckBox(false, rect<s32>((50 + (i % 4) * 80) * xScale, (50 + (i / 4) * 55) * yScale, (130 + (i % 4) * 80) * xScale, (80 + (i / 4) * 55) * yScale),
chkAttribute[i] = env->addCheckBox(false, rect<s32>((50 + (i % 4) * 80) * xScale, (60 + (i / 4) * 55) * yScale, (130 + (i % 4) * 80) * xScale, (90 + (i / 4) * 55) * yScale),
wANAttribute, CHECK_ATTRIBUTE, dataManager.FormatAttribute(filter));
//announce race
wANRace = env->addWindow(rect<s32>(500 * xScale, 50 * yScale, 800 * xScale, 550 * yScale), false, dataManager.GetSysString(563));
wANRace->getCloseButton()->setVisible(false);
wANRace->setVisible(false);
ChangeToIGUIImageWindow(wANRace, bgANRace, imageManager.tDialog_S);
stANRace = env->addStaticText(L"", rect<s32>(20 * xScale, 10 * yScale, 280 * xScale, 40 * yScale), false, false, wANRace, -1, false);
stANRace->setTextAlignment(EGUIA_CENTER, EGUIA_CENTER);
for(int filter = 0x1, i = 0; i < 25; filter <<= 1, ++i)
chkRace[i] = env->addCheckBox(false, rect<s32>((30 + (i % 3) * 90) * xScale, (30 + (i / 3) * 50) * yScale, (100 + (i % 3) * 90) * xScale, (70 + (i / 3) * 50) * yScale),
chkRace[i] = env->addCheckBox(false, rect<s32>((30 + (i % 3) * 90) * xScale, (60 + (i / 3) * 50) * yScale, (100 + (i % 3) * 90) * xScale, (110 + (i / 3) * 50) * yScale),
wANRace, CHECK_RACE, dataManager.FormatRace(filter));
//selection hint
stHintMsg = env->addStaticText(L"", rect<s32>(500 * xScale, 90 * yScale, 820 * xScale, 120 * yScale), true, false, 0, -1, false);
......@@ -1043,9 +1051,9 @@ bool Game::Initialize(ANDROID_APP app) {
env->addStaticText(dataManager.GetSysString(1342), rect<s32>(20 * xScale, 25 * yScale, 290 * xScale, 45 * yScale), false, false, wReplaySave);
ebRSName = CAndroidGUIEditBox::addAndroidEditBox(L"", true, env, rect<s32>(20 * xScale, 50 * yScale, 370 * xScale, 90 * yScale), wReplaySave, -1);
ebRSName->setTextAlignment(irr::gui::EGUIA_CENTER, irr::gui::EGUIA_CENTER);
btnRSYes = env->addButton(rect<s32>(70 * xScale, 110 * yScale, 180 * xScale, 160 * yScale), wReplaySave, BUTTON_REPLAY_SAVE, dataManager.GetSysString(1341));
btnRSYes = env->addButton(rect<s32>(70 * xScale, 130 * yScale, 180 * xScale, 170 * yScale), wReplaySave, BUTTON_REPLAY_SAVE, dataManager.GetSysString(1341));
ChangeToIGUIImageButton(btnRSYes, imageManager.tButton_S, imageManager.tButton_S_pressed);
btnRSNo = env->addButton(rect<s32>(210 * xScale, 110 * yScale, 320 * xScale, 160 * yScale), wReplaySave, BUTTON_REPLAY_CANCEL, dataManager.GetSysString(1212));
btnRSNo = env->addButton(rect<s32>(210 * xScale, 130 * yScale, 320 * xScale, 170 * yScale), wReplaySave, BUTTON_REPLAY_CANCEL, dataManager.GetSysString(1212));
ChangeToIGUIImageButton(btnRSNo, imageManager.tButton_S, imageManager.tButton_S_pressed);
//replay control
wReplayControl = env->addWindow(rect<s32>(200 * yScale, 5 * yScale, 310 * yScale, 270 * yScale), false, L"");
......
......@@ -461,22 +461,26 @@ public:
//announce number
irr::gui::IGUIWindow* wANNumber;
irr::gui::IGUIImage* bgANNumber;
irr::gui::IGUIStaticText* stANNumber;
irr::gui::IGUIComboBox* cbANNumber;
irr::gui::IGUIButton* btnANNumber[12];//
irr::gui::IGUIButton* btnANNumberOK;//
//announce card
irr::gui::IGUIWindow* wANCard;
irr::gui::IGUIImage* bgANCard;
irr::gui::IGUIStaticText* stANCard;
irr::gui::IGUIEditBox* ebANCard;
irr::gui::IGUIListBox* lstANCard;
irr::gui::IGUIButton* btnANCardOK;//
//announce attribute
irr::gui::IGUIWindow* wANAttribute;
irr::gui::IGUIImage* bgANAttribute;
irr::gui::IGUIStaticText* stANAttribute;
irr::gui::IGUICheckBox* chkAttribute[7];
//announce race
irr::gui::IGUIWindow* wANRace;
irr::gui::IGUIImage* bgANRace;
irr::gui::IGUIStaticText* stANRace;
irr::gui::IGUICheckBox* chkRace[25];
//cmd menu
irr::gui::IGUIWindow* wCmdMenu;
......
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