Post Pacific

Post Pacific (https://postpacific.mmorpg-game.online/index.php)
-   L2C# General (https://postpacific.mmorpg-game.online/forumdisplay.php?f=48)
-   -   l2c# [dev] team (https://postpacific.mmorpg-game.online/showthread.php?t=3666)

Bacek 09.05.2006 09:16

Why do you think that is not possible to use geo from client files? IMHO it will be better to create small parser from client geo to use in L2C#, than fix and hex everything.. Better to star new, than try to fix a lot of mistakes..

/rus/ а почему нельзя использовать гео из клиентской части? помоему если написать нормальный парсер с нуля который создаст свой формат для L2C#, то отпадет большинство нестыковок и вообще помоему одно дело исправлять и совсем другое писать по новой уже без ошибок и с учетом всего! /rus/

Digital 09.05.2006 11:17

speed is the essence.
u have to understand y there's geodata in the first place
and what it is for...
ncsoft didnt make geodata out for fun ;)

Stormi 11.05.2006 13:15

Yup. Geo is the first MUST HAVE requirements for any new L2 server emu. The second MUST HAVE is OFF-like formulas, if you understand me - the one that I have no idea where to get... BTW, i do not think that any dev team will use any of existent file format. It is easyer to write converter than support NC files sometimes ;) And if you have sources you can hardcode a lot of stuff into the server, for example, it does not matter (for small team I mean) what to do - change AI in C# or in the pseudo-asm like NC did. It is just processor and nemory usage question.

Digital 11.05.2006 14:26

:S well... part right and wrong (imo)
l2 off geodata is probably the most efficient by far.
and that is if u really understand the structure of geodata

just to save ppl from repeated post i'll write a simple explaination as to y
1. client geodata is used to build the "world"
2. to let the server "use" the client geodata...
2.1 the server has to build the world using the client geodata first
2.2 then it has to regenerate all the movable axis and heights and layers, blah blah blah
2.3 then it'll have to compare it to the current mob location, player, etc, blah blah
2.4 multiply this by the number of 1k++ users and 4k++ mob u have.. hohoho

final sum = lag festival ;)

Hackfaq 11.05.2006 16:24

karioth, what client do you use to test your server?
Clean C4 Client From lineage2.com ?

Stormi 11.05.2006 17:12

Quote:

1. client geodata is used to build the "world"
With nice tool from HD it is just question of time
Quote:

2.1 the server has to build the world using the client geodata first
Sure. As you said format is efficient. Just use memory layout as in file - make big square (2d arrays), in each element make arrays of smaller squares and so on until you get 3D array of 8x8 plates with heights. This way will give you exact square where item located with few iterations. No huge cycles - less cpu usage and faster answer from server.
Quote:

2.2 then it has to regenerate all the movable axis and heights and layers, blah blah blah
Just make pointers between squares from NSEW bits? It will use at least 4 times more ram than file size but will significantly speed up path finding...
Quote:

2.3 then it'll have to compare it to the current mob location, player, etc, blah blah
Just having fast method to locate square where item located will make this compare fast, isnt it?
Quote:

2.4 multiply this by the number of 1k++ users and 4k++ mob u have.. hohoho
Heh.... Maybe you want to say 40K++ mob? I belive we have 4K+ classes but each class have at least 10 (just got this number from /dev/random) instanses in the word or i'm wrong? Who can tell how many creatures in the world server should support? I have no idea, just a lot... So 1K++ users is not a big problem :)
Quote:

final sum = lag festival
If NC did this, we also can... Or can not? :)

Digital 12.05.2006 02:35

jesus...
how fast would it be if u are to recompile the whole world using the client geodata then regenerate them into geodata before getting the correct position for the mob every time?

geodata is a pre-compiled version of the the processed client geodata.
after which it is loaded into memory during server loading.
thus the locating of the cell during runtime is efficient.

the example in the previous post is what might happen if they actually use client geodata directly.
unlike what i've explained above which is what ncsoft is doing.
of cause there's the pathnode.bin file as well for mob ai... but well..
that's another story of cause.

karioth 19.05.2006 19:28

Quote:

Originally Posted by Digital
l2 off geodata is probably the most efficient by far.

have you last geo from C4 off server?
but client has :)
this is the only and the most important reason to use client geo

as for efficient, Nikolas Virt said "Programs are algoritms and data structures".
so speed === geo representation in mem

karioth 19.05.2006 19:31

Quote:

