def set_command(action): """Set player's T_COMMAND, then call turn_over().""" id = [ x for x in world_db["ThingActions"] if world_db["ThingActions"][x]["TA_NAME"] == action ][0] world_db["Things"][0]["T_COMMAND"] = id turn_over()
def command_ai(): """Call ai() on player Thing, then turn_over().""" from server.ai import ai if world_db["WORLD_ACTIVE"]: ai(world_db["Things"][0]) turn_over()
def set_command(action): """Set player's T_COMMAND, then call turn_over().""" id = [x for x in world_db["ThingActions"] if world_db["ThingActions"][x]["TA_NAME"] == action][0] world_db["Things"][0]["T_COMMAND"] = id turn_over()