import java.awt.*; import java.awt.event.*; import java.applet.Applet; public class inimene extends Applet implements MouseMotionListener{ public inimene(){ init(); } public void init(){ addMouseMotionListener(this); } public void mouseMoved(MouseEvent e){} public void mouseDragged(MouseEvent e){} public void paint(Graphics g){ //Graphics g=this.getGraphics(); g.setColor(Color.white); //g.fillRect(0, 0, getSize().width, getSize().height); for(int x=40; x<2000; x=x+2){ int raadius=10; g.setColor(Color.blue); g.drawOval(100, 100, 35, 80); g.drawOval(100, 80, 10, 10); g.drawOval(120, 80, 10, 10); g.fillOval(100, 80, 4, 4); g.fillOval(120, 80, 4, 4); g.drawLine(230, 0, 230, 400); g.drawLine(50, 0, 50, 400); g.drawLine(100, 100+55, 100+(int)(raadius*Math.cos(x/10.0))-10, 100+125); g.drawLine(100+35, 100+55, 100+35+(int)(raadius*Math.cos(x/15.0))+20, 100+125); g.drawLine(100, 100+25, 100-35+(int)(raadius*Math.cos(x/10.0))-10, 100+60); g.drawLine(100+35, 100+25, 100+70+(int)(raadius*Math.cos(x/10.0))-10, 100+60); g.drawOval(100, 100-35, 35, 35); try{Thread.sleep(50);}catch(Exception e){} g.setColor(Color.white); g.drawLine(100, 100+55, 100+(int)(raadius*Math.cos(x/10.0))-10, 100+125); g.drawLine(100+35, 100+55, 100+35+(int)(raadius*Math.cos(x/15.0))+20, 100+125); g.drawLine(100, 100+25, 100-35+(int)(raadius*Math.cos(x/10.0))-10, 100+60); g.drawLine(100+35, 100+25, 100+70+(int)(raadius*Math.cos(x/10.0))-10, 100+60); } } /*public static void main(String argumendid[]){ Frame f=new Frame(); f.add(new inimene()); f.setSize(200, 200); f.setVisible(true); }*/ }