Jump to content

[1.7.10] Internal Server Error on transferPlayerToDimension


DrPiggy

Recommended Posts

Hey, im trying to teleport players to another dimension when right clicking a sign, when the first guy right clicks the sign, its fine, he is teleported and everything, but after that, every time someone tries to use it, he gets an internal server error, BUT the guy who used it the first time can still use it! i have no idea what to do! the error doesn't even point to the dimension teleport!

(i know its the dimension teleport because when i comment it out it doesn't crash).

 

Code of the class: https://gist.github.com/DrPiggy/c9a21adbc9f879a983ff41bea5e2d21a

Error that shows up in the server: https://gist.github.com/DrPiggy/9dc34110ead5bc28e31acdd303dd3dc6

Error in client: https://gist.github.com/DrPiggy/ce68b357f1ef07df8415f9a37840947f

Link to comment
Share on other sites

1.7.10 isn't supported here any more, but I'm going to ask this anyway:

 

On these lines here:

https://gist.github.com/DrPiggy/c9a21adbc9f879a983ff41bea5e2d21a#file-commoneventhandler-java-L78-L82

Why do you get the item in the slot s, check that it's not null, and then instead of using the local variable that is the item in slot s, do you get the item in slot s again?

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

Just now, Draco18s said:

1.7.10 isn't supported here any more, but I'm going to ask this anyway:

 

On these lines here:

https://gist.github.com/DrPiggy/c9a21adbc9f879a983ff41bea5e2d21a#file-commoneventhandler-java-L78-L82

Why do you get the item in the slot s, check that it's not null, and then instead of using the local variable that is the item in slot s, do you get the item in slot s again?

no reason, i can change that, but i am not sure it contributes to the problem, also if 1.7.10 is not supported, where should i ask? :(

Link to comment
Share on other sites

No idea. Forge has moved on. You should update.

 

As for a Null Pointer Exception, those are easy to fix.  Find the thing that is null, figure out why it hasn't been assigned a value.

 

Use your debugger.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

Just now, Draco18s said:

No idea. Forge has moved on. You should update.

 

As for a Null Pointer Exception, those are easy to fix.  Find the thing that is null, figure out why it hasn't been assigned a value.

 

Use your debugger.

ah, you shouldn't tell me that, i usually make mods for 1.9, its just my friend's group play on 1.7 and asked me to make them a mod so i said why not, what debugger are you talking about? (unless you mean just output to console by myself every variable and check :P)

Link to comment
Share on other sites

debug.png

 

If you're not using Eclipse, google how to activate the debugger in your IDE.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.

 

Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.

 

DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

  • Guest locked this topic
Guest
This topic is now closed to further replies.


×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.