Commit 51c3d041 authored by Julian Zobel's avatar Julian Zobel
Browse files

Random Generators now call the AP monitors

parent af3f2cc6
......@@ -134,7 +134,10 @@ public class RandomAttractionGenerator implements IAttractionGenerator {
}
attractionPoints.clear();
attractionPoints.addAll(result);
for (AttractionPoint ap : result) {
addAttractionPoint(ap);
}
}
private PositionVector createPosVec() {
......
......@@ -134,7 +134,7 @@ public class RandomDynamicAttractionGenerator implements IAttractionGenerator {
for(int i = 0; i < deltaAP; i++) {
int random = rand.nextInt(attractionPoints.size());
attractionPoints.remove(random);
removeAttractionPoint(attractionPoints.get(random));
}
return;
}
......@@ -146,7 +146,7 @@ public class RandomDynamicAttractionGenerator implements IAttractionGenerator {
for(int i = 0; i < deltaAP; i++) {
AttractionPoint newAP = createAttractionPoint();
scheduleDynamicEvent(newAP);
attractionPoints.add(newAP);
addAttractionPoint(newAP);
}
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment