Beispiel #1
0
    public bool IsFairTrade()
    {
        bool fairTrade = Mathf.Abs((float)(ValueOfGetResources() - ValueOfGiveResources())) <= AIEngine.AverageValue();

        if (debugMessages)
        {
            GameEngine.print("GET VALUE: " + ValueOfGetResources());
            GameEngine.print("GIVE VALUE: " + ValueOfGiveResources());
            GameEngine.print("___avg val: " + AIEngine.AverageValue());
            GameEngine.print("IS FAIR TRADE?: " + fairTrade);
        }

        return(fairTrade);
    }
Beispiel #2
0
    public bool IsFairTrade(PlayerHand a, PlayerHand b)
    {
        PlayerHand get  = a;
        PlayerHand give = b;

        bool fairTrade = Mathf.Abs((float)(get.ValueOfHand() - give.ValueOfHand())) <= AIEngine.AverageValue();

        return(fairTrade);
    }