Restoring server

Have you created a useful tool? or Do you want to get help building one? This is the right place!
Forum rules
READ NOW: L2j Forums Rules of Conduct
Post Reply
Battery
Posts: 27
Joined: Wed Oct 15, 2014 11:12 am

Restoring server

Post by Battery »

Yes, I've done it. I've destroyed my server trying to fix the errors I had from an incomplete l2jserver code written by the l2jserver team (my mistake, I should have noticed it contains only skill core and not Instance, zones etc.). But I have a backup of my old l2jserver.jar. Can I do something to restore my server and be able to edit its java files again simultaneously?

I tried Java Decompiler, but it doesn't show the spaces correctly, so every code is mistaken and I cannot add / delete spaces from 50 files that I want to replace.
User avatar
jurchiks
Posts: 6769
Joined: Sat Sep 19, 2009 4:16 pm
Location: Eastern Europe

Re: Restoring server

Post by jurchiks »

Sounds like you've never heard of source code...
If you have problems, FIRST TRY SOLVING THEM YOURSELF, and if you get errors, TRY TO ANALYZE THEM, and ONLY if you can't help it, THEN ask here.
Otherwise you will never learn anything if all you do is copy-paste!
Discussion breeds innovation.
Battery
Posts: 27
Joined: Wed Oct 15, 2014 11:12 am

Re: Restoring server

Post by Battery »

LoneRanger wrote:Sounds like you've never heard of source code...
Yes, and you have. So, do you know how to make an l2jserver.jar editable and imported in eclipse?
User avatar
AntV
Posts: 177
Joined: Mon May 10, 2010 10:46 pm

Re: Restoring server

Post by AntV »

I'm not quite sure that will do you any good...
Theoretically you could decompile the jar file and add it as a new project in eclipse, download l2jserver again and start checking for differences.
In practice I believe it will take you much more time than simply downloading a new version and start building from it to what you want to have. The biggest issue I believe you will face is that the decompiled jar will be way different than the new version.

Of course if you feel adventurous you can always try the first method, but since you seem to lack experience in both java and eclipse (don't want to sound rude or anything, it is just what I got from your previous post) I think you're better off forgetting it ever worked.


Also you said that the old one didn't work because you were missing what is essentially the data pack.
If that is the case, simply try downloading and compiling the data pack and put it with the .jar you salvaged.
Battery
Posts: 27
Joined: Wed Oct 15, 2014 11:12 am

Re: Restoring server

Post by Battery »

No, the old one didn't work because the java codes written by the L2Jserver team were containing only skill effects and not the changes that should be made in PCInstance.java etc and I didn't notice that, because the codes were too many, so, after adding them (and making a mess in skill effects), I started trying to add the appropriate codes in the other java files myself. And I did, and there was no error in eclipse, neither was there a problem in the server with the pre-existing skills. However, when I was trying to add the new skills in the datapack, StartGameServer.bat was acting as if they were missing core support.

So, when I found a new complete fix for some of these skills, I couldn't add the codes, because many of them were already existing incorrectly.

Anyway, it seems I build the server again. Do you know if there is a list of bugs, exploits in Interlude and diffs for their fixations?
Post Reply