public void onDraw(Graphics g, int viewX, int viewY)
    {
        if ((status&World.ST_INVISIBLE)!=0)
        {
            return;
        }
        int offs = x % 8;
         if (!done)
        {
            //x+=move;
            g.drawArc(((x-2)-viewX)*3, ((y-10)-viewY)*3, 4, 4, 0, 360);
            g.drawLine(((x)-viewX)*3, ((y-6)-viewY)*3, ((x)-viewX)*3, ((y-3)-viewY)*3);
            g.drawLine(((x-2)-viewX)*3, ((y-4)-viewY)*3, ((x+2)-viewX)*3, ((y-4)-viewY)*3);
            g.drawLine(((x)-viewX)*3, ((y-3)-viewY)*3, ((x+offs-2)-viewX)*3, ((y)-viewY)*3);
            g.drawLine(((x)-viewX)*3, ((y-3)-viewY)*3, ((x+2-offs)-viewX)*3, ((y)-viewY)*3);
        }
        else
        {
            int yUp = 20;
            
            if (Integer.signum(move)==-1)
            {
                left = -1;
            }
             if (Integer.signum(move)==1)
            {
                left = 1;
            }
            Graphics2D g2 = (Graphics2D)g;
            g2.scale(left,1);
            g2.drawImage(bodyParts[0], (x-viewX)*3*left+(left<0?-18:0), (y-yUp-6-viewY)*3, null);
             g2.drawImage(bodyParts[1], (int)(x+2-((bodyParts[1].getWidth(null)-23)/5)-viewX)*3*left+(left<0?-(6+(bodyParts[1].getWidth(null)-23)):0), ((y-yUp-16-((bodyParts[1].getHeight(null)-31))/3)-viewY)*3, null);

            double ffs = Math.toRadians(((4-offs)*6));
            AffineTransform  previousAT = g2.getTransform();
            g2.translate((x-3-viewX)*3*left, ((y-yUp-6)-viewY)*3);
                g2.rotate(Math.toRadians(leftArmAngle-90),4*(left+1),2);
                    g2.drawImage(bodyParts[2],0 , 0, null);
            g2.setTransform(previousAT);
            
            g2.translate((((x-3-viewX)+lengthdir_x(6*left, leftArmAngle*left)))*left*3, (((y-yUp-6)-this.lengthdir_y(6*left,leftArmAngle*left))-viewY)*3);
                g2.rotate(Math.toRadians(leftArmAngle-90),4*(left+1),2);
                    g2.drawImage(bodyParts[3], 0,0, null);
            g2.setTransform(previousAT);
               
            
            g2.translate((x+9-viewX)*3*left, ((y-yUp-6)-viewY)*3);
                g2.rotate(Math.toRadians(rightArmAngle-90),8-left*4,4);
                    g2.drawImage(bodyParts[2], 0, 0, null);
            g2.setTransform(previousAT);
            
            g2.translate((((x+9-viewX)+this.lengthdir_x(6*left, rightArmAngle*left))*3)*left, (((y-yUp-6)-this.lengthdir_y(6*left,rightArmAngle*left))-viewY)*3);
                g2.rotate(Math.toRadians(rightArmAngle-90),8-left*4,4);
                    g2.drawImage(bodyParts[3], 0, 0, null);
            g2.setTransform(previousAT);    
            
            g2.drawImage(bodyParts[4], (x+1-viewX)*3*left, ((y-yUp+7)-viewY)*3, null);
            g2.drawImage(bodyParts[4], (x+5-viewX)*3*left, ((y-yUp+7)-viewY)*3, null);
            
            
            g2.translate((x+5-viewX)*3*left, ((y+13)-viewY-yUp)*3);
                g2.rotate(ffs);
                    g2.drawImage(bodyParts[5], 0, 0, null);
            g2.setTransform(previousAT);
           
            g2.translate((x+1-viewX)*3*left, ((y+13)-viewY-yUp)*3);
                g2.rotate(-ffs);
                    g2.drawImage(bodyParts[5], 0, 0, null);
            g2.setTransform(previousAT);
            g2.scale(left, 1);
        }
         g.setColor(myTeam?Color.GREEN:Color.MAGENTA);
         g.drawString(username, ((x-(username.length()))-viewX)*3, (y-40-viewY)*3);
    }