public void setWidth(int w){
    	if(w == 0) w = 1;
    	//System.out.println("Setting Width: " + w);
    	for(int i = 0; i < anim.getFrames().size(); i ++){
    		Image image = ((AnimFrame)anim.getFrames().get(i)).image;
    		image = image.getScaledInstance(w, image.getHeight(null), 0);
    		((AnimFrame)anim.getFrames().get(i)).image = image;
    	}
    	//anim.setImage(anim.getImage().getScaledInstance(w, anim.getImage().getHeight(null), 0));
    }