import java.awt.*; import java.awt.event.*; public class Rekt extends Frame implements MouseListener { int x,y; public void mouseReleased(MouseEvent e){} public void mouseEntered(MouseEvent e){} public void mouseExited(MouseEvent e){} public void mouseClicked(MouseEvent e){} public void mousePressed(MouseEvent e){ Graphics g=this.getGraphics(); do{ for(int t=0;t<=150;t++){ x=t; y=t; g.drawRect(x,y,25,25); g.drawLine(0,0,160,160); g.drawLine(160,160,300,160); try{ Thread.sleep(10);}catch(Exception ex){} g.clearRect(0,0,300,300); } for(int t=150;t<=300;t++){ x=t; y=150; g.drawRect(x,y,25,25); g.drawLine(0,0,160,160); g.drawLine(160,160,300,160); try{ Thread.sleep(10);}catch(Exception ex){} g.clearRect(0,0,300,300); } }while(true); } public static void main(String arg[]){ Rekt k=new Rekt(); k.setSize(300,300); k.setVisible(true); k.addMouseListener(k); } }