Jump to content

[Guide]L2j FAQ


Recommended Posts

Are u new to L2j Developing?

Would you like to learn how to Create a powerfull Server??!!?

Then That's The Guide  which Will Help You.

 

I.Eclipse

II.Patches, modifications

III.Compiling

IV.Update Revision

V.Preconficure Packs

VI.Datapack Modifications

VII.Q&A

VII.Packs

VIII.Add Skills

 


Part I: Eclipse

Download Eclipse From here : http://www.eclipse.org/downloads/download.php?file=/eclipse/downloads/drops/R-3.5-200906111540/eclipse-SDK-3.5-win32.zip

Also Dont forget to Install Java JDK.

 

Select your workspace etc. Now go on Install Updates --> Add---> Name: SubEclipse Site : http://subclipse.tigris.org/update_1.6.x --> Press Next and Select subeclipse-->The Install.Now your eclipse will be restart.


From killer_007:

 

Now we have to configure java. Go to window (upper right corner of program's screen) and then preferences. Check that cross on java (in order to expand that box) and then click on Installed JREs. Select jdk and unselect jre (if you have both of them installed). Press ok. (Remember that if it can't find it, you have to add the path manually using the add button... for me the path is: C:\Program Files\Java\jdk1.5.0_04

guide12ik9.jpg

guide13cf6.jpg

 

After That We are Ready For starting Developing Our Project :D

 

1st of all go to Windows-->Show and Vew--> SvN --> SvN Reposity

Now use right click on the new tab on the white space, then new and finally Repository location.

For Example : http://www.l2jserver.com/svn/

Then We open the reposity and We checkOut The Trunk.

Do the same with l2jdb : http://www.l2jdb.com/svn/

After The DP is CheckedOut, Right click on Our DP, select Properties and then Build Path (only L2j Latest Realease) then click Projects and we add our Gameserver, then go Libraries and add all the files in Gameserver/libs....

With that way we make a syntax hightlighting in l2jdb.


Part 2 : Patches,Modifications

If you want to make your own Patches then u must do 2 things :D

1st Learn Java , (best Book out there: http://java.sun.com/docs/books/tutorial/index.html )

2nd Learn most of l2j Classes. (Most difficultpart for me :D )

Note: This isnt 1 day work....

 

Now We find for example this patch :

Index: C:/workspace/L2J-Archid-Game/config/mods/customs.properties
===================================================================
--- C:/workspace/L2J-Archid-Game/config/mods/customs.properties	(revision 721)
+++ C:/workspace/L2J-Archid-Game/config/mods/customs.properties	(working copy)
@@ -212,6 +212,11 @@
# Syntax: .autoherbs_on .autoherbs_off 
AllowAutoHerbsCommand = false

+# Allow NullKarma Command
+# Usage : .nokarma
+# When a Player has >0 karma , it gets nullified.
+AllowNullKarmaCommand = False
+
# Show the GM's name who made the announcement.
# example: "Announce: hi [GM]"
AnnounceGmName = False
Index: C:/workspace/L2J-Archid-Game/src/main/java/com/l2jarchid/gameserver/handler/MasterHandler.java
===================================================================
--- C:/workspace/L2J-Archid-Game/src/main/java/com/l2jarchid/gameserver/handler/MasterHandler.java	(revision 721)
+++ C:/workspace/L2J-Archid-Game/src/main/java/com/l2jarchid/gameserver/handler/MasterHandler.java	(working copy)
@@ -177,6 +177,7 @@
import com.l2jarchid.gameserver.handler.voicedcommandhandlers.Away;
import com.l2jarchid.gameserver.handler.voicedcommandhandlers.Banking;
import com.l2jarchid.gameserver.handler.voicedcommandhandlers.JoinVIP;
+import com.l2jarchid.gameserver.handler.voicedcommandhandlers.NullKarma;
import com.l2jarchid.gameserver.handler.voicedcommandhandlers.Online;
import com.l2jarchid.gameserver.handler.voicedcommandhandlers.Wedding;
import com.l2jarchid.gameserver.handler.voicedcommandhandlers.stat;
@@ -403,6 +404,10 @@
		if(Config.ALLOW_ONLINE_VCOMMAND)
		VoicedCommandHandler.getInstance().registerVoicedCommandHandler(new Online());

+		if(Config.ALLOW_NULLKARMA_COMMAND)
+		{
+		VoicedCommandHandler.getInstance().registerVoicedCommandHandler(new NullKarma());
+		}
	}

	public static void load()
Index: C:/workspace/L2J-Archid-Game/src/main/java/com/l2jarchid/Config.java
===================================================================
--- C:/workspace/L2J-Archid-Game/src/main/java/com/l2jarchid/Config.java	(revision 721)
+++ C:/workspace/L2J-Archid-Game/src/main/java/com/l2jarchid/Config.java	(working copy)
@@ -1567,7 +1567,8 @@
     **************************************************************************/
	public static boolean CURSED_WEAPON_PLAYER_USE_POTS;
	public static boolean NOBLE_STATUS_NEEDED_TO_USE_HERO_ITEM;
-
+	public static boolean ALLOW_NULLKARMA_COMMAND;
+	
	// Four Sepulchers
	public static int FS_TIME_ATTACK;
	public static int FS_TIME_COOLDOWN;
@@ -1679,7 +1680,7 @@
	        ARCHID_AWAY_TIMER = Integer.parseInt(CustomMod.getProperty("AwayTimer", "30"));
	        ARCHID_BACK_TIMER = Integer.parseInt(CustomMod.getProperty("BackTimer", "30"));
	        ARCHID_AWAY_PEACE_ZONE = Boolean.parseBoolean(CustomMod.getProperty("AwayOnlyInPeaceZone", "False"));
-
+	        ALLOW_NULLKARMA_COMMAND = Boolean.parseBoolean(CustomMod.getProperty("AllowNullKarmaCommand", "False"));
	        CHAR_TITLE = Boolean.parseBoolean(CustomMod.getProperty("CharTitle", "false"));
	    	ADD_CHAR_TITLE = CustomMod.getProperty("CharAddTitle", "Welcome");
            NOBLE_CUSTOM_ITEMS = Boolean.parseBoolean(CustomMod.getProperty("EnableNobleCustomItem", "true"));

(by Stefoulis15)

And We dont know how to add it!!!And u ask : What should I do???

Simply Read my Guide :

http://www.maxcheaters.com/forum/index.php?topic=64593.0

 

Simply Now U have Add Your Patch :D

 

Now go to gameserver/config and open each config with eclipse and edit them.....

 


Part 3 : Compiling

The Most Important Part :D

After u Did all the Modifications, u will need to compile your Pack :D

 

If you are using an l2j based pack Like : l2j,l2jdot,l2jarchid(I think),l2jequal,l2emu and l2jofficial

Then Simply go to gamerver/build.xml and right Click-->Run-->Ant Build

And you Simply Build your Own gs pack... u will see that in build folder there are 2 files : l2jserver.java and l2jgameserver.zip , In l2jgamerver.zip there is our pack, the l2jserver.java is our java modifications......

 

If you are using an l2jfree based pack like : l2jfree  where there is only a pom.xml u will need to use maven ...

Datapack:Really simple right click on Build.xml->Run as->1 Ant build.

Core:l2jfree use maven so you need to compile it with maven.(Other pack use Build.xml to core too)

Compile l2jfree core:

before you compile you need to do 2 things.

1st open control panel->system->special->variables

You need to add new system variable for java jdk.Add these lines to user and system variables.

Variable name:JAVA_HOME

Varible path:C:\Program Files\Java\jdk1.6.0_11

Now restart your PC.

Open maven\bin\mvn.bat with notepad go to line 157 and write this:

old one:%MAVEN_JAVA_EXE% %MAVEN_OPTS% -classpath %CLASSWORLDS_JAR%

new one:%MAVEN_JAVA_EXE% %MAVEN_OPTS% "-Xmx1024m" -classpath %CLASSWORLDS_JAR%

Now compile the core:

open a command line(start->run->cmd)

go to your core folder(for example the core is c:\workspace\l2jfree-core)

type cd C:\

type cd workspace

type cd l2jfree-core

Now you need to compile:

type C:\maven\bin\mvn clean:clean

thats delete the excisting compile(Target folder)if you have.

type C:\maven\bin\mvn assembly:assembly -Dmaven.test.skip=true

thats build your core and place it to l2jfree-core\target folder.

Thx Intrepid


Part IV : Updating Rev

Everyday all the projects Updates The l2j projects, the updates are in java and properties files....

To Update our Core we simply : Right Click on gamerver --->Team-->Update to Head

Now It will download all the files :D

After that is finished, We simply Build again our project and we replace our old files :D

 

Now to update our DP, we do the same but, If we have sql Updates u will need to update your DB , How?

Look:

1. Make sure you have a working database of your new rev installed on MySQL (preferable a separate PC / laptop)

2. Work all of your new rev files just like being a full new release and you had none before (config, data, new NPC's, etc.)

3. Start login server and game server to make sure it's really working without errors

4. If everything is OK, dump your database to an SQL file

 

...and now for the "complicated" part...

 

5. If you had that on a separate PC, copy new rev on your server machine, along with your dumped SQL file

6. Make a separate DB on your server MySQL connection, like l2clean or whatever Smiley

7. Make sure you have altered server.properties and login.properties to match your internal / external IP

8. Stop your server (nasty !!!)

9. Go on Navicat to Tools -> Structure Syncronization

10. Left side -> (your connection name) -> (your new rev db)

11. Right side -> (your connection name) -> (your GS db)

12. Press "Compare" button

13. After compare has been done -> press "Run query" button

14. After successful completion go to Tools -> Data Syncronization

15. Left side -> (your connection name) -> (your GS db)

16. Right side -> (your connection name) -> (your new rev db)

17. Go "Advanced" and remove the mark from "Delete records"

 

Remark: BE SURE YOU REMOVED THAT MARK BEFORE STARTING !!!

 

18. Press "Preview" button

 

You will get 6 or 7 errors, tables which you should copy to a temporary DB FROM YOUR NEW REV DB and copy back after completion...

 

Normally this tables are:

boxaccess

clan_wars

pledge_skill_trees

posts

skill_spellbooks

topic

zone

 

19. If on "Preview" is everything OK then press "Start" to upgrade

 

BE SURE YOU HAVE COMPLETED POINT 17 BEFORE !!!

 

20. Now just dump SQL file of your old DB and copy your new DB instead

21. start your login server

22. start your game server

23. YOU'RE DONE !!!!!

Thx A-style aka GodOfAden

And Like this we update our DB :D


Part V: Preconficure Packs

 

Most of the people are start with a preconficure Pack, That's very bad, because :

You dont have the source, and u cant do any modifications in Java, that means that: ucant fix L2 phx hacks (client packets) and u cant add any modification, and the most importand think for me : U cant update your server.....

 

What I want to say ,  Preconficure Packs are the worst packs for a l2j server.....

Do U want a server???? Just Compile it!!!


Part VI : DataPack Modifications

 

If you are using l2j, u can see that from gracia , the admin-players commands have been tranfered to Datapack... That's Why We Use Syntax hightlighting, because many java files have tranfered to DP.

Except Of Them, DP has all the HTML,Xml,Quest Scripts etc <--- All of that, are use a big ammount of Ram , which may cause sometimes Lag....

When U make a server x100+ with class manager, there are several files that can be deleted...

Let's Go to scripts/Quest , there are more than 800+ quest .... But because We have a "PvP" Server , we dont need them , so we delete them....

Delete all the quest that you dont need.... ( Better all except , Nobless quest)

Also u can also delete some (if not all) multisell files if you want.., also there are some HtmL files that can also removed, check the id : id.html , and  if you dont need them then delete the  html + for the spawnlist.



Part VII: Q&A :

Q: How Can I run my server??

A: Simply Look this topic: http://www.maxcheaters.com/forum/index.php?topic=50068.0

 

Q: How Can I change the buff time?

A: If you are using an l2j pack hellbound or later, then go to character.properties and find this Line: SkillDurationList =

After that add :

271,4200;272,4200;273,4200;274,4200;275,4200;276,4 200;277,4200;307,4200;309,4200;310,4200;311,4200;3 66,4200;367,4200;530,4200;\

264,4200;265,4200;266,4200;267,4200;268,4200;269,4 200;270,4200;304,4200;305,4200;306,4200;308,4200;3 49,4200;363,4200;364,4200;437,4200;529,4200;\

1002,4200;1003,4200;1005,4200;1006,4200;1007,4200; 1009,4200;1010,4200;1229,4200;1251,4200;1252,4200; 1253,4200;1284,4200;1308,4200;1309,4200;1310,4200; 1362,4200;1363,4200;1390,4200;1391,4200;1413,4200; 1461,4200;\

1353,4200;1311,4200;1307,4200;1204,4200;1085,4200; 1078,4200;1077,4200;1062,4200;1044,4200;1043,4200; 1035,4200;1068,4200;1040,4200;1073,4200;\

1191,4200;1189,4200;1182,4200;1033,4200;1259,4200; \

1032,4200;1036,4200;1045,4200;1048,4200;1086,4200; 1240,4200;1242,4200;1243,4200;1388,4200;1389,4200; 1392,4200;1393,4200;1352,4200;\

1355,4200;1356,4200;1357,4200;\

1087,4200;1257,4200;1397,4200;1304,4200;1303,4200; 1354,4200;\

1059,4200;1268,4200

 

U can change the time by changing to 4200(s) number.

If you are using another pack, then u have to go to Stats/skills find your skill, and change the duretion : 3600 for 1 hour etc ...

 

Q:How can I execute an SQL?

A: Simply , go to navicat/localhost/l2jdb right click execute SQL...

 

Q:How can i change a stat of a(n) armor/weapon?

A: Go to Stats/Armors or Weapons/find your weapon ID, find it in a file,And change the Val of stats, Stats are : pDef ,mDef,pAtk,mAtk etc

 

Part VIII: Packs

In this part, I will help you to choose a Pack.

Gracia Final Packs:


l2jserverlogo.png

TimeLine: http://www.l2jserver.com/trac/timeline and http://www.l2jdb.com/trac/timeline

SvN: http://www.l2jserver.com/svn/ && http://www.l2jdb.com/svn/


L2jOfficial:

TimeLine: http://trac.assembla.com/L2jOfficial/timeline

SvN: http://svn.assembla.com/svn/L2jOfficial/


L2Emu:

TimeLine: http://trac-l2emu.no-ip.info:8060/changelog/L2Emu

Svn: http://svn-l2emu.no-ip.info:8080/svn/L2Emu/


Now For IL:

l2jArchid:

SVN Url: http://svn.assembla.com/svn/L2J-Archid

TimeLine: http://trac.assembla.com/L2J-Archid/timeline


l2j-equal:

 

SVN : http://my-svn.assembla.com/svn/L2J-Equal/

Timeline: http://my-trac.assembla.com/L2J-Equal/timeline

 


To do the character to auto Learn skills that you created or other classes simply. Ceate an sql like this:

INSERT INTO `skill_trees` VALUES ('0', '3', '1', 'Power Strike', '50', '5');

0 = the class ID

3 = skill ID

1= level

50 = SP needed

and

5 is the level needed to be to learn the skill :D easy

 

 

That's All.

Ps: Dont be bad with me LoL

Ps2: It is only some things for newbies.If you want more expert think to learn: http://www.maxcheaters.com/forum/index.php?topic=73559.0

Link to comment
Share on other sites

Nice "FAQ" TheEnd, well, very nice guide for newbie Admins :)

Thank you Matim.

I make that for people who ask help in help section...

Link to comment
Share on other sites

0wn Great Share TheEnd! I think you the first that make a tut about eclipse :D

Many N44bs use Ready Packs ;)

