Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

Pirate King (Tales of Pirate) Server Files.

Status
Not open for further replies.
Newbie Spellweaver
Joined
Jan 26, 2008
Messages
58
Reaction score
3
i have managed to get the damn thing to work!!!
a couple of hours of hard softicing with groupserver and voila :)

attached is the screenshot


it required to insert some new columns into the db, since it was very uncomplete.
so wait for a complete guide, because it's 4:15am now and i really gotta get some sleep.

Awesome. I played around with it yesterday, too but only got as far as "GateServer discovered network abnormality" when trying to log in.

Btw. if you write your guide and I can get the server running on my machine, I'll probably spend a few hours coding a nice registration-page for new accounts in PHP. Should be easy - as far as I have seen, user-passwords seem to be md5-hashs.
 
Junior Spellweaver
Joined
Mar 9, 2007
Messages
111
Reaction score
0
Hm... I can't set up both gates servers, because there is a collision bewteen them, they both try to bind to port 1973, so what value should I use for the other?

And something to make account would be nice, even if I set up the server, I can't login in because I don't have an account! :')

BTW, Zukota, did you use Chinese client or english? OR are both possible?
 
Newbie Spellweaver
Joined
Mar 11, 2008
Messages
38
Reaction score
0
Download server files




Some theory first

-----------------

The server communication structure is shown on the picture. Digits are the port numbers servers are listening on, and arrows show the direction of connections.


terzo - Pirate King (Tales of Pirate) Server Files. - RaGEZONE Forums


Servers and their functions:
----------------------------
GroupServer: this baby plays the central role for the server operation. Disassembling of it revealed that it is responsible for authorizing the client, creating characters, map handling, etc. Think of it as the dispatcher and syncronizer between the Game and Gate Servers.

GameServer: it runs one or more maps. What is a map? A map is the part of the game world where your char can move without teleporting. If you are teleporting to another continent, you're changing maps. Maps are stored under the 'resource' directory of the server. See directory names there like 'garner', 'magicsea' and so on? Those are maps. Well, running even one map requires TONS of memory. Typically, running 'garner' map which in fact is Ascaron continent takes about 1GB of RAM on my machine. So, running all the continents and locations would require some serious hardware, I guess :) Or, maybe there exists some tweak for amount of RAM used, I don't know yet, since all the config files are in bloody chinese.

GateServer: this is some proxy between the client, GroupServer and GameServer. This is the only piece of software the client is communicating with. There can be more than one GateServer, but in this example we'll use only one.

AccountServer: pretty straightforward. Simply checks if a certain user can be authorized to login or not.


Databases:
----------

AccountServer: contains all the users allowed to login. Passwords are plain md5 hashes.

GameDB: main game DB. Contains all the chars, their stats, items, friends, guilds etc.


How to get this all to work:
----------------------------

In this example I'll show how to run just one map, 'garner', which is Ascaron. If you try to teleport to magicsea, it won't take you there, because this map is not running on the server. Well, you can try to run magicsea and deepblue maps on the same GameServer, but it will be a memory hog. You've been warned.

First of all, unpack the archive somewhere on your hardisk.

IMPORTAT NOTE: this archive doesn't contain some files under 'resource' folder that were present in the original archive because the filenames of them are in chinese and I wasn't able to extract those files from the original archive. But those files are necessary scripts for server operation and you should get them from the original archive somehow.

Restore the database backups to your MSSQL server. The backups are in DB folder of the archive. I won't go into the details, since operating MSSQL is beyond of the scope of this guide.

Having both databases restored, you should edit some config files. I'll show them here entirely, with the appropriate comments. You don't have to copy them from here. The archive already contains all the config files edited.


AccountServer.cfg
-----------------
Code:
[net]
listen_port = 1978          // the port AccountServer should listen on for GroupServer connection
listen_ip = 127.0.0.1       // the inerface AccountServer should listen on for GroupServer connection 

[db]
dbserver = (local)          // ip address of the MSSQL server running the AccountServer DB.
//                          // can be (local) which means 127.0.0.1 I suppose
db = AccountServer          // DB name
userid =
passwd =
//userid = account
//passwd = uCcnL+k0BUrE40Wr8VHg9A==
//passwd = cathy_way

[bill]
enable_bill = 0             // some kind of billing, not used for now
bill_server1 = 10.10.1.107
bill_server2 = 10.10.1.108

[tom]
enable_tom = 0              // not used now either

[gs]
GroupServerAndor = GroupServerAndor // looks like GroupServers are enumerated here
//                                  // we'll use only one for now
enable_ping = 0                     // dunno
GateServer.cfg
--------------
Code:
[Main]
Name = knight_gate01            // the name of the GateServer. not really important
Version = 133                   // the version of the server it should report to the client
//                              // 133 means 1.33, 102 means 1.02 and so on
                                  
