Jump to content

Discussion Fast load npc?


Recommended Posts

You need add the new param in INI file of NPC server.

 

L2NPC.ini
FastEnterWorld=true

This param allows load NPCs in few threads.

Edited by Rootware
Link to comment
Share on other sites

this work as it know in GF.

some ru devs create system and can load the npc in 15sec for interlude vanganth source.

also the offline shop restore after the server restart

Link to comment
Share on other sites

rewrite CNpcMakerDB::TimerExpired and have it load all npcs in 1 shot without any delay, something like

 

void CNpcMakerDB::TimerExpired(int timer_id) {
    while (this->ProcessOneNpcMaker()) { }
    while (this->ProcessOneNpcMakerEx()) { }
}

 

probably won't do it in 15 seconds but will be a hell of a lot faster than standard behavior and given that these funcs are almost certainly not thread-safe in the c4 l2npc.exe, rewriting the system to work how it does in GF+ isn't likely to be easy

Link to comment
Share on other sites

pretty sure the retail servers don't use fastenterworld, probably don't like flooding l2server with so many objects all at once, server has enough errors even on 100% retail files i'm sure they don't want to compound the issue, whereas priv servers don't give a shit and just want the npcs ig quick so people stop yelling in chat "pls gm where gk" "faul serwer xaxax"

 

16 hours ago, Anarchy said:

rewrite CNpcMakerDB::TimerExpired and have it load all npcs in 1 shot without any delay, something like

 

 


void CNpcMakerDB::TimerExpired(int timer_id) {
    while (this->ProcessOneNpcMaker()) { }
    while (this->ProcessOneNpcMakerEx()) { }
}

 

 

probably won't do it in 15 seconds but will be a hell of a lot faster than standard behavior and given that these funcs are almost certainly not thread-safe in the c4 l2npc.exe, rewriting the system to work how it does in GF+ isn't likely to be easy

 

surprisingly this code actually works, got bored and tested it today, so yeah, do that and you have fastenterworld-like behavior on c4-based l2npc.exe

Edited by Anarchy
Link to comment
Share on other sites

Take into account, that only L2NPC will load them at once, and send all 10000 packets to L2Server. But L2Server (at least C1) has 100 ms timeout for each NPC create packet, so you have also remove/reduce this on server side in order to show NPC

 

Link to comment
Share on other sites

On 2/20/2019 at 2:22 AM, Majestic12 said:

this work as it know in GF.

some ru devs create system and can load the npc in 15sec for interlude vanganth source.

also the offline shop restore after the server restart

Do you speak about new Ketrawars server? If yes, they don't use Vanganth anymore, they use our new Interlude extender based on GF core

Link to comment
Share on other sites

On 2/23/2019 at 8:39 AM, Anarchy said:

gf to interlude seems like way more effort than it's worth :D i did down to hellbound and that was bad enough xD

We succeed in that totally:) And Eglobal/Shock-world example, where is a custom work with HF client and Interlude mechanics, which we don't sell. Or January ketrawars server, where is a totally clear interlude implementation

Link to comment
Share on other sites

i don't doubt you've done it i just don't get why you would :D gf server is nice and all but only reason i used it for hellbound is to avoid the bullshit work of adding kamael race into c4 server, you go down to interlude i don't see the gain there over already existing c4-based exts you have, other than instances and the new clan system as native which doesn't seem worth the work - but that's just me and i'm a lazy fuck ¯\_(ツ)_/¯

Link to comment
Share on other sites

On 2/19/2019 at 10:00 PM, Anarchy said:

rewrite CNpcMakerDB::TimerExpired and have it load all npcs in 1 shot without any delay, something like

 

 


void CNpcMakerDB::TimerExpired(int timer_id) {
    while (this->ProcessOneNpcMaker()) { }
    while (this->ProcessOneNpcMakerEx()) { }
}

 

 

probably won't do it in 15 seconds but will be a hell of a lot faster than standard behavior and given that these funcs are almost certainly not thread-safe in the c4 l2npc.exe, rewriting the system to work how it does in GF+ isn't likely to be easy

 

How to apply in IL?

Link to comment
Share on other sites

  • 1 month later...
L2Server.exe

NPC Removing!!!  %d
NPC Removing DONE!!!
NPC Removing DONE!!!
NPC Removing DONE!!!

	g_HookManager.WriteMemoryBYTES(0x6F0A96, "79");	//Remove NPC Very Fast
	g_HookManager.WriteMemoryBYTES(0x6f0aaa, "01");	//Remove NPC Very Fast
	g_HookManager.WriteMemoryBYTES(0x6f1f74, "01");	//Remove NPC Very Fast





CEnterWorldSerializer::TimerExpired
06F1F73                 mov     edx, 0C8h	This is what MasterToma talks about   200mls

 

Link to comment
Share on other sites

  • 3 months later...
On 2/20/2019 at 2:21 PM, Anarchy said:

pretty sure the retail servers don't use fastenterworld, probably don't like flooding l2server with so many objects all at once, server has enough errors even on 100% retail files i'm sure they don't want to compound the issue, whereas priv servers don't give a shit and just want the npcs ig quick so people stop yelling in chat "pls gm where gk" "faul serwer xaxax"

 

 

surprisingly this code actually works, got bored and tested it today, so yeah, do that and you have fastenterworld-like behavior on c4-based l2npc.exe

hello, how to do it ? give us a help 

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