Originally Posted by Hackfaq
karioth, what client do you use to test your server?
Clean C4 Client From lineage2.com ?

now all test code works with C3, protocol 560
i'll add protocol 656 soon

Digital 20.05.2006 11:08

yes the client has the file... and of cause we dun have the geodata,
but it could be made... just like l2j's datapack... everything could be made... teams could be formed, people could be found, even more people could contribute to the works, since this is just simple but tedious work.

but i'm debating logically, do u really want to compile and compute the geodata during runtime for every player, mob, npc, etc? (this is the case if u use client files)

and really, thank god u are still working on this project karioth ;)
hope to see some new working sources soon

karioth 22.05.2006 02:34

Quote:

Originally Posted by Digital
but i'm debating logically, do u really want to compile and compute the geodata during runtime for every player, mob, npc, etc? (this is the case if u use client files)

yes, in runtime, but only once during server loading

Quote:

Originally Posted by Digital
and really, thank god u are still working on this project karioth ;)
hope to see some new working sources soon

Thanks ;)

Digital 23.05.2006 03:39

hmm.. if that's the case...
it might be better off to write a external compiler instead?
to convert client files to geodata isnt it?
rather then making the loading time for server so much longer?

imagine the loading of geodata now? it's taking a pretty long time...
then imagine computing the geodata then loading? even longer isnt it?
then imagine when u are testing the server, and it'll require multiple times of restarting... u'll recompute geodata everytime? :O

these are some concerns i'd like to see addressed :p
since they'll have quite major impact...

karioth 30.06.2006 04:58

Quote:

now all test code works with C3, protocol 560
i'll add protocol 656 soon
I implemented protocol 660 from last C4 client,
code for 530-560 protocols was deleted

karioth 24.09.2006 05:49

I'm walking :)
 
Since last time post I have implemented many network packets...
I can now walk in La2 world. But geo is taking from client and server has no sync between clients (they cannot see each other).

http://l2cs.zakamsk.net

Digital 29.09.2006 06:05

yeah... in this case, all the synchronization are done on the server end

the client see and moves, but the movement packet is sent to the server
the server then calculates if it's possible/how to reach the selected position and validates it with the client
and at the same time, upon validation it'll broadcast it to all the other clients within a certain area/radius

same theory applies to the attack/spell/etc packets...

so the hard part here is to actually identify among who in the area to send to....
probably filtered by map then by a certain square grid size, like 4x4 grid from the client that activate it?

just some thoughts... and good work on the progress :)

karioth 05.10.2006 04:09

Quote:

Originally Posted by Digital (Post 68862)
yeah... in this case, all the synchronization are done on the server end

I understand that. Now I wanna take the maximum from C# and .net frmwrk. I wanna make server structure modular and have ability to replace or add modules (action, spell, quest, drop handlers and etc.) on the fly without server rebooting.
Server will be able itself to build C# module sources from some scripts (not from off server), compile it and add (or replace old) module handlers to global spell, drop, item, quest handlers.

Sindol 06.10.2006 21:43

This is the way I think most emulators should be handled now in regard to scripts. Some devs, like those of RunUO have been using a similar method forever, albiet only at run time. With reflection in .NET its easy to accomplish this to be handled on the fly, you can even set up a watcher thread that automagically rebuilds a compiled assembly when ever its code file is changed or you can go way out there, I had set a goal to allow classes to be added dynamically to my assembly via an in game text editor accessible by devs. My original goal was to use this feature for tracing and debugging, but there's nothing stoping a person from using a similar method to add dynamic content on the fly for events, ect ...

Quote:

Originally Posted by karioth (Post 69361)
I understand that. Now I wanna take the maximum from C# and .net frmwrk. I wanna make server structure modular and have ability to replace or add modules (action, spell, quest, drop handlers and etc.) on the fly without server rebooting.
Server will be able itself to build C# module sources from some scripts (not from off server), compile it and add (or replace old) module handlers to global spell, drop, item, quest handlers.


Rikimaru 07.10.2006 10:07

Yea altrough runuo dropped that kind of stuff, coz it was messing up thing with already created objects :)

Digital 21.10.2006 09:33

yeah, dynamic dll/script loading & unloading would be really useful.
and in c# it's really possible to get it done... there's already a couple of examples online which i've seen that does runtime compilation and execution...
if u get it working stable, it'd be a state of the art l2 server that even ncsoft would have troubles with.. lol ;)
GL!


All times are GMT. The time now is 15:43.