while hero.gold > hero.costOf("soldier"):
hero.summon("soldier")
soldiers = hero.findFriends()
soldierIndex = 0
# Add a while loop to command all the soldiers.
while True:
soldier = soldiers[soldierIndex]
hero.command(soldier, "move", {"x": 50, "y": 40})
hero.move({'x': 50, 'y': 40})
soldierIndex += 1
It’s saying "command’s argument minion should have type unit, but got null. Hero placeholder needs something to command.
What’s null, for starters? And it’s not pinpointing a specific line, either.