Exemplo n.º 1
0
MoveHint ClockSolver::translateMove( const MOVE &m )
{
    PatPile *frompile = deal->store[m.from];
    KCard *card = frompile->topCard();

    if ( m.totype == O_Type )
    {
        return MoveHint( card, deal->target[m.to], m.pri );
    } else {
        return MoveHint( card, deal->store[m.to], m.pri );
    }
}
Exemplo n.º 2
0
MoveHint Mod3Solver::translateMove( const MOVE & m )
{
    if ( m.from == deck )
        return MoveHint();

    PatPile *frompile = deal->stack[m.from / 8][m.from % 8];
    KCard *card = frompile->topCard();

    if ( m.to == aces )
    {
        return MoveHint( card, deal->aces, m.pri );
    } else {
        return MoveHint( card, deal->stack[m.to / 8][m.to % 8], m.pri );
    }
}