Ejemplo n.º 1
0
 public void updateInfo(LabelHandle target)
 {
     if (getSightings() > 0) {
         updatePosition(target.getPosition());
         updateTime(System.DateTime.Now);
         updateAttachedTags(target.getTags());
         if (target.getDirection() != null) {
             updateDirection(target.getDirection());
         }
     }
 }
Ejemplo n.º 2
0
 public void addSighting(LabelHandle target, Vector3 position, Vector3? direction)
 {
     if (targetSightings.ContainsKey (target)) {
         SensoryInfo info = targetSightings[target];
         info.addSighting();
         info.updateInfo(target);
     } else {
         if (staleTargetSightings.ContainsKey(target)) {
             SensoryInfo info = staleTargetSightings[target];
             targetSightings.Add(target, info);
             staleTargetSightings.Remove(target);
             info.addSighting();
         } else {
             targetSightings[target] = new SensoryInfo(position, direction, System.DateTime.Now, target.getTags(), 1);
         }
         registerTags(target);
         notifyListenersTargetFound(target);
     }
 }
Ejemplo n.º 3
0
 private void notifyListenersTargetLost(LabelHandle target)
 {
     foreach (Tag tag in target.getTags()) {
         notifyListenersTagRemoved(tag);
     }
 }
Ejemplo n.º 4
0
 private void notifyListenersTargetFound(LabelHandle target)
 {
     foreach (Tag tag in target.getTags()) {
         notifyListenersTagAdded(tag);
     }
 }