Author Topic: Source codes of FOnline Reloaded 2nd season (only server executable)  (Read 3031 times)

Offline Powerack

  • Administrátor na doživotí.
    • Powerackovo Doupě
Hello to everybody. I would like to start working on FOnline: Reloaded S2. I have a few ideas on how to make a little bit of it. For example, autostart server (no need manual start) when program runs and compression of saved positions would be appropriate. I would use zip compression. Just for example: unpacked save has 46 MB, packed 1.1MB. It seems to me unnecessary to store that amount of data. My server saves the game after 1 minute due to possible problems. In a day it makes about 5 GB of data, because not all the positions remain on the disk.

If possible, I would like to obtain the FonlineServer.exe (season 2 - version 0506-EC or newer) source code for adding the required features.
« Last Edit: January 06, 2019, 04:02:02 pm by Powerack »
I am working on private server at: fonline.powerack.cz.
Why I cant use image in signature?

Offline Wipe

  • Rotator
  • Random is god
Re: Source codes of FOnline Reloaded 2nd season (only server executable)
« Reply #1 on: January 07, 2019, 07:56:17 am »
autostart server
FOnlineServer -start

My server saves the game after 1 minute
It seems to me unnecessary to store that amount of data
HHHMMMMMMMMMMMMMM, i think i found a problem :P

Anyway, complete FOnline repo can be found here; just compare commits dates with old xp-dev repo until you find a match.

« Last Edit: January 07, 2019, 08:14:01 am by Wipe »
Games are meant to be created, not played...

Offline Powerack

  • Administrátor na doživotí.
    • Powerackovo Doupě
Re: Source codes of FOnline Reloaded 2nd season (only server executable)
« Reply #2 on: January 07, 2019, 08:17:13 pm »
I just wanted to point out that the position would be better to compress. These are data files with a large number of empty spaces. After archiving, the resulting values are up to 45x lower. I think developers could implement a zip library, for example. In any case, I will try.
I am working on private server at: fonline.powerack.cz.
Why I cant use image in signature?

Offline Wipe

  • Rotator
  • Random is god
Re: Source codes of FOnline Reloaded 2nd season (only server executable)
« Reply #3 on: January 07, 2019, 09:09:17 pm »
Well, good luck, just remember that worldsave size won't stay the same all the time.
As game grows (both in content and playerbase), so will worldsave; each and every time world is saved, engine will have to waste time on compression, while in reality you'll need only very small % of nicely compressed files - when you restart server. Just take notes how many files are created, and how many are actually used.

I'd rather work on external tool/script which takes care of compressing worldsaves once engine creates them; just making sure N most recent files are left as-is, so they can be loaded after restarts. Having tool/scripts is simply easier to maintain in the long run - if you ever decide to update engine, you'll still have desired functionality, without need for porting engine changes. Same if you decide to work with team which, for any reason, cannot implement your changes. As a side-bonus, it could be adjusted to work with any other application generating files constantly, not just FOnline server.

Just my two caps ;)
« Last Edit: January 07, 2019, 09:16:55 pm by Wipe »
Games are meant to be created, not played...

Re: Source codes of FOnline Reloaded 2nd season (only server executable)
« Reply #4 on: January 07, 2019, 10:42:27 pm »
Yeah, just make a script that runs periodically, compresses worldsave files then deletes them, or whatever else you need.

The only problem that remains is when you use SSD and large worldsaves (>100MB) being saved every minute can result in hundreds of GB of disk writes every day, then the drive would last only several months... the good news is that large SSD are cheap nowadays.