import java.awt.*; import java.awt.event.*; import java.applet.Applet; import java.net.*; public class radar3 extends Applet { int X,Y; int i; public radar3() { vaenlased v=new vaenlased(); addMouseListener(v); } public void paint(Graphics g) { int pos; int u=0; g.setColor(Color.black); g.fillRect(0, 0, getSize().width, getSize().height); pos=i; int v2rv=255; while(pos>=i-10) { Color varv=new Color(0,v2rv,0); g.setColor(varv); g.fillArc(1, 25, 301, 325, pos, 1); pos--; v2rv-=25; } g.setColor(Color.black); g.fillOval(X, Y, 10, 10); } class vaenlased extends Thread implements MouseListener { public vaenlased() { start(); } public void run() { for (i=0;i<=360;i++) { repaint(); try{Thread.sleep(15);}catch(Exception e2){} if(i==360) i=0; } } public void mousePressed(MouseEvent e) { X=e.getX(); Y=e.getY(); System.out.println(X+" "+Y); } public void mouseReleased(MouseEvent e){} public void mouseClicked(MouseEvent e){} public void mouseEntered(MouseEvent e){} public void mouseExited(MouseEvent e){} } public static void main(String[] argumendid) { Frame f=new Frame(); f.setBackground(Color.black); f.add(new radar3()); f.setSize(350, 400); f.setVisible(true); } }