Exemple #1
0
    public int doesIt(Moves c, Moves p, GameCollection g)
    {
        // GD.Print("hasBictory: " + c);
        // GD.Print("hasBictory: " + p);
        // GD.Print(g);

        GameCollection myG = new GameCollection();
        Gen3           lol = new Gen3();

        lol.combinations(c.getMoves(), myG);

        for (int i = 0; i < myG.getArray().Length; i++)
        {
            int big = g.getIndexGameContains(myG.getArray()[i].getInt(0), myG.getArray()[i].getInt(1), myG.getArray()[i].getInt(2));
            // GD.Print("OMFG OQ Q E ISO: " + myG.getArray()[i].getInt(0), myG.getArray()[i].getInt(1), myG.getArray()[i].getInt(2));
            if (big != -1)
            {
                return(big);
            }
            ;
        }

        lol.combinations(p.getMoves(), myG);

        for (int i = 0; i < myG.getArray().Length; i++)
        {
            int big = g.getIndexGameContains(myG.getArray()[i].getInt(0), myG.getArray()[i].getInt(1), myG.getArray()[i].getInt(2));
            // GD.Print("OMFG OQ Q E ISO: " + myG.getArray()[i].getInt(0), myG.getArray()[i].getInt(1), myG.getArray()[i].getInt(2));
            if (big != -1)
            {
                return(big);
            }
            ;
        }



        return(-1);
    }