java.lang error when uploading

Hi, I've been working on a project for a while and have so far been able to compile and upload the sketch without problems until last night. Suddenly I got a " exec: "avr-g++": executable file not found in $PATH " error, which I fixed following this website's instructions Technoblogy - Programming ATtinys with Arduino 1.6.8 [Updated]. Then after I could compile I got this:

java.lang.NullPointerException
at cc.arduino.packages.uploaders.SerialUploader.uploadUsingPreferences(SerialUploader.java:81)
at cc.arduino.UploaderUtils.upload(UploaderUtils.java:78)
at processing.app.Sketch.upload(Sketch.java:1186)
at processing.app.Sketch.exportApplet(Sketch.java:1160)
at processing.app.Sketch.exportApplet(Sketch.java:1132)
at processing.app.Editor$DefaultExportHandler.run(Editor.java:2409)
at java.lang.Thread.run(Thread.java:745)

If I knew what it meant it would help, but any help would be appreciated !!

Are you able to verify and upload a different program without a problem?

If so, those errors generally mean that the Arduino folks did not include enough error correction code in the IDE program.

The usual cause is something missing in your code that has confused the Java program - perhaps an unclosed quote

...R

No, I can't even upload the Blink sketch. I thought it was to do with the new IDE version and the core I use for ATtiny, but my older 1.6.4 version, which also worked, gives a different .lang error

You need to provide more information.

Have you ever had a working version of the IDE?
If so, what changed between then and now?

What computer operating system are you using?
Has it changed?

What version of Java JRE or JDK are you using?
Has that changed?

...R

As I have said the problem only occurred last night, before then I was able to upload and compile any sketch. I recently upgraded from 1.6.4 to 1.6.9 but it was working after the upgrade. My current JRE version is 8.0.920.14, which I believe is the newest version. According to Java it ran the updater at 00:05 this morning. I am using Win8.1 x64.