Jump to content




Java Exception thrown: java.lang.NullPointerException


  • You cannot reply to this topic
5 replies to this topic

#1 Dustmuz

  • Members
  • 174 posts
  • LocationDenmark

Posted 03 December 2015 - 10:32 AM

As the title says..

What does that mean

i know that it isnt the code i am using, as it hasnt changed, and worked yesterday afternoon when i last logged in..

#2 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 7,099 posts
  • LocationTasmania (AU)

Posted 03 December 2015 - 10:56 AM

It means that there was an error in the code that your code calls. Likely that error was triggered by your code, and the script wouldn't've worked anyway, but you ideally would've got a more descriptive error.

It's difficult to elaborate without access to your code, but usually the problem can be found in the way that a script is attempting to use a third-party peripheral. Sprinkling random print statements throughout should allow you to narrow down which of your script lines is leading to the crash.

#3 Dustmuz

  • Members
  • 174 posts
  • LocationDenmark

Posted 03 December 2015 - 11:02 AM

i just wonder how it could be the code, since it worked when i logged off the server yesterday afternoon, and it worked.
and the pack we are using havent been updated..

nothing really changed, except its now the 3rd december instead of the 2nd :)

but the code is here

Edited by Dustmuz, 03 December 2015 - 11:02 AM.


#4 Dustmuz

  • Members
  • 174 posts
  • LocationDenmark

Posted 03 December 2015 - 01:16 PM

and now the code works again. without me changing anything at all

#5 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 7,099 posts
  • LocationTasmania (AU)

Posted 03 December 2015 - 01:24 PM

My bet is on the reactor.setActive() calls. If it happens again, stick print statements before and after them, and consider checking on reactor.getConnected() before allowing your script to progress to its main loop. The reactor may not be ready for controlling immediately on chunkload, especially if it covers multiple chunks.

#6 Dustmuz

  • Members
  • 174 posts
  • LocationDenmark

Posted 03 December 2015 - 01:43 PM

I'll try that..

Thanks Bomb :)

Edited by Dustmuz, 03 December 2015 - 01:44 PM.






1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users