Jump to content
  • 0

Npc gone after restarting


Question

Posted (edited)

As mentioned in the title, I lose Npcs after restarting the server from the admins panel. The problem is, I never had this issue before. Also it's not for certain Npc, it's for all Npc. What i mean is, all the Npc I spawned before I started getting this issue are still in place. Whatever I spawn now is gone after restarting. It's like I exceeded the limit of spawns. Tried searching here but nothing was applicable for me (even though others had this issue). Is there anyone who had this issue or anyone who knows how to solve this? Thanks in advance.

(aCis 382)

Edited by Hann1bal

9 answers to this question

Recommended Posts

  • 0
Posted

//spawn_once doesn't save the Spawn into db, other than that there is no reason it bugs (from memory).

 

Verify first if there are correctly on db, if not, it's normal it can't load - magic can't happen.

 

If they are on db, there are only few cases where it won't generate a Spawn, and most of them got an error message associated to it (wrong NpcTemplate, wrong type of Npc - Guards, Bosses, etc).

  • 0
Posted (edited)
36 minutes ago, HowardStern said:

which pack?

 

8 hours ago, Hann1bal said:

(aCis 382)

 

 

Edited by Hann1bal
  • 0
Posted
1 hour ago, Tryskell said:

//spawn_once doesn't save the Spawn into db, other than that there is no reason it bugs (from memory).

 

Verify first if there are correctly on db, if not, it's normal it can't load - magic can't happen.

 

If they are on db, there are only few cases where it won't generate a Spawn, and most of them got an error message associated to it (wrong NpcTemplate, wrong type of Npc - Guards, Bosses, etc).

I use //spawn command. I already have custom npcs spawned into the game which are saved after restarting. For some reason, no npc is saved from now on, even if I spawn existing in-game Npcs like Clarissa(30080).

  • 0
Posted
2 hours ago, MoNsT3ReN4RgY said:

propably you messed up something last time you edit something..

That's what I'm thinking but last stuff I edited was itemhandler for hero coin etc, I didn't edit any spawn related class.

  • 0
Posted
On 10/18/2020 at 1:07 PM, Tryskell said:

If they are on db, there are only few cases where it won't generate a Spawn, and most of them got an error message associated to it (wrong NpcTemplate, wrong type of Npc - Guards, Bosses, etc).

Solved the issue. Apprarenlty I forgot a NPC I was trying to make. Deleted Class from eclipse but not the NPC in the XML, so it had "wrong" type so long. Thanks everyone. Newbie mistake I guess.

