[Guide] So you want a L2J Server
Forum rules
READ NOW: L2j Forums Rules of Conduct
READ NOW: L2j Forums Rules of Conduct
-
- Posts: 66
- Joined: Tue Dec 24, 2013 1:30 am
[Guide] So you want a L2J Server
This basic guide is meant for testing, and NOT for a Live server.
Briefing
Every L2J server you have played on has 2 main things.
L2J_SERVER files and L2J_DATAPACK files.
L2J_SERVER would be the mechanical part of your server. This part loads the datapack and allows connections.
L2J_DATAPACK would be the content part of your server. This part defines all aspects of the emulation.
A good analogy,
L2J_DATAPACK are the books in a library.
L2J_SERVER is the librarian who handles the books.
Software list
1.-Java
2.-Eclipse
3.-Xampp
NOTE: If you have set a root mysql password then write it down. You will have to put it into the LoginServer and GameServer configuration file, so that they can access to the MySql database.
4.-Heidi SQL
If you want any other client like Navicat, you can do so.
Repository Files
The Repository system allows easy simultaneous modification of the files from the developers.
More information about git
The current repository location is in: https://github.com/L2J
The Git system has something called "Branches". And the purpose is to separate different code versions.
Just to name a few there are C4, Gracia, Freya, Hi5 branches.
If you want to set up a Freya server, then you would have to get the Freya branch.
In this example i will be using the Hi5 Stable branch.
So you want a L2J Server?
-> Start Eclipse
-> Select a Workspace, it can be anywhere.
-> Go to Window
-> Show View
-> Project Explorer
Cloning Datapack
-> Copy this : https://github.com/L2J/L2J_DataPack.git
-> Inside the Project Explorer Window Right-Click
-> Import
-> Git
-> Projects From Git
-> Next
-> Clone URI
-> Paste inside URI
-> Next
-> Select the Branch you want
-> Finish
Cloning Serverpack
- >Copy this : https://github.com/L2J/L2J_Server.git
-> Inside the Project Explorer Window Right-Click
-> Import
-> Git
-> Projects From Git
-> Next
-> Clone URI
-> Paste inside URI
-> Next
-> Select Desired Branch
-> Finish
Compiling Datapack
-> Inside Project Explorer
-> Expand L2J_Datapack
-> Right-Click Build.xml
-> Run As
-> Ant Build
Compiling Serverpack
-> Inside Project Explorer
-> Expand L2J_Server
-> Right-Click Build.xml
-> Run As
-> Ant Build
Setting Up Files
-> Navigate to your L2J_DATAPACK file
-> Look for the build folder
-> Inside the build folder extract the compressed file
-> Copy all the content into a new folder you can call it how you want.
-> Navigate to your L2J_SERVER file
-> Look for the build folder
-> Inside the build folder extract the compressed file
-> Copy all the content into the folder you created. It will ask to overwrite. This is normal, press yes.
Installing Database
-> Run Xampp Control Panel
-> Press Start in MySQL
-> Run HeidiSQL
-> Log into your local Mysql Server
-> Create Databases: l2jls , l2jgs and l2jcs (use utf8-general_ci encoding)
-> Browse to yourserverfolder/tools
-> Run Dbinst_cs.jar (Community Server)
-> Fill in with your Mysql information.
-> Select Full Install
-> Repeat the process for Dbinst_ls.jar (Login Server) and Dbinst_gs.jar (Game Server), thanks to Unafraid
NOTE: If you have set a root mysql password then write it down. You will have to put it into the LoginServer and GameServer configuration file, so that they can access to the MySql database.
Optional: If you have set a root password for your MySql server then follow these steps:
-> Open yourserverfolder\login\L2J_Configurator.jar
-> Under LoginServer tab find "Password"
-> Type your MySql root password
-> Save and Close
-> Open yourserverfolder\game\L2J_Configurator.jar
-> Under Server tab find "Password"
-> Type your MySql root password
-> Save and Close
Starting the Server
-> Run yourserverfolder\game\StartGameServer ------------------ A Command Prompt Window will open, let it load
-> Run yourserverfolder\login\StartLoginServer ------------------ A Command Prompt Window will open, let it load
Logging in
Now that we have got our server up and running, its time to test it.
To play in the server, from the same pc, you need to edit your hosts file.
Located inside C:\Windows\System32\drivers\etc
Copy the file in your desktop, edit it with notepad adding these lines:
[pastebin]2pL4AN8K[/pastebin]
Save the file, copy from desktop and paste inside the C:\Windows\System32\drivers\etc directory.
I suggest you do it this way because sometimes windows will not allow you to edit and save the files when they are inside the operating system directory. E.g windows/system32/xxxx
Once you have saved the file. Start your Lineage 2 Client and test. (Accounts are auto create by default)
Do not edit the Lineage 2 Client because it is illegal
I hope you enjoyed the guide, if you are a seasoned L2J Developer and found any error or have a suggestion, submit a comment.
Happy testing!
UPDATE 29/12/14 ----> Changed DatabaseInstaller.bat/sh method to Dbinst_(ls,gs,cs) method.
Briefing
Every L2J server you have played on has 2 main things.
L2J_SERVER files and L2J_DATAPACK files.
L2J_SERVER would be the mechanical part of your server. This part loads the datapack and allows connections.
L2J_DATAPACK would be the content part of your server. This part defines all aspects of the emulation.
A good analogy,
L2J_DATAPACK are the books in a library.
L2J_SERVER is the librarian who handles the books.
Software list
1.-Java
2.-Eclipse
3.-Xampp
NOTE: If you have set a root mysql password then write it down. You will have to put it into the LoginServer and GameServer configuration file, so that they can access to the MySql database.
4.-Heidi SQL
If you want any other client like Navicat, you can do so.
Repository Files
The Repository system allows easy simultaneous modification of the files from the developers.
More information about git
The current repository location is in: https://github.com/L2J
The Git system has something called "Branches". And the purpose is to separate different code versions.
Just to name a few there are C4, Gracia, Freya, Hi5 branches.
If you want to set up a Freya server, then you would have to get the Freya branch.
In this example i will be using the Hi5 Stable branch.
So you want a L2J Server?
-> Start Eclipse
-> Select a Workspace, it can be anywhere.
-> Go to Window
-> Show View
-> Project Explorer
Cloning Datapack
-> Copy this : https://github.com/L2J/L2J_DataPack.git
-> Inside the Project Explorer Window Right-Click
-> Import
-> Git
-> Projects From Git
-> Next
-> Clone URI
-> Paste inside URI
-> Next
-> Select the Branch you want
-> Finish
Cloning Serverpack
- >Copy this : https://github.com/L2J/L2J_Server.git
-> Inside the Project Explorer Window Right-Click
-> Import
-> Git
-> Projects From Git
-> Next
-> Clone URI
-> Paste inside URI
-> Next
-> Select Desired Branch
-> Finish
Compiling Datapack
-> Inside Project Explorer
-> Expand L2J_Datapack
-> Right-Click Build.xml
-> Run As
-> Ant Build
Compiling Serverpack
-> Inside Project Explorer
-> Expand L2J_Server
-> Right-Click Build.xml
-> Run As
-> Ant Build
Setting Up Files
-> Navigate to your L2J_DATAPACK file
-> Look for the build folder
-> Inside the build folder extract the compressed file
-> Copy all the content into a new folder you can call it how you want.
-> Navigate to your L2J_SERVER file
-> Look for the build folder
-> Inside the build folder extract the compressed file
-> Copy all the content into the folder you created. It will ask to overwrite. This is normal, press yes.
Installing Database
-> Run Xampp Control Panel
-> Press Start in MySQL
-> Run HeidiSQL
-> Log into your local Mysql Server
-> Create Databases: l2jls , l2jgs and l2jcs (use utf8-general_ci encoding)
-> Browse to yourserverfolder/tools
-> Run Dbinst_cs.jar (Community Server)
-> Fill in with your Mysql information.
-> Select Full Install
-> Repeat the process for Dbinst_ls.jar (Login Server) and Dbinst_gs.jar (Game Server), thanks to Unafraid
NOTE: If you have set a root mysql password then write it down. You will have to put it into the LoginServer and GameServer configuration file, so that they can access to the MySql database.
Optional: If you have set a root password for your MySql server then follow these steps:
-> Open yourserverfolder\login\L2J_Configurator.jar
-> Under LoginServer tab find "Password"
-> Type your MySql root password
-> Save and Close
-> Open yourserverfolder\game\L2J_Configurator.jar
-> Under Server tab find "Password"
-> Type your MySql root password
-> Save and Close
Starting the Server
-> Run yourserverfolder\game\StartGameServer ------------------ A Command Prompt Window will open, let it load
-> Run yourserverfolder\login\StartLoginServer ------------------ A Command Prompt Window will open, let it load
Logging in
Now that we have got our server up and running, its time to test it.
To play in the server, from the same pc, you need to edit your hosts file.
Located inside C:\Windows\System32\drivers\etc
Copy the file in your desktop, edit it with notepad adding these lines:
[pastebin]2pL4AN8K[/pastebin]
Save the file, copy from desktop and paste inside the C:\Windows\System32\drivers\etc directory.
I suggest you do it this way because sometimes windows will not allow you to edit and save the files when they are inside the operating system directory. E.g windows/system32/xxxx
Once you have saved the file. Start your Lineage 2 Client and test. (Accounts are auto create by default)
Do not edit the Lineage 2 Client because it is illegal
I hope you enjoyed the guide, if you are a seasoned L2J Developer and found any error or have a suggestion, submit a comment.
Happy testing!
UPDATE 29/12/14 ----> Changed DatabaseInstaller.bat/sh method to Dbinst_(ls,gs,cs) method.
Last edited by canislupus on Tue Dec 30, 2014 5:14 am, edited 8 times in total.
So you want a L2J Server? Check out my guide viewtopic.php?f=81&t=30556&p=182721#p182721
- St3eT
- Posts: 961
- Joined: Sun Mar 07, 2010 6:50 pm
Re: So you want a L2J Server
Awesome, good job!
-
- Posts: 2
- Joined: Wed Aug 13, 2014 7:28 pm
Re: So you want a L2J Server
Thanks for guide. Can't find when wiki will be avaliable?
-
- Posts: 1
- Joined: Mon Dec 01, 2014 9:06 pm
Re: So you want a L2J Server
Edit: Nevermind, I downloaded modified system folder of lineage high five and it works now ![Very Happy :D](./images/smilies/icon_biggrin.gif)
Now, I need to figure out how to invite my friends to play with me...
![Very Happy :D](./images/smilies/icon_biggrin.gif)
Now, I need to figure out how to invite my friends to play with me...
-
- Posts: 66
- Joined: Tue Dec 24, 2013 1:30 am
Re: So you want a L2J Server
Thank you, will modify it tomorrow.
I guess pretty soon viewtopic.php?f=81&t=30493&p=182898&hilit=wiki#p182898St3eT wrote:Awesome, good job!
Updated to eclipse guide.Sequentiality wrote:Thanks for guide. Can't find when wiki will be avaliable?
So you want a L2J Server? Check out my guide viewtopic.php?f=81&t=30556&p=182721#p182721
-
- Posts: 5
- Joined: Wed Sep 28, 2011 12:10 am
Re: [Guide] So you want an L2J Server
This guide is very useful with the wikis gone and many of the guides elsewhere on the web being dodgy at best.
I have some questions:
Other guides say to copy the L2J_DataPack files into the folder that has the L2J_Server files. This guide says to copy the server files over the DataPack files. Does it make a difference?
Is it no longer necessary to run the login/RegisterGameServer.bat (or .sh) file and copy the resulting hexid.txt file into the game/config folder?
You say this is not a suitable guide for a live server. What would change if that were the case?
I have some questions:
Other guides say to copy the L2J_DataPack files into the folder that has the L2J_Server files. This guide says to copy the server files over the DataPack files. Does it make a difference?
Is it no longer necessary to run the login/RegisterGameServer.bat (or .sh) file and copy the resulting hexid.txt file into the game/config folder?
You say this is not a suitable guide for a live server. What would change if that were the case?
- UnAfraid
- L2j Veteran
- Posts: 4199
- Joined: Mon Jul 23, 2007 4:25 pm
- Location: Bulgaria
- Contact:
Re: [Guide] So you want a L2J Server
I'd suggest using dbinst_gs.jar, dbinst_ls.jar instead of databaseinstaller.bat/sh
-
- Posts: 66
- Joined: Tue Dec 24, 2013 1:30 am
Re: [Guide] So you want an L2J Server
I believe that merging the files from either L2J_Datapack or L2J_Server to another directory, will have the exact same output.Ardirion wrote:This guide is very useful with the wikis gone and many of the guides elsewhere on the web being dodgy at best.
I have some questions:
Other guides say to copy the L2J_DataPack files into the folder that has the L2J_Server files. This guide says to copy the server files over the DataPack files. Does it make a difference?
Is it no longer necessary to run the login/RegisterGameServer.bat (or .sh) file and copy the resulting hexid.txt file into the game/config folder?
You say this is not a suitable guide for a live server. What would change if that were the case?
Datapack and Server have same folders. But they have different components that need to be together.
Yes, you should add the HexId if you want a custom server name, this is usually not necessary for a test server. Because if no HexId file is detected, the system will assign the default name "Bartz". But it is worth mentioning.
I made this guide for newcomers mostly.
This will happen to you if you run a live server as a newb
https://www.youtube.com/watch?v=2m-42ek85G4
Nobody wants to lose their time in a server where the Gm/Admin has less than a week of experience.
What do i think you need to run a live server? I am not an expert, just to name a few..
Standalone sql installation. No apache, No php.
Focus on security
1, secure the sql with a custom user and password.
2, only allow sql access from localhost.
3, create firewall rules to allow only sql access from your IP.
4, create firewall rules and block everything that doesnt use login or game ports.
It also depends if your server runs on Linux or Windows.
Get used to working with Eclipse and Git.
I will try to add more content to the guide so that you dont end like Simba. and more like :
https://www.youtube.com/watch?v=YxFPE8xjzpI
Last edited by canislupus on Tue Dec 30, 2014 5:10 am, edited 2 times in total.
So you want a L2J Server? Check out my guide viewtopic.php?f=81&t=30556&p=182721#p182721
-
- Posts: 66
- Joined: Tue Dec 24, 2013 1:30 am
Re: [Guide] So you want a L2J Server
Thanks for the suggestion. Why is it better with the jars?UnAfraid wrote:I'd suggest using dbinst_gs.jar, dbinst_ls.jar instead of databaseinstaller.bat/sh
So you want a L2J Server? Check out my guide viewtopic.php?f=81&t=30556&p=182721#p182721
- UnAfraid
- L2j Veteran
- Posts: 4199
- Joined: Mon Jul 23, 2007 4:25 pm
- Location: Bulgaria
- Contact:
Re: [Guide] So you want a L2J Server
Its really simple to use, small amount of data to type, and it has GUI (and console for linux)canislupus wrote:Thanks for the suggestion. Why is it better with the jars?UnAfraid wrote:I'd suggest using dbinst_gs.jar, dbinst_ls.jar instead of databaseinstaller.bat/sh
-
- Posts: 66
- Joined: Tue Dec 24, 2013 1:30 am
Re: [Guide] So you want a L2J Server
Updated, thanks Unafraid!
So you want a L2J Server? Check out my guide viewtopic.php?f=81&t=30556&p=182721#p182721
-
- Posts: 1
- Joined: Wed Dec 31, 2014 11:57 am
Re: [Guide] So you want a L2J Server
a
Last edited by kope93 on Sat Jan 03, 2015 1:53 pm, edited 1 time in total.
- UnAfraid
- L2j Veteran
- Posts: 4199
- Joined: Mon Jul 23, 2007 4:25 pm
- Location: Bulgaria
- Contact:
Re: [Guide] So you want a L2J Server
Are you sure you used the correct branch.
If u haven't builded login server from Ertheia branch that can happen.
If u haven't builded login server from Ertheia branch that can happen.
-
- Posts: 441
- Joined: Mon May 05, 2014 10:15 am
Re: [Guide] So you want a L2J Server
All work fine
but i se you changed community bord.
if i click on favorite link it don't work.
how can i make it as it was so you canse who is online ans server info.
And at L2J_Configurator i don't get l2jdp-version and l2jdp-version is that normal ?
sorry for my bad english
thanks
but i se you changed community bord.
if i click on favorite link it don't work.
how can i make it as it was so you canse who is online ans server info.
And at L2J_Configurator i don't get l2jdp-version and l2jdp-version is that normal ?
sorry for my bad english
thanks
- UnAfraid
- L2j Veteran
- Posts: 4199
- Joined: Mon Jul 23, 2007 4:25 pm
- Location: Bulgaria
- Contact:
Re: [Guide] So you want a L2J Server
Yes since we use git there is no revision numbers anymore so we don't have *-version files anymore.Attila wrote:All work fine
but i se you changed community bord.
if i click on favorite link it don't work.
how can i make it as it was so you canse who is online ans server info.
And at L2J_Configurator i don't get l2jdp-version and l2jdp-version is that normal ?
sorry for my bad english
thanks
Community board is not entirely implemented yet.