Commit 5cab52df authored by nanahira's avatar nanahira

Merge branch 'new-premake' into server

parents 6fde86f0 f214527d
...@@ -188,7 +188,7 @@ bool DeckManager::LoadSide(Deck& deck, int* dbuf, int mainc, int sidec) { ...@@ -188,7 +188,7 @@ bool DeckManager::LoadSide(Deck& deck, int* dbuf, int mainc, int sidec) {
pcount[deck.side[i]->first]++; pcount[deck.side[i]->first]++;
Deck ndeck; Deck ndeck;
LoadDeck(ndeck, dbuf, mainc, sidec); LoadDeck(ndeck, dbuf, mainc, sidec);
#ifndef NO_SIDE_CHECK #ifndef YGOPRO_NO_SIDE_CHECK
if(ndeck.main.size() != deck.main.size() || ndeck.extra.size() != deck.extra.size()) if(ndeck.main.size() != deck.main.size() || ndeck.extra.size() != deck.extra.size())
return false; return false;
#endif #endif
...@@ -198,7 +198,7 @@ bool DeckManager::LoadSide(Deck& deck, int* dbuf, int mainc, int sidec) { ...@@ -198,7 +198,7 @@ bool DeckManager::LoadSide(Deck& deck, int* dbuf, int mainc, int sidec) {
ncount[ndeck.extra[i]->first]++; ncount[ndeck.extra[i]->first]++;
for(size_t i = 0; i < ndeck.side.size(); ++i) for(size_t i = 0; i < ndeck.side.size(); ++i)
ncount[ndeck.side[i]->first]++; ncount[ndeck.side[i]->first]++;
#ifndef NO_SIDE_CHECK #ifndef YGOPRO_NO_SIDE_CHECK
for(auto cdit = ncount.begin(); cdit != ncount.end(); ++cdit) for(auto cdit = ncount.begin(); cdit != ncount.end(); ++cdit)
if(cdit->second != pcount[cdit->first]) if(cdit->second != pcount[cdit->first])
return false; return false;
......
...@@ -62,6 +62,7 @@ boolOptions = { ...@@ -62,6 +62,7 @@ boolOptions = {
"no-lua-safe", "no-lua-safe",
"message-debug", "message-debug",
"default-duel-rule", "default-duel-rule",
"no-side-check",
} }
for _, boolOption in ipairs(boolOptions) do for _, boolOption in ipairs(boolOptions) do
......
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