It isnt the first :D

But I have all in one :D

Link to comment
Share on other sites

add l2jarchid timeline too

 

Trac / Timeline : http://trac.assembla.com/L2J-Archid/timeline

 

SVN : http://svn.assembla.com/svn/L2J-Archid

 

 

awesome work once again :)

Link to comment
Share on other sites

add l2jarchid timeline too

 

Trac / Timeline : http://trac.assembla.com/L2J-Archid/timeline

 

SVN : http://svn.assembla.com/svn/L2J-Archid

 

 

awesome work once again :)

I had add it...as it is the best IL project...

 

Wow really nice guide thend

thanks for sharing with us !

thx

 

~Titlte Changed

Link to comment
Share on other sites

Awesome!

 

I never leave comments like ''I like it'' etc,but this topic reverse it!

 

+1 by me,cuz I am newbie at this kind of developing,and it really helped me!

 

Also,is nice-looking!

 

Keep on TheEnd.

Link to comment
Share on other sites

Ps2: It is only some things for newbies.If you want more expert think to learn: http://www.maxcheaters.com/forum/index.php?topic=73559.0

 

thanks for adding my Guide  :)

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...

AdBlock Extension Detected!

Our website is made possible by displaying online advertisements to our members.

Please disable AdBlock browser extension first, to be able to use our community.

I've Disbaled AdBlock