Adding points to list by clicking

In Global JavaScript
function ggbOnInit() {[br] ggbApplet.evalCommand("Sx = {}");[br] ggbApplet.registerAddListener("listener");[br]}[br][br]function listener(obj) {[br] if (ggbApplet.getObjectType(obj) == "point") {[br] ggbApplet.evalCommand("SetValue(Sx, Length(Sx) + 1, " + obj + ")");[br] }[br]}

Information: Adding points to list by clicking