Development of Manasource and anything else related to the Mana Project.
#136475 by fatalfeel
Tue Jul 16, 2013 4:57 pm
as follows

1.have any update in Sourceoftales zip

2.and how to do in Manasource?


/////////////////////
I was afraid of that, because I've never done this myself. Maybe someone else can help you better in this regard. But what you have to do to my knowledge is:

-Put all game data used by your server (graphics, maps, sounds etc.) in zip files
-use a tool to calcutate the adler32 checksums of the zip files
-create a resource2.txt (or is this an xml by now?) which lists all the updates with their checksums
-upload the zip files and the resource file to your website
-change some conf settings of the server to point the clients to your website

You can open http://updates.themanaworld.org with a common webbrowser for an example.
#136476 by Ablu
Tue Jul 16, 2013 5:19 pm
If I understand this right you want to make clients connecting to your server automatically downloading the game content?

Note: If you only need this for local testing it is usually a lot easier to simply run the client with the -u -d path/to/world-data-directory (in your case the sourceoftales repo).

However if you want to allow autodownloading you need a few more steps.

First you need to zip the game data (one big zip is fine). The zip must not have any prefix (meaning that all the files are not inside a folder, but directly in the zip root.
Then you need to generate a adler32 hash of this. A small program which implements this hash algorithm is located in tools/adler32.c in the mana client repository. Note that this program is console only. If you are on windows it might be worth to try out this: http://hash.online-convert.com/adler32-generator
I did not test it, but it looks like a viable solution.

After you got your zip(s) and their hashs you create a resources.xml. See here for how to do it: http://doc.manasource.org/update_system
As a last step you need to make a news.txt. It does not matter what you put in there. It only has to exist (the client will display it in the update / download window.

Then you put the resources.xml, the zip(s) and the news.txt somewhere on a webserver / hosting (even stuff like dropbox works, it only needs to keep the names and the path prefix to all files must be identical). Then you must configure your server to tell the client to use that update host. You do that by setting the "net_defaultUpdateHost" setting in your manaserv.xml.

Then connecting clients should query the resources.xml, check if they need to download stuff, and download the missing zips.

NOTE: We have a script which makes creating the update zips and the resources.xml really easy. It is located here: https://github.com/tales/tales-tools/bl ... pdates.lua
However this script (without modifications), only will work for linux (except you have "git" and "adler32" available in $PATH on windows (though i think you would need to append .exe there? (I might be wrong here, I do not use windows))).

Regards,
Ablu
#136483 by fatalfeel
Tue Jul 16, 2013 10:16 pm
What a great answer like god's give!

you are my suinshine~~~~ thanks
http://www.youtube.com/watch?v=EZr2lYMI8q8

Ablu wrote:If I understand this right you want to make clients connecting to your server automatically downloading the game content?

Note: If you only need this for local testing it is usually a lot easier to simply run the client with the -u -d path/to/world-data-directory (in your case the sourceoftales repo).

However if you want to allow autodownloading you need a few more steps.

First you need to zip the game data (one big zip is fine). The zip must not have any prefix (meaning that all the files are not inside a folder, but directly in the zip root.
Then you need to generate a adler32 hash of this. A small program which implements this hash algorithm is located in tools/adler32.c in the mana client repository. Note that this program is console only. If you are on windows it might be worth to try out this: http://hash.online-convert.com/adler32-generator
I did not test it, but it looks like a viable solution.

After you got your zip(s) and their hashs you create a resources.xml. See here for how to do it: http://doc.manasource.org/update_system
As a last step you need to make a news.txt. It does not matter what you put in there. It only has to exist (the client will display it in the update / download window.

Then you put the resources.xml, the zip(s) and the news.txt somewhere on a webserver / hosting (even stuff like dropbox works, it only needs to keep the names and the path prefix to all files must be identical). Then you must configure your server to tell the client to use that update host. You do that by setting the "net_defaultUpdateHost" setting in your manaserv.xml.

Then connecting clients should query the resources.xml, check if they need to download stuff, and download the missing zips.

NOTE: We have a script which makes creating the update zips and the resources.xml really easy. It is located here: https://github.com/tales/tales-tools/bl ... pdates.lua
However this script (without modifications), only will work for linux (except you have "git" and "adler32" available in $PATH on windows (though i think you would need to append .exe there? (I might be wrong here, I do not use windows))).

Regards,
Ablu
#136489 by Ablu
Wed Jul 17, 2013 5:26 am
fatalfeel wrote:1. have any speciall spec? apache2 or some else

It does not matter. apache / httpd / any webserver works.
fatalfeel wrote:2. does tales have site like "http://updates.themanaworld.org" can be download

Yes of course. You download the data from there if you connect to our test server. The location is updates.manasource.org/
#136494 by fatalfeel
Wed Jul 17, 2013 6:47 pm
tks.

by the way~~ why client not update from account server

Account server also can support data and zip

1.why update from website?

2. http://updates.manasource.org/
You don't have permission to access
any way get it?



Ablu wrote:
fatalfeel wrote:1. have any speciall spec? apache2 or some else

It does not matter. apache / httpd / any webserver works.
fatalfeel wrote:2. does tales have site like "http://updates.themanaworld.org" can be download

Yes of course. You download the data from there if you connect to our test server. The location is updates.manasource.org/
#136496 by Ablu
Wed Jul 17, 2013 6:56 pm
fatalfeel wrote:by the way~~ why client not update from account server

Account server also can support data and zip

why update from website?


The updates are usually really big and downloads could take multiple minutes. The account server is not really designed to transfer that much data for that long.
Especially since the account-server is the entry point to the game we should try to keep its traffic as low as possible.

The way we currently do it we rely on existing and easy solutions and keep all flexibility (you could host your data in a super fast content delivery network optimised for static files for example).

Regards,
Ablu
#136499 by Jaxad0127
Wed Jul 17, 2013 6:57 pm
Pointing the client at a URL to get the data from means you can use more appropriate software to distribute the data (web or general file servers). You can also point the client at a CDN (content delivery network), which handles the details of getting the data to the clients efficiently.

The amount of data for a good sized world can get quite large. Letting a dedicated system handle that keeps everything fast and easy.
#136511 by fatalfeel
Thu Jul 18, 2013 3:26 am
ref http://code.google.com/p/mongoose/downloads/list

1. search all download find mongoose-2.8

2. here I build all sample in vs2008, download it
http://www.mediafire.com/?0k3vrk6tvz104v9

3.modify mongoose .conf port 8080 to 80
Attachments
222.PNG
222.PNG (104.17 KiB) Viewed 1960 times
111.PNG
111.PNG (152.47 KiB) Viewed 1960 times
Last edited by fatalfeel on Thu Jul 18, 2013 5:28 am, edited 1 time in total.
#136513 by Ablu
Thu Jul 18, 2013 5:17 am
This looks a lot like you try to use the TMW client data for manaserv?

I mean generally this is fine, the data itself would work. But there is no server which is compatible with this data and runs on manaserv. You mentioned Source of Tales a couple of times. If you run Source of Tales on your server you of course need to use a Source of Tales update for the client.

I am also not sure whether you hit a problem or simply wanted to tell us that it worked?

Regards,
Ablu
#136514 by fatalfeel
Thu Jul 18, 2013 5:26 am
just a test see if it works~~~

Ablu wrote:This looks a lot like you try to use the TMW client data for manaserv?

I mean generally this is fine, the data itself would work. But there is no server which is compatible with this data and runs on manaserv. You mentioned Source of Tales a couple of times. If you run Source of Tales on your server you of course need to use a Source of Tales update for the client.

I am also not sure whether you hit a problem or simply wanted to tell us that it worked?

Regards,
Ablu

Who is online

Users browsing this forum: No registered users and 1 guest