from hlt import *
from networking import *

playerTag, gameMap = getInit()
sendInit("BasicBot"+str(playerTag))

while True:
	moves = []
	gameMap = getFrame()

	for y in range(0, len(gameMap.contents)):
		for x in range(0, len(gameMap.contents[y])):
			site = gameMap.contents[y][x]
			if site.owner == playerTag:
				direction = random.randint(0, 5)
				if site.strength < 5*site.production:
					direction = STILL
				else:
					for d in CARDINALS:
						if gameMap.getSite(Location(x, y), d).owner != playerTag:
							direction = d
							break
				moves.append(Move(Location(x, y), direction))

	sendFrame(moves)

from hlt import *
from networking import *

playerTag, gameMap = getInit()
sendInit("PythonBot"+str(playerTag))

while True:
	moves = []
	gameMap = getFrame()

	for y in range(0, len(gameMap.contents)):
		for x in range(0, len(gameMap.contents[y])):
			site = gameMap.contents[y][x]
			if site.owner == playerTag:
				moves.append(Move(Location(x, y), int(random.random() * 5)))

	sendFrame(moves)

Revert python mybot to random bot
Revert python mybot to random bot


Former-commit-id: b08897ea13c57ce3700439954b432a6453fcfb3f
Former-commit-id: 28471a6712bd57db5dc7fd6d42d614d2f7ae7069
Former-commit-id: 871c6ab61f365689493b0663b761317cfb786507