Browse Source

add todo and little check

Bastien Sevajol 9 years ago
parent
commit
5e2a0e44e3
1 changed files with 3 additions and 1 deletions
  1. 3 1
      intelligine/synergy/object/ant/Ant.py

+ 3 - 1
intelligine/synergy/object/ant/Ant.py View File

20
                                                            COL_FIGHTER])
20
                                                            COL_FIGHTER])
21
         self._carried = []
21
         self._carried = []
22
         self._last_pheromones_points = {}
22
         self._last_pheromones_points = {}
23
+        # TODO: Faire un body_part schema pour ces trucs la
23
         self._movement_pheromone_gland = MovementPheromoneGland(self, self._context)
24
         self._movement_pheromone_gland = MovementPheromoneGland(self, self._context)
24
         self._brain.switch_to_mode(MOVE_MODE_EXPLO)
25
         self._brain.switch_to_mode(MOVE_MODE_EXPLO)
25
 
26
 
56
 
57
 
57
     # TODO: Est-ce ici que doit etre ce code ?
58
     # TODO: Est-ce ici que doit etre ce code ?
58
     def set_position(self, position):
59
     def set_position(self, position):
59
-        if self._position is not None:
60
+        if self._position is not None and position != self._position:
60
             self._brain.host_moved()
61
             self._brain.host_moved()
61
         super().set_position(position)
62
         super().set_position(position)
62
         if self.is_carrying():
63
         if self.is_carrying():
63
             for obj_carried in self._carried:
64
             for obj_carried in self._carried:
64
                 obj_carried.set_position(position)
65
                 obj_carried.set_position(position)
65
 
66
 
67
+    # TODO: N'est plus utiliser ! delete it !
66
     def get_last_pheromone_point(self, pheromone_name):
68
     def get_last_pheromone_point(self, pheromone_name):
67
         if pheromone_name in self._last_pheromones_points:
69
         if pheromone_name in self._last_pheromones_points:
68
             return self._last_pheromones_points[pheromone_name]
70
             return self._last_pheromones_points[pheromone_name]