- Joined
- Jan 4, 2010
- Messages
- 3
- Reaction score
- 3
Ok so im new to the forum and also new to running l2j server and fixing bugs its for my own fun i would like to share with ppl here maybe an idea to use AI for fixing bugs i have no coding experience or whatever and ofc. its hard to find "how to fix" some things on forums etc.
Let go straight to the problem which is 3rd job not showing up at lvl 76 how did i solve the problem? simple AI did the job for me so here is the copy of the process.
3rd job quest not showing up when reaching level 76
If the 3rd job change quest is not showing up for players when they reach level 76 in your Lineage 2 Java server, this is likely due to one of the following issues:
Copy
public class _473_ThirdLineage extends Quest {
private static final int[] NPCs = {30001, 30002}; // NPC IDs who start the quest
private static final int REQUIRED_LEVEL = 76;
public _473_ThirdLineage() {
super(473, "Third Lineage", "Third Class Transfer");
addStartNpc(NPCs);
addTalkId(NPCs);
}
@Override
public String onTalk(NpcInstance npc, Player player) {
if (player.getLevel() < REQUIRED_LEVEL) {
return "npc_condition_not_met.htm"; // Player is not level 76
}
if (!player.isInCategory(CategoryType.SECOND_CLASS_GROUP)) {
return "npc_wrong_class.htm"; // Player is not in the correct class group
}
// Start the quest
return "npc_start_quest.htm";
}
}
Copy
SELECT * FROM quests WHERE quest_id = 473;
SELECT * FROM npc WHERE npc_id IN (30001, 30002);
Copy
@Override
public String onTalk(NpcInstance npc, Player player) {
if (player.getLevel() < REQUIRED_LEVEL) {
log.warning("Player " + player.getName() + " is not level 76.");
return "npc_condition_not_met.htm";
}
if (!player.isInCategory(CategoryType.SECOND_CLASS_GROUP)) {
log.warning("Player " + player.getName() + " is not in the correct class group.");
return "npc_wrong_class.htm";
}
log.info("Starting 3rd job change quest for player " + player.getName());
return "npc_start_quest.htm";
}
html
Copy
<html>
<body>
You are ready for your 3rd class transfer. Are you prepared?<br>
<a action="bypass -h Quest _473_ThirdLineage">Start the quest.</a>
</body>
</html>
Run HTML
If you share more details about your server setup (e.g., L2J, L2OFF, custom modifications) or the specific issue you're encountering, I can provide more targeted assistance!
Ok so at this point i was still without any clue wtf should i do ofc. if i would ask the right question from the start i would get an answer... And than it gave a hit for what to look at and i came to this
Now that i got a hint of which file to look for i did and than i just put the file in AI to figure it out what is wrong with it or what was missing.
I’ve reviewed the Q10010_TimeToChangeClass.java script, and while it’s well-structured, there are a few issues that might be causing the 3rd job change quest not to work as expected. Below, I’ll outline the problems and provide fixes for each.
java
Copy
private boolean canStartQuest(Player player) {
return player.isInCategory(CategoryType.SECOND_CLASS_GROUP) && player.getLevel() >= 76;
}
java
Copy
private static final int[] NPCs = {30001, 30002}; // Add NPC IDs for class masters
public Q10010_TimeToChangeClass() {
super(QUEST_ID);
addStartNpc(NPCs);
addTalkId(NPCs);
addKillId(MONSTERS);
}
@Override
public String onTalk(Npc npc, Player player) {
if (!canStartQuest(player)) {
return "npc_condition_not_met.htm"; // Player does not meet the requirements
}
final QuestState questState = getQuestState(player, true);
if (!questState.isStarted() && !questState.isCompleted()) {
questState.startQuest();
return "npc_start_quest.htm"; // Start the quest
}
return "npc_already_started.htm"; // Quest already started
}
java
Copy
@Override
public String onKill(Npc npc, Player player, boolean isSummon) {
final QuestState questState = getQuestState(player, false);
if ((questState != null) && questState.isCond(QuestCondType.ACT)) {
int count = questState.getInt("count");
if (count < 10) { // Example: Kill 10 monsters
questState.set("count", count + 1);
} else {
questState.setCond(QuestCondType.DONE);
player.sendPacket(new ExQuestNotification(questState));
}
}
return super.onKill(npc, player, isSummon);
}
html
Copy
<html>
<body>
You are ready for your 3rd class transfer. Are you prepared?<br>
<a action="bypass -h Quest Q10010_TimeToChangeClass">Start the quest.</a>
</body>
</html>
Run HTML