[GroupServer]
IP = 127.0.0.1                  // ip address where GroupServer is running, in our case it's our local address
Port = 1975                     // port on which GroupServer is running
EnablePing = 180        // time interval to send KeepAlive packets to GroupServr

[ToClient]
IP = 0.0.0.0                    // interface GateServer should listen on for the client connection
Port = 1973                     // port number GateServer should listen on for the client connection
CommEncrypt = 1            // 
EnablePing = 60            // time interval to send KeepAlive packets to the client
Єм
 
Junior Spellweaver
Joined
Mar 9, 2007
Messages
111
Reaction score
0
Hm can you create a SQL file from the DB? The backups try to make a database with a size of multiple gigabytes, which might be a bit overkill ;)
 
Newbie Spellweaver
Joined
Mar 11, 2008
Messages
38
Reaction score
0
some corrections:
1. replace 'deepblue' with the 'darkblue' in the above guide :)
2. i figured out what exactly that
[ҐXҐН
 
Newbie Spellweaver
Joined
Mar 11, 2008
Messages
38
Reaction score
0
Sjikke could not find how to dump the DB to SQL in this stupid MSSQL 2K. Try to restore the database to a NTFS compressed folder.
 
Junior Spellweaver
Joined
Mar 9, 2007
Messages
111
Reaction score
0
Thanks, anyway. I'll connect my external HD, it has about 1,3 TB of free space :)

When I'm ready, I'll make an SQL of it, so other ppl don't have to waste their HD space.

About translating it, with that you mean the client right? That's gonna take some time yes.. But I can only start once I have it, my download times out from that FTP.

EDIT: SQL added in attachments.
 

Attachments

You must be registered for see attachments list
Banned
Banned
Joined
Sep 6, 2007
Messages
834
Reaction score
167
Thanks for the Guide, i'm at work, in my house i update first page with ur nice guide.
Thanks for ur help :)
 
Newbie Spellweaver
Joined
Jan 26, 2008
Messages
58
Reaction score
3
A little trick regarding all that bloody chinese in the config-files ;-)

What I did: I installed the East Asian Languages for windows. After that I loaded the cfg-Files into Word. When you load those files, an import-dialog is shown. there you can select "Simplified Chinese" and the config-file is shown in chinese. You simply copy everything into the online-translator from google and you'll end up with something like:

Code:
/ / Game Server configuration file 
/ / Please fill in all the necessary information to connect the Gate and the server is responsible for the operation of the map name 

[Folder ether] 
Name = GameServer01 / / server name, and not the other map server Chongming 
Equment = shouhushen 

[The important thinking has called Xian Min Rex ] 
Gate = 127.0.0.1, 1971 / / connect Naiyisi Gate server format for the ip address, port 
Gate = 127.0.0.1, 1972 / / connect Naiyisi Gate server format for the ip address, port 

[ melon  ] / / from one or more map 
Map = garner 
Map = eastgoaf 
Map = lonetower 

[Village Board of Juzhang Fu] / / designated data connectivity information 
Db_ip = 192.168.16.102 / / database server ip address 
Db_usr = game / / access to the database Account 
Db_pass EZCpyYOZVofugqDFBZrLKw == = / / access to the database password, the password is encrypted specialized tools after the results 

[Socket] 
Keep_alive = 120 

[ID of bladder] / / server distribution ID for the role of the base, each map server are different 
BaseID = 0x50000000 

[Turtles bang ofヘ] / / effects memory footprint 
Max_ply = 3000 / / number of players 
Max_cha = 15000 / / monster numbers 
Max_item = 30000 / / number of props 
Max_tnpc = 300 / / number of NPC dialogue 
/ / Max_cha = 5000 

[And Pin- Θ  dollars] 
Guild_num = 80 

[And Pin-  у Θ  dollars] 
Guild_try_num = 80 

[Fan ㄣ] 
Item_show_time = 60 / / props exist Time (sec) 
Item_prot_time = 30 / / props protection time (seconds) 

[Ding Ting Chi Advisory] 
Say_interval = 1 / / sec. 


[Qi    melon] 
Db_mapmask = 1 / / preservation of the large map 

[LOG Min Zuo] 
Log_cha = 0 
Log_cal = 0 
Log_ai = 0 
Log_mission = 0 

[Stover just   Min Zuo] / / debugging, non-GM orders 
Supercmd = 1 

[Ge sideヘ]] 
Res_dir = resource 

[Logヘ]] 
Log_dir = log \ log1

which still has some strange stuff in it but most of the time it gives you an idea what the settings are all about...

And if you look at the translated stuff, you'll see that this settings:

Code:
max_ply = 3000		// 玩家数目
max_cha = 15000		// 怪物数目
max_item = 30000	// 道具数目
max_tnpc = 300		// 对话NPC数目

