MCPcopy Create free account
hub / github.com/dds-bridge/dds / SolveBoardPBN

Function SolveBoardPBN

library/src/solve_board.cpp:168–190  ·  view source on GitHub ↗

* Solve a single bridge Deal in PBN format. * * Public API documentation is maintained in the API headers. */

Source from the content-addressed store, hash-verified

166 * Public API documentation is maintained in the API headers.
167 */
168int STDCALL SolveBoardPBN(
169 DealPBN dlpbn,
170 int target,
171 int solutions,
172 int mode,
173 FutureTricks * futp,
174 int thrId)
175{
176 Deal dl;
177 if (convert_from_pbn(dlpbn.remainCards, dl.remainCards) != RETURN_NO_FAULT)
178 return RETURN_PBN_FAULT;
179
180 for (int k = 0; k <= 2; k++)
181 {
182 dl.currentTrickRank[k] = dlpbn.currentTrickRank[k];
183 dl.currentTrickSuit[k] = dlpbn.currentTrickSuit[k];
184 }
185 dl.first = dlpbn.first;
186 dl.trump = dlpbn.trump;
187
188 int res = SolveBoard(dl, target, solutions, mode, futp, thrId);
189 return res;
190}
191
192
193/**

Callers 2

register_solve_bindingsFunction · 0.85
mainFunction · 0.85

Calls 2

convert_from_pbnFunction · 0.85
SolveBoardFunction · 0.70

Tested by

no test coverage detected