|
@@ -2,7 +2,8 @@ from intelligine.core.exceptions import NoMolecule
|
2
|
2
|
from intelligine.synergy.object.ant.Ant import Ant
|
3
|
3
|
from synergine_xyz.display.Pygame import Pygame as XyzPygame
|
4
|
4
|
import pygame
|
5
|
|
-from intelligine.cst import PHEROMON_DIR_EXPLO, MOLECULES, SMELL_EGG, SMELL_FOOD, MOLECULES_DIRECTION
|
|
5
|
+from intelligine.cst import PHEROMON_DIR_EXPLO, MOLECULES, SMELL_EGG, SMELL_FOOD, MOLECULES_DIRECTION, \
|
|
6
|
+ MOVE_BYBASS_MEMORY
|
6
|
7
|
from intelligine.display.pygame.visualisation import SURFACE_PHEROMONE_EXPLORATION, SURFACE_PHEROMONE_HOME, \
|
7
|
8
|
SURFACE_SMELL_EGG, SURFACE_SMELL_FOOD
|
8
|
9
|
|
|
@@ -78,6 +79,17 @@ class Pygame(XyzPygame):
|
78
|
79
|
myfont = pygame.font.SysFont("monospace", 15)
|
79
|
80
|
label = myfont.render(str(obj.get_id()), 1, (255,255,0))
|
80
|
81
|
self._draw_callbacks.append(lambda: self._screen.blit(label, point))
|
|
82
|
+ label2 = myfont.render(',', 1, (0,0,0))
|
|
83
|
+
|
|
84
|
+ ant_mem = self._context.metas.value.get(MOVE_BYBASS_MEMORY, obj.get_id(), allow_empty=True,
|
|
85
|
+ empty_value=[])
|
|
86
|
+
|
|
87
|
+ def print_mem(points):
|
|
88
|
+ for m in points:
|
|
89
|
+ real_point = self._get_real_pixel_position_of_position((0, m[0], m[1]))
|
|
90
|
+ self._screen.blit(label2, real_point)
|
|
91
|
+
|
|
92
|
+ self._draw_callbacks.append(lambda: print_mem(ant_mem) )
|
81
|
93
|
|
82
|
94
|
def start_of_cycle(self):
|
83
|
95
|
super().start_of_cycle()
|