summaryrefslogtreecommitdiff
path: root/napoleon.py
diff options
context:
space:
mode:
Diffstat (limited to 'napoleon.py')
-rw-r--r--napoleon.py25
1 files changed, 3 insertions, 22 deletions
diff --git a/napoleon.py b/napoleon.py
index 2a1048c..15685eb 100644
--- a/napoleon.py
+++ b/napoleon.py
@@ -9,7 +9,6 @@ import robots
from robots.algorithms import distance_relaxer
from robots.constants import City
-from robots.utils import add_spawns
def get_close_spawns(whoami, state, threshold):
distances = []
@@ -142,24 +141,6 @@ class Napoleon:
)
if __name__ == '__main__':
-# import random
-
-# random.seed(42)
- map_ = robots.border_map(42, 22, 0)
-
- add_spawns(map_, 10, 'X')
- add_spawns(map_, 20, '+')
- add_spawns(map_, 6)
-
- game = robots.Game(map_)
-
- game.add_bot(Napoleon(), 'Napoleon')
-
- from capturer import CaptureSpawns
- game.add_bot(CaptureSpawns(), 'Alice')
- game.add_bot(CaptureSpawns(), 'Bob')
- game.add_bot(CaptureSpawns(), 'Charlie')
- game.add_bot(CaptureSpawns(), 'Doug')
-
- viewer = robots.CursesViewer(game)
- viewer.run()
+ server = robots.Server()
+ server.add_bot(Napoleon, 'Napoleon')
+ server.run()