Skip to content
Snippets Groups Projects
Commit 6e13f104 authored by Hugo Roussel's avatar Hugo Roussel
Browse files

Fix consistency of percepts list in amoeba

parent 76431949
Branches
No related tags found
2 merge requests!3Merge masters,!2Merge dev into develop
......@@ -2449,10 +2449,6 @@ public class Head extends AmoebaAgent {
getAmas().data.maxConfidence = Double.NEGATIVE_INFINITY;
getAmas().data.minConfidence = Double.POSITIVE_INFINITY;
for (Percept pct : getAmas().getPercepts()) {
addPercept(pct);
}
// getAmas().data.mappingPerformance.setPerformanceIndicator(world.getMappingErrorAllowed());//
// Math.pow(world.getMappingErrorAllowed(),
// world.getScheduler().getPercepts().size());
......
......@@ -37,8 +37,7 @@ public class Percept extends AmoebaAgent {
*/
public Percept(AMOEBA amoeba) {
super(amoeba);
getAmas().getHeadAgent().addPercept(this);
getAmas().addPercept(this);
}
/**
......
......@@ -839,4 +839,9 @@ public class AMOEBA extends Amas<World> implements IAMOEBA {
}
}
public void addPercept(Percept pct) {
percepts = null;
head.addPercept(pct);
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment