class radarPoint { float x, y; float dist, angle; color xroma; boolean visible; radarPoint(float px, float py, float pdist, float pangle, color pxroma, boolean pvisible) { x = px; y = py; dist = pdist; angle = pangle; xroma = pxroma; visible = pvisible; } void display() { if (!visible) return; noStroke(); fill(xroma); ellipse(x, y, 5, 5); } void info() { if (!visible) return; fill(255); text(str(dist) + " cm", width/2, height-200); text(str(angle) + " μοίρες", width/2, height-100); } void update(float px, float py, float pangle, float pdist) { x = px; y = py; angle = pangle; dist = pdist; visible = true; } void hide() { visible = false; } }