public void addFrame(BufferedImage img, long stepTime){
		if(img!=null && !running){
			images.add(img);
			times.add(stepTime);
			totalTime += stepTime;
		}else if(running){
			System.err.println("Animations cannot be edited once started");
			try{
			throw new Exception();
			}catch(Exception e){
				e.printStackTrace();
			}
		}
	}