예제 #1
0
def determine_bot_functions(bot_names):
    bot_list = []
    for name in bot_names:
        if name == "student":
            bot_list.append(bots.StudentBot())
        elif name == "random":
            bot_list.append(bots.RandBot())
        elif name == "wall":
            bot_list.append(bots.WallBot())
        elif name == "ta1":
            bot_list.append(ta_bots.TABot1())
        elif name == "ta2":
            bot_list.append(ta_bots.TABot2())
        elif name == "survivor":
            bot_list.append(bots.Survivor())
        elif name == "mocker":
            bot_list.append(bots.Mocker())
        elif name == "attacker":
            bot_list.append(bots.Attacker())
        elif name == "bad":
            bot_list.append(bots.BadSurvivor())
        elif name == "thinker":
            bot_list.append(bots.Thinker())
        else:
            raise ValueError(
                """Bot name %s is not supported. Value names include "student",
"random", "wall", "ta1", "ta2" "survivor", "attacker", """ % name)
    return bot_list
예제 #2
0
파일: support.py 프로젝트: haoyangqian/TRON
def determine_bot_functions(bot_names):
    bot_list = []
    for name in bot_names:
        if name == "student":
            bot_list.append(bots.StudentBot())
        elif name == "random":
            bot_list.append(bots.RandBot())
        elif name == "wall":
            bot_list.append(bots.WallBot())
        elif name == "ta1":
            bot_list.append(bots.TABot1())
        else:
            raise ValueError(
                '''Bot name %s is not supported. Value names include "student", 
"random", "wall", "tabot1" ''' % name)
    return bot_list
예제 #3
0
파일: support.py 프로젝트: singhru27/AI-Bot
def determine_bot_functions(bot_names):
    bot_list = []
    for name in bot_names:
        if name == "student":
            bot_list.append(bots.StudentBot())
        elif name == "random":
            bot_list.append(bots.RandBot())
        elif name == "student_voronoi":
            bot_list.append(bots.StudentVoronoiBot())
        elif name == "wall":
            bot_list.append(bots.WallBot())
        elif name == "test1":
            bot_list.append(ta_bots.TABot1())
        elif name == "test2":
            bot_list.append(ta_bots.TABot2())
        else:
            raise ValueError(
                """Bot name %s is not supported. Value names include "student",
"random", "wall", "test1", "test2" """ % name)
    return bot_list