if(e != null){
if(e.getType().equals("PositionChanged")){
PositionChangedEvent p = (PositionChangedEvent) e;
this.centreOfOrbit = p.getTo();
}else if(e.getType().equals("TimePassed")){
PositionComponent posComp = (PositionComponent) getSiblingByType(PositionComponent.class.getName());
if(posComp != null){
Vector2f pos = posComp.getVector();
if(pos != null && centreOfOrbit != null && !pos.equals(centreOfOrbit)){
TimePassedEvent t = (TimePassedEvent) e;
posComp.setVector(VectorUtil.rotateAround(pos.copy(), centreOfOrbit, t.getDelta()*orbitalVelocity));
}
}
}
}
}