seem to influence the amount of memory used... so playing with them could probably reduce the amount of memory needed...

Btw. I think I found the GM-commands in the gameserver.exe - look at it with a hex-editor and jump to the offset 1722676. You'll see a bunch of readable (english! :)) commands like "attr", "setcesslevel", "addcess", "addsailexp", "addexp", "addmoney" and stuff like that. attr is 100% a GM command (I've seen that on a chinese page - syntax is something like: attr 1,2 - but i don't know if it just alters your own stats or that of someone else) - so i guess that the other stuff is GM-related, too (at least it sounds plausible). I'll look into this when I have a running server...
 
Newbie Spellweaver
Joined
Jan 26, 2008
Messages
58
Reaction score
3
And btw. at least all *.bin files can easily be translated to english. All you have to do is taking the current versions from PKO or TOP, extract them and overwrite the chinese descriptions/itemnames with the english ones. I already wrote a parser for the bin-files (they are really simple - all records have a fixed size - so translating items/chars is just a matter of taking some bytes from file A and copy them to file B) - so I could provide a little PHP-script that copies the english strings to the chinese files. I don't think that we'll break anything because I doubt that any Item-IDs were changed (so I guess a Short Sword in V1.33 has the same ID as the short-sword in V1.35)
 
Junior Spellweaver
Joined
Mar 9, 2007
Messages
111
Reaction score
0
Why changing versions? I still got the english 1.33 client. I can't get to the Chinese one though.
 
Newbie Spellweaver
Joined
Mar 11, 2008
Messages
38
Reaction score
0
SnowCrash, cool to see you are working on this :)

And btw. at least all *.bin files can easily be translated to english. All you have to do is taking the current versions from PKO or TOP, extract them and overwrite the chinese descriptions/itemnames with the english ones. I already wrote a parser for the bin-files (they are really simple - all records have a fixed size - so translating items/chars is just a matter of taking some bytes from file A and copy them to file B) - so I could provide a little PHP-script that copies the english strings to the chinese files. I don't think that we'll break anything because I doubt that any Item-IDs were changed (so I guess a Short Sword in V1.33 has the same ID as the short-sword in V1.35)

Yes, but I believe there are also text ID strings also, and they are all in chinese. The clear example of this are birth points IDs, just look at resource\script\birth\birth_conf.lua. Great care must be taken when translating all these, and what is worse, things like that should be translated both for the client and the server.

So anyone got the server to work?
Feel free to contact me for any help.

And if someone already got the chinese client 1.33, could you upload it somewhere, because others seem to have trouble getting it?
 
Newbie Spellweaver
Joined
Jan 28, 2008
Messages
14
Reaction score
0
please!! someone can upload in sharefile (for example) or other site the cliente V1.33 , I can`t download from ftp site. Thank you very much! ..:: Yolaus ::..
 
Newbie Spellweaver
Joined
Mar 11, 2008
Messages
38
Reaction score
0
Network abnormality means that groupserver isn't running.

And md5 hashes should be in uppercase I believe.

BTW, trying to log in with english version won't take you farther than creating a pin code (where it locks up happily). Only chinese version works for me.
 
Junior Spellweaver
Joined
Mar 9, 2007
Messages
111
Reaction score
0
Indeed, they are uppercase, nice to know ;)

Now I can log in, I can set my pin, but then if I create my character and klick on the island I want to go to (Ascaron) it hangs... It's really weird, I don't see any errors in the log files or anything :S

And the Character Table is HUGE, it gives errors that the max row lenght is 8mb where the character table can be 32mb :|
 
Newbie Spellweaver
Joined
Mar 11, 2008
Messages
38
Reaction score
0
Well, you have recreated the DB from your SQL dumps, haven't you? Are you sure they are complete?
It doesn't give such errors with my DB backups.

Also did you edit GroupServer.cfg as described in the guide? Birth points, etc.

And finally are you using the same version of the client as me? One that I use has the file ver.rec with a game version hash (I believe) which is 8aab5dea594717ad0965ef7ee8627527
 
Newbie Spellweaver
Joined
Jan 26, 2008
Messages
58
Reaction score
3
Just another quick information...

If you get an error that the SQL-Query contains illegal characters when you start the GroupServer.exe, just hex the GroupServer.exe

Replace:

Code:
0006b1d0h: 45 54 44 41 54 45 28 29 29 20 65 6C 73 65 20 30 ; ETDATE()) else 0
0006b1e0h: 20 65 6E 64 20 20 BD E2 C9 A2 BF BC B2 EC C0 DB ;  end
 
Skilled Illusionist
Joined
Apr 6, 2006
Messages
336
Reaction score
111
The first one translates to: Investigation total dissolution of minutes

and the second: Dissolution of the remaining minutes inspection


AquaLung


.
 
Status
Not open for further replies.
Back
Top