public void checkEnemyCollision(ArrayList<Enemy> list){
        //setFalling(true);
        //double tempDx=getDx();
        //double tempX=getXTemp();
        for(int i=0;i<list.size();i++){
            //boolean rgt=false;
            //boolean lft=false;
            double w=.5*(list.get(i).getCWidth()+getWidth());
            double h=.5*(list.get(i).getCHeight()+getHeight());
            double dx=list.get(i).getCCenterX()-getCenterX();
            double dy=list.get(i).getCCenterY()-getCenterY();
            if(Math.abs(dx)<=w&&Math.abs(dy)<=h){
                double wy=w*dy;
                double hx=h*dx;
                if(wy>hx){
                    if(wy>-hx){
                        // Collision is on the top
                        // This will probably never happen
                        System.out.println("Not supposed to happen :: Koopa");
                    }else{
                        // Collision is from the left
                        if(!shell){
                            turn();
                            list.get(i).turn();
                        }else{
                            list.get(i--).hitByProjectile(this);
                        }
                    }
                }else{
                    if(wy>-hx){
                        // Collision is on the right
                        if(!shell){
                            turn();
                            list.get(i).turn();
                        }else{
                            list.get(i--).hitByProjectile(this);
                        }
                    }else{
                        // Collision is on the bottom
                        System.out.println("Not supposed to happen :: Koopa");
                    }
                }
                //if(rgt&&lft){
                //    setDx(tempDx);
                //    setXTemp(tempX);
                //}
            }
        }
    }