Guest
This topic is now closed to further replies.


  • Posts

    • we all love you very much Guytis💖 🤗
    • W/e u smoke there, i want aswell... life has been cruel all this time! Maybe it will help me
    • I would like to take this opportunity to publicly apologize to the following people:   @Acacia, @Victory, @Splicho, @ShadowNetwork, @l2gold2025, @SkyLord, @maneco, @F4sh10n, @Maxtor, @Celestine, @911reg, @Nightw0lf. @UnknownSoldier   If at any point my words, actions, or posts offended you, I sincerely apologize. I recognize that in the past there were moments of tension and unnecessary conflict, but today I want to leave all of that behind. From now on, I choose not to hold any grudges against anyone and to let go of everything that happened — from both sides. The path I want to follow in this community is one of collaboration, mutual respect, and growth. Thank you to those who are still contributing and sharing. Sincerely,   Guytis
    • I found a dev , I will edit this post and start tomorrow as to build a 100 percent retail l2 Pride volos style like the old times   Features: Chronicle: Interlude  Xp:999 Sp:999 Adena:999 Start level : 80   Fast farming system : up to 3 hours for S grade equipment and up.to 5 days for later added 2 armor and weapon sets   Buff time 59mins all Full Npc buffer,  I will have buffers but with no heal close by for all areas  Reasonably priced Gm Shop, Gatekeeper, Free noblesse On death you dont lose sny materials and such except for very few if you P.k.   CP,hp,mp potion for 200 each   all players go from.No grade gear to S grade  with each different part of weapon , armor set,jewels,dyes,tattoos having different stats and such   Unique system of skills and little tweaks,     All classes of heroes have a fighting chance each with a different purpose and character..     All skills and deffus work for 70% chance of success and up  but for 4 to 7 sec each.   Many different areas of xp,sp and farm, 2 3 different farm pvp areas and all changing some. Days of the week, Also 2 party farm and pvp areas will be added.     All mini raid bosses and bosses have an hour respawn time.   As for special bosses  All have 1 hour almost  respawn time except for , Valakas and antharas with 3 hours.   And lastly  , 5 different events will be available for a good reward 5 times a day.  
    • Чтобы скачать файлы с сайта Akumu, вы можете использовать этот код на Node.js. Понадобятся два пакета: axios и cheerio.   это медленно, но делает свою работу   P.S. пропускает файл, если он присутствует и не изменен   const axios = require("axios"); const cheerio = require("cheerio"); const fs = require("fs/promises"); const path = require("path"); const BASE_URL = "http://akumu.ru/lineage2/L2NA/P746/"; const OUTPUT_DIR = "./downloaded"; async function delay(ms) { return new Promise((res) => setTimeout(res, ms)); } async function downloadFile(url, filepath) { // Skip download if file already exists and was not modified today try { const stat = await fs.stat(filepath); const mtime = stat.mtime; const today = new Date(); if ( mtime.getFullYear() === today.getFullYear() && mtime.getMonth() === today.getMonth() && mtime.getDate() === today.getDate() ) { // File was modified today, do not skip } else { console.log(`File exists, skipping: ${filepath}`); return false; // Indicate skipped } } catch (e) { // File does not exist, proceed to download } const writer = await fs.open(filepath, "w"); const response = await axios({ url, method: "GET", responseType: "stream" }); const totalLength = parseInt(response.headers['content-length'], 10); let downloadedLength = 0; let lastLogged = Date.now(); let lastDownloaded = 0; const lastModified = response.headers["last-modified"]; const mtime = lastModified ? new Date(lastModified) : new Date(); return new Promise((resolve, reject) => { const stream = writer.createWriteStream(); response.data.on('data', (chunk) => { downloadedLength += chunk.length; const now = Date.now(); if (now - lastLogged > 1000 || downloadedLength === totalLength) { const percent = totalLength ? ((downloadedLength / totalLength) * 100).toFixed(2) : 'N/A'; const speed = ((downloadedLength - lastDownloaded) / ((now - lastLogged) / 1000)) / 1024; // KB/s process.stdout.write(`\rDownloading ${path.basename(filepath)}: ${percent}% (${(downloadedLength/1024).toFixed(1)} KB/${totalLength ? (totalLength/1024).toFixed(1) : '?'} KB) ${(speed).toFixed(1)} KB/s `); lastLogged = now; lastDownloaded = downloadedLength; } }); response.data.pipe(stream); response.data.on("end", async () => { await writer.close(); process.stdout.write("\n"); // Set mtime and atime try { await fs.utimes(filepath, mtime, mtime); } catch (e) { console.warn( `Failed to set file timestamp for ${filepath}:`, e.message ); } resolve(true); // Indicate downloaded }); response.data.on("error", async (err) => { await writer.close(); reject(err); }); }); } async function crawlAndDownload(url, localPath) { console.log("Visiting:", url); // Ensure local path exists await fs.mkdir(localPath, { recursive: true }); const { data } = await axios.get(url); const $ = cheerio.load(data); const links = $("tbody a") .toArray() .map((el) => $(el).attr("href")) .filter((href) => href && href !== "../"); for (const href of links) { const fullUrl = new URL(href, url).href; const decodedHref = decodeURIComponent(href); const targetPath = path.join(localPath, decodedHref); if (href.endsWith("/")) { // It's a folder, recurse normally await crawlAndDownload(fullUrl, targetPath); } else { // It's a file, retry download indefinitely on failure while (true) { try { console.log("Downloading file:", fullUrl); const downloaded = await downloadFile(fullUrl, targetPath); if (downloaded) { await delay(1000); // Delay only if file was downloaded } break; // Success or skipped, exit retry loop } catch (err) { console.error( `Failed to download ${fullUrl}, retrying... Error: ${err.message}` ); // Optionally wait before retrying to be gentle on server await delay(3000); } } } } } crawlAndDownload(BASE_URL, OUTPUT_DIR) .then(() => console.log("Done!")) .catch((err) => console.error("Error:", err));
  • Topics

×
×
  • 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 Disabled AdBlock