def addmatchrequests(matches):
    [result, message] = gridclienthelper.getproxy().schedulematchesv1(matches)
    if not result:
        print "error: " + message
        raise Exception(message)
    else:
        return message
def addmatchrequest( ai0, ai1, mod_name, map_name, speed, softtimeout, hardtimeout):
    [result, message] = gridclienthelper.getproxy().schedulematchv1(map_name,mod_name,[{'ai_name': ai0.ai_name,'ai_version': ai0.ai_version},{'ai_name': ai1.ai_name, 'ai_version': ai1.ai_version } ],[], speed, softtimeout, hardtimeout)
    if not result:
        print "error: " + message
        raise Exception(message)
    else:
        return message #message represents matchrequest_id
Пример #3
0
def getleaguematches(league):
    matchidsquery = sqlalchemysetup.session.query(LeagueMatch).filter(LeagueMatch.league_id == league.league_id)
    matchids = [matchqueryitem.match_id for matchqueryitem in matchidsquery]
    [success, matches] = gridclienthelper.getproxy().getmatchesv1(matchids)
    return matches