Skip to content

Commit

Permalink
Merge branch 'master' of github.com:Fluorohydride/ygopro
Browse files Browse the repository at this point in the history
  • Loading branch information
purerosefallen committed May 25, 2021
2 parents 6a941af + 2c1f3de commit 71ffc9c
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 19 deletions.
12 changes: 12 additions & 0 deletions gframe/client_field.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,18 @@ void ClientField::ClearSelect() {
(*cit)->is_selectable = false;
(*cit)->is_selected = false;
}
for(auto cit = selected_cards.begin(); cit != selected_cards.end(); ++cit) {
(*cit)->is_selectable = false;
(*cit)->is_selected = false;
}
for(auto cit = selectsum_all.begin(); cit != selectsum_all.end(); ++cit) {
(*cit)->is_selectable = false;
(*cit)->is_selected = false;
}
for(auto cit = selectsum_cards.begin(); cit != selectsum_cards.end(); ++cit) {
(*cit)->is_selectable = false;
(*cit)->is_selected = false;
}
}
void ClientField::ClearChainSelect() {
for(auto cit = activatable_cards.begin(); cit != activatable_cards.end(); ++cit) {
Expand Down
23 changes: 4 additions & 19 deletions gframe/duelclient.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4166,7 +4166,10 @@ void DuelClient::SendResponse() {
break;
}
case MSG_SELECT_CARD:
case MSG_SELECT_UNSELECT_CARD: {
case MSG_SELECT_UNSELECT_CARD:
case MSG_SELECT_TRIBUTE:
case MSG_SELECT_SUM:
case MSG_SELECT_COUNTER: {
mainGame->dField.ClearSelect();
for (auto cit = mainGame->dField.limbo_temp.begin(); cit != mainGame->dField.limbo_temp.end(); ++cit)
delete *cit;
Expand All @@ -4177,24 +4180,6 @@ void DuelClient::SendResponse() {
mainGame->dField.ClearChainSelect();
break;
}
case MSG_SELECT_TRIBUTE: {
mainGame->dField.ClearSelect();
break;
}
case MSG_SELECT_COUNTER: {
mainGame->dField.ClearSelect();
break;
}
case MSG_SELECT_SUM: {
for(int i = 0; i < mainGame->dField.must_select_count; ++i) {
mainGame->dField.selected_cards[i]->is_selected = false;
}
for(size_t i = 0; i < mainGame->dField.selectsum_all.size(); ++i) {
mainGame->dField.selectsum_all[i]->is_selectable = false;
mainGame->dField.selectsum_all[i]->is_selected = false;
}
break;
}
case MSG_CONFIRM_CARDS: {
for (auto cit = mainGame->dField.limbo_temp.begin(); cit != mainGame->dField.limbo_temp.end(); ++cit)
delete *cit;
Expand Down
2 changes: 2 additions & 0 deletions gframe/game.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ bool Game::Initialize() {
L"/usr/share/fonts/truetype/DroidSansFallbackFull.ttf",
L"/usr/share/fonts/opentype/noto/NotoSansCJK-Bold.ttc",
L"/usr/share/fonts/google-noto-cjk/NotoSansCJK-Bold.ttc",
L"/usr/share/fonts/noto-cjk/NotoSansCJK-Bold.ttc",
L"/System/Library/Fonts/SFNSTextCondensed-Bold.otf",
L"/System/Library/Fonts/SFNS.ttf",
L"./fonts/numFont.ttf",
Expand All @@ -122,6 +123,7 @@ bool Game::Initialize() {
L"/usr/share/fonts/truetype/DroidSansFallbackFull.ttf",
L"/usr/share/fonts/opentype/noto/NotoSansCJK-Regular.ttc",
L"/usr/share/fonts/google-noto-cjk/NotoSansCJK-Regular.ttc",
L"/usr/share/fonts/noto-cjk/NotoSansCJK-Regular.ttc",
L"/System/Library/Fonts/PingFang.ttc",
L"./fonts/textFont.ttf",
L"./fonts/textFont.ttc",
Expand Down

0 comments on commit 71ffc9c

Please sign in to comment.