i cant find npc_condition_not_met.html npc_start_quest.html npc_already_started.html
If the HTML dialogue files (npc_condition_not_met.htm, npc_start_quest.htm, and npc_already_started.htm) are missing, you’ll need to create them. These files are essential for the quest to function properly, as they provide the dialogue that players see when interacting with NPCs.
Below, I’ll provide the content for these files and explain where to place them.
html
Copy
<html>
<body>
You are not ready for your 3rd class transfer yet.<br>
Requirements:<br>
- Be at least level 76.<br>
- Be in your 2nd class.<br>
<a action="bypass -h Quest Q10010_TimeToChangeClass">Check again.</a>
</body>
</html>
Run HTML
html
Copy
<html>
<body>
You are ready for your 3rd class transfer. Are you prepared?<br>
<a action="bypass -h Quest Q10010_TimeToChangeClass">Start the quest.</a>
</body>
</html>
Run HTML
html
Copy
<html>
<body>
You have already started the 3rd class transfer quest.<br>
<a action="bypass -h Quest Q10010_TimeToChangeClass">Check your progress.</a>
</body>
</html>
Run HTML
Copy
data/html/default/
For example:
3. Update the Quest Script where do i find this
To update the quest script, you’ll need to locate the Q10010_TimeToChangeClass.java file in your server’s source code. Here’s how you can find and update it:
Copy
data/scripts/quests/Q10010_TimeToChangeClass.java
If you’re using an IDE (e.g., IntelliJ IDEA, Eclipse), you can search for the file by its name (Q10010_TimeToChangeClass.java) in the project.
Im using eclipse what to do after project build all
If you’re using Eclipse and have successfully built your project with Build All, the next steps involve deploying the updated server files and restarting the server to apply the changes. Here's a step-by-step guide:
Hopefully this is not to much for some of you but after logging in the game the 3rd job was fixed hopefully this post will help some of you to think outside the box and try to ask AI if you dont find or get the answers you are looking for on forums.
Cheers
Let go straight to the problem which is 3rd job not showing up at lvl 76 how did i solve the problem? simple AI did the job for me so here is the copy of the process.
3rd job quest not showing up when reaching level 76
If the 3rd job change quest is not showing up for players when they reach level 76 in your Lineage 2 Java server, this is likely due to one of the following issues:
- Quest Conditions Not Met: The quest might have additional requirements (e.g., completing a previous quest, having a specific item, or being in a certain location).
- Quest Script Missing or Broken: The quest script might be missing, incomplete, or incorrectly implemented.
- Level or Class Check Failure: The server might not be correctly checking the player's level or class to trigger the quest.
- Database Issues: The quest data might be missing or incorrect in the database.
Step 1: Verify Quest Requirements
Ensure that the player meets all the requirements for the 3rd job change quest. These typically include:- Reaching level 76.
- Completing the 2nd job change quest.
- Being in the correct class (e.g., not a subclass).
- Having the required items (if any).
Step 2: Check the Quest Script
The 3rd job change quest is usually implemented as a Quest Script in the server. Look for the script in your server's quests folder (e.g., data/quests). The script might be named something like _473_ThirdLineage or similar.Example Quest Script Structure:
javaCopy
public class _473_ThirdLineage extends Quest {
private static final int[] NPCs = {30001, 30002}; // NPC IDs who start the quest
private static final int REQUIRED_LEVEL = 76;
public _473_ThirdLineage() {
super(473, "Third Lineage", "Third Class Transfer");
addStartNpc(NPCs);
addTalkId(NPCs);
}
@Override
public String onTalk(NpcInstance npc, Player player) {
if (player.getLevel() < REQUIRED_LEVEL) {
return "npc_condition_not_met.htm"; // Player is not level 76
}
if (!player.isInCategory(CategoryType.SECOND_CLASS_GROUP)) {
return "npc_wrong_class.htm"; // Player is not in the correct class group
}
// Start the quest
return "npc_start_quest.htm";
}
}
Common Issues in Quest Scripts:
- Missing or incorrect NPC IDs.
- Incorrect level or class checks.
- Missing dialogue files (e.g., npc_start_quest.htm).
Step 3: Check the Database
The quest data is often stored in the database. Check the following tables:- quests: Ensure the 3rd job change quest is listed.
- npc: Verify that the NPCs who start the quest exist and have the correct IDs.
- player_quests: Check if the quest is being assigned to players correctly.
Example SQL Query:
sqlCopy
SELECT * FROM quests WHERE quest_id = 473;
SELECT * FROM npc WHERE npc_id IN (30001, 30002);
Step 4: Debugging the Issue
- Check Server Logs: Look for errors or warnings related to the quest or NPCs.
- Test with a GM Character: Use a GM character to manually trigger the quest and see if it works.
- Add Debug Logs: Add debug logs to the quest script to see where it might be failing.
Example Debug Logs:
javaCopy
@Override
public String onTalk(NpcInstance npc, Player player) {
if (player.getLevel() < REQUIRED_LEVEL) {
log.warning("Player " + player.getName() + " is not level 76.");
return "npc_condition_not_met.htm";
}
if (!player.isInCategory(CategoryType.SECOND_CLASS_GROUP)) {
log.warning("Player " + player.getName() + " is not in the correct class group.");
return "npc_wrong_class.htm";
}
log.info("Starting 3rd job change quest for player " + player.getName());
return "npc_start_quest.htm";
}
Step 5: Fixing the Issue
Based on what you find, here are some possible fixes:- Update the Quest Script: Ensure the script has the correct NPC IDs, level checks, and class checks.
- Add Missing Data: If the quest or NPCs are missing from the database, add them.
- Fix Dialogue Files: Ensure the HTML dialogue files (e.g., npc_start_quest.htm) exist in the data/html folder.
Example Fix: Adding Missing NPC Dialogue
If the NPC dialogue is missing, create a file like data/html/default/30001.htm with the following content:html
Copy
<html>
<body>
You are ready for your 3rd class transfer. Are you prepared?<br>
<a action="bypass -h Quest _473_ThirdLineage">Start the quest.</a>
</body>
</html>
Run HTML
Final Steps
- Restart the server after making changes.
- Test the quest with a character that meets the requirements.
- Verify that the quest starts correctly and progresses as expected.
If you share more details about your server setup (e.g., L2J, L2OFF, custom modifications) or the specific issue you're encountering, I can provide more targeted assistance!
Ok so at this point i was still without any clue wtf should i do ofc. if i would ask the right question from the start i would get an answer... And than it gave a hit for what to look at and i came to this
Common 3rd Job Quest Scripts
Here are some common script names or IDs that might be related to the 3rd job change quest:- _473_ThirdLineage.java
- Q10010_TimeToChangeClass.java
- Q10011_GoingOut.java
- Q10012_ThirdClassTransfer.java
Now that i got a hint of which file to look for i did and than i just put the file in AI to figure it out what is wrong with it or what was missing.
I’ve reviewed the Q10010_TimeToChangeClass.java script, and while it’s well-structured, there are a few issues that might be causing the 3rd job change quest not to work as expected. Below, I’ll outline the problems and provide fixes for each.
Key Issues
- Missing Level 76 Check:
- The script does not explicitly check if the player has reached level 76 before allowing them to start the quest.
- Missing NPC Interaction:
- The script does not include NPC interaction to start the quest. Typically, players should talk to an NPC (e.g., their class master) to initiate the quest.
- Incomplete Quest Logic:
- The quest logic is focused on teleporting the player and setting conditions but does not include steps for completing the 3rd job change (e.g., killing monsters, collecting items, or talking to NPCs).
- Missing HTML Dialogue Files:
- The script references HTML dialogue files (e.g., npc_start_quest.htm), but these files might be missing or incorrectly configured.
Fixes
1.
The script should explicitly check if the player has reached level 76 before allowing them to start the quest. Update the canStartQuest method:java
Copy
private boolean canStartQuest(Player player) {
return player.isInCategory(CategoryType.SECOND_CLASS_GROUP) && player.getLevel() >= 76;
}
2.
The quest should include NPC interaction to start the quest. Add NPC IDs and interaction logic:java
Copy
private static final int[] NPCs = {30001, 30002}; // Add NPC IDs for class masters
public Q10010_TimeToChangeClass() {
super(QUEST_ID);
addStartNpc(NPCs);
addTalkId(NPCs);
addKillId(MONSTERS);
}
@Override
public String onTalk(Npc npc, Player player) {
if (!canStartQuest(player)) {
return "npc_condition_not_met.htm"; // Player does not meet the requirements
}
final QuestState questState = getQuestState(player, true);
if (!questState.isStarted() && !questState.isCompleted()) {
questState.startQuest();
return "npc_start_quest.htm"; // Start the quest
}
return "npc_already_started.htm"; // Quest already started
}
3.
The quest should include steps for completing the 3rd job change. For example, the player might need to kill specific monsters or collect items. Add logic for this:java
Copy
@Override
public String onKill(Npc npc, Player player, boolean isSummon) {
final QuestState questState = getQuestState(player, false);
if ((questState != null) && questState.isCond(QuestCondType.ACT)) {
int count = questState.getInt("count");
if (count < 10) { // Example: Kill 10 monsters
questState.set("count", count + 1);
} else {
questState.setCond(QuestCondType.DONE);
player.sendPacket(new ExQuestNotification(questState));
}
}
return super.onKill(npc, player, isSummon);
}
4.
Ensure the following HTML files exist in the data/html folder:- npc_condition_not_met.htm: Informs the player they do not meet the requirements.
- npc_start_quest.htm: Starts the quest.
- npc_already_started.htm: Informs the player the quest is already in progress.
html
Copy
<html>
<body>
You are ready for your 3rd class transfer. Are you prepared?<br>
<a action="bypass -h Quest Q10010_TimeToChangeClass">Start the quest.</a>
</body>
</html>
Run HTML
Next Steps
- Add the missing HTML dialogue files.
- Verify the database entries for the quest and NPCs.
- Restart the server and test the quest with a level 76 character.
i cant find npc_condition_not_met.html npc_start_quest.html npc_already_started.html
If the HTML dialogue files (npc_condition_not_met.htm, npc_start_quest.htm, and npc_already_started.htm) are missing, you’ll need to create them. These files are essential for the quest to function properly, as they provide the dialogue that players see when interacting with NPCs.
Below, I’ll provide the content for these files and explain where to place them.
1.
npc_condition_not_met.htm
This file is shown when the player does not meet the requirements to start the quest (e.g., not level 76 or not in the correct class group).html
Copy
<html>
<body>
You are not ready for your 3rd class transfer yet.<br>
Requirements:<br>
- Be at least level 76.<br>
- Be in your 2nd class.<br>
<a action="bypass -h Quest Q10010_TimeToChangeClass">Check again.</a>
</body>
</html>
Run HTML
npc_start_quest.htm
This file is shown when the player meets the requirements and can start the quest.html
Copy
<html>
<body>
You are ready for your 3rd class transfer. Are you prepared?<br>
<a action="bypass -h Quest Q10010_TimeToChangeClass">Start the quest.</a>
</body>
</html>
Run HTML
npc_already_started.htm
This file is shown when the player has already started the quest.html
Copy
<html>
<body>
You have already started the 3rd class transfer quest.<br>
<a action="bypass -h Quest Q10010_TimeToChangeClass">Check your progress.</a>
</body>
</html>
Run HTML
2.
These HTML files should be placed in the data/html folder of your server. The exact path depends on your server setup, but it’s typically something like:Copy
data/html/default/
For example:
- data/html/default/npc_condition_not_met.htm
- data/html/default/npc_start_quest.htm
- data/html/default/npc_already_started.htm
3. Update the Quest Script where do i find this
To update the quest script, you’ll need to locate the Q10010_TimeToChangeClass.java file in your server’s source code. Here’s how you can find and update it:
1.
The quest script is typically located in the data/scripts/quests folder of your server’s source code. The exact path depends on your server setup, but it’s usually something like:Copy
data/scripts/quests/Q10010_TimeToChangeClass.java
If you’re using an IDE (e.g., IntelliJ IDEA, Eclipse), you can search for the file by its name (Q10010_TimeToChangeClass.java) in the project.
2.
Once you’ve located the file, open it in a text editor or IDE. The file should look like the one you shared earlier.4.
After updating the script, save the file.5.
If you’ve made changes to the source code, you’ll need to recompile the server. Here’s how:- Open your IDE (e.g., IntelliJ IDEA, Eclipse).
- Build the project:
- In IntelliJ: Build > Build Project.
- In Eclipse: Project > Build All.
- If you’re using a build tool like Maven or Gradle, run the appropriate command:
- Maven: mvn clean install
- Gradle: gradle build
Im using eclipse what to do after project build all
If you’re using Eclipse and have successfully built your project with Build All, the next steps involve deploying the updated server files and restarting the server to apply the changes. Here's a step-by-step guide:
1.
After building the project, Eclipse compiles the Java files into .class files. These files are typically located in the bin or target folder of your project, depending on your setup.- Default Location: YourProjectFolder/bin/
- Maven Location: YourProjectFolder/target/classes/
2.
You need to copy the updated .class files to your server’s data/scripts folder. Here’s how:- Navigate to the folder where Eclipse compiled the files (e.g., bin/ or target/classes/).
- Locate the compiled quest file:
- For Q10010_TimeToChangeClass, the file will be in a subfolder like quests/Q10010_TimeToChangeClass.class.
- Copy the .class file to your server’s data/scripts/quests/ folder.
3.
After updating the files, restart your server to apply the changes. Here’s how:- Stop the server if it’s running.
- Start the server again.
4.
- Log in with a level 76 character in the 2nd class.
- Talk to the NPC (e.g., class master) to start the quest.
- Verify that the correct dialogue is shown and the quest progresses as expected.
Detailed Steps for Eclipse
Step 1: Build the Project
- Open Eclipse.
- Right-click on your project in the Project Explorer.
- Select Build Project or Build All.
Step 2: Locate the Compiled Files
- In Eclipse, navigate to the bin or target/classes folder in your project.
- Find the compiled .class file for the quest:
- Example: bin/quests/Q10010_TimeToChangeClass.class.
Step 3: Copy the Files to the Server
- Open your server’s data/scripts/quests/ folder.
- Copy the .class file from Eclipse to this folder.
Step 4: Restart the Server
- Stop the server if it’s running.
- Start the server again.
Hopefully this is not to much for some of you but after logging in the game the 3rd job was fixed hopefully this post will help some of you to think outside the box and try to ask AI if you dont find or get the answers you are looking for on forums.
Cheers
Last edited:

