You sure it do not print out more like what file it causing it?
|
Hello,
I wonder if anybody could help me.
Sometimes when people try to login on the server it prints this
java.lang.ArrayIndexOutOfBoundsException
in the console and kicks them back out
They have to try multiple times before the server lets them on.
i've been looking everywhere for a solution some people say its cache related but i've put the cache
in my data file so fuck noes
Any help would be appreciated
thanks
You sure it do not print out more like what file it causing it?
Have you tried running the server in debug mode with the option enabled to stop code execution when a certain type of exception is thrown?
EDIT: I mean within an IDE
Last edited by TheChosenOne; 06-04-2019 at 09:36 PM. Reason: Clarification
java.lang.ArrayIndexOutOfBoundsException is the only thing that prints when it happens, If i go to the arrayutils file there is alot of outofbounds text so unsure which one it is.
Apparently it happens on other servers using my source aswell. This is the code : https://pastebin.com/5iEBp7s6
So on eclipse just right click and click debug as? I've not clue how to enable that other option
Within eclipse you can click left of the line which you want to read data from. A small circle will appear and then run the server in debug mode. Once the debugger reaches the line of code, the server will pause
Take a look at this link, it explains how to break on certain exceptions: https://help.eclipse.org/oxygen/inde...exceptions.htm
Thank you guys, i'll try this out.
This is what is causing it i'm fairly certain but no clue how to fixjava.lang.ArrayIndexOutOfBoundsException: 512
at ethos.util.Stream.writeBits(Stream.java:384)
at ethos.model.players.Player.addNewNPC(Player.java:3 477)
at ethos.model.players.PlayerHandler.updateNPC(Player Handler.java:251)
at ethos.model.players.Player.update(Player.java:1260 )
at ethos.model.players.PlayerHandler.process(PlayerHa ndler.java:195)
at ethos.Server.lambda$0(Server.java:174)
at java.util.concurrent.Executors$RunnableAdapter.cal l(Unknown Source)
at java.util.concurrent.FutureTask.runAndReset(Unknow n Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$S cheduledFutureTask.access$301(Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$S cheduledFutureTask.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker( Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run (Unknown Source)
at java.lang.Thread.run(Unknown Source)
player.java reads : str.writeBits(14, id);
I think its because its out of bounds, what should i change this to?
« Previous Thread | Next Thread » |
Thread Information |
Users Browsing this ThreadThere are currently 1 users browsing this thread. (0 members and 1 guests) |