G33X Nexus Entertainment

G33X Nexus Entertainment => Precursors => Requiem for Innocence => Current Projects => Suggestions => Topic started by: Oceanus on December 28, 2005, 06:07:42 pm

Title: Auto Patching
Post by: Oceanus on December 28, 2005, 06:07:42 pm
Auto patching for precursors would be a good start. So we all download the first version and when we connect and you are ready to release a patch for the client we can just auto patch instead of hunting down the link for the newer version and having to reinstall and stuff.
Title: Re: Auto Patching
Post by: ryguy_1617 on December 28, 2005, 08:19:56 pm
yea, that would be a good idea, because we will eventually need that anyways.
Title: Re: Auto Patching
Post by: Neo on January 03, 2006, 09:55:06 am
Don't all games have that now?
Title: Re: Auto Patching
Post by: ryguy_1617 on January 03, 2006, 09:59:35 am
idk...but pretty much all the ones I've seen and played do.
Title: Re: Auto Patching
Post by: Oceanus on January 03, 2006, 05:02:18 pm
Its a must if you want easy access do your game and no hassle browsing the site for patches.
Title: Re: Auto Patching
Post by: Morgul on January 10, 2006, 07:23:12 pm
Good idea, however I have no clue how to do it. Mind looking up some programming references, or even some articles that explain the concept of how it's done? Don't worry about understanding most of it; I'm sure we'll be able to figure it out.

--Chris
Title: Re: Auto Patching
Post by: Caenus on January 10, 2006, 09:35:45 pm
It shouldn't be too hard to implement once we figure out the steps to take.
Title: Re: Auto Patching
Post by: PhinnFort on January 16, 2006, 04:00:10 pm
I have no real programming experience, but you would probably have to let the game's updater know which files are updated in each release. And then the game checks its version against the server, and if it's too old, it quits, and launches another program, which just updates what is needed.
And you must also remember that it should only update itself, not any of it's depencies, or it will probably not get into many distros (like Gentoo have a policy of not including any "auto-packages", which messes with other applications/libraries). But if you're only gonna distribute statically linked binaries, that won't be a problem, of course.

You could look into how PlaneShift does this, they have an (excellent?) updating system.
http://www.planeshift.it/

-PhinnFort
Title: Re: Auto Patching
Post by: Oceanus on January 16, 2006, 06:59:38 pm
I suggest automatically updating from an FTP
Title: Re: Auto Patching
Post by: PhinnFort on January 17, 2006, 05:09:42 am
rsync?

-PhinnFort
Title: Re: Auto Patching
Post by: Morgul on January 17, 2006, 11:37:53 am
rsync?

-PhinnFort

Gentoo User?
Title: Re: Auto Patching
Post by: Morgul on January 17, 2006, 11:46:39 am
(Yes, I'm double posting, but it's my forums, so bite me. :P)

We're currently planning the following:

1) When you connect to a server, it tells the game to send it the crc of all the game data files. Any that don't match get removed, and replaced. This handles updating of game data files.
2) When you connect to a server, it will get a version from the application, If that version is older than the server, it will download the updated client files, and tell the game "Exit and update". The game then prompts the user, and then starts an updater program, and exits. The updater will extract the new client files, overwriting all the others (keeping settings, of course) and then restart the game. The game will know that it ust updated, and will double check that the updater program itself doesn't have an update; if it does, it updates that too.

Now, I guess that it would be possible to take that updater, and allow it to connect to the server as a 'updating client', instead of a 'game client'. This would mean that if there's an update to the client program, we can have ti ust prompt the user, and ask them if they want to exit the game, and start the updater. The do that, and then the updater will download the update, install it, and then tell the game to overwrite itself (the updater tool) if there's an update.

I think this would work pretty well.
Title: Re: Auto Patching
Post by: Caenus on January 17, 2006, 01:29:15 pm
Sounds like a decent plan to me.
Title: Re: Auto Patching
Post by: ryguy_1617 on January 17, 2006, 03:48:22 pm
That sounds like it'll work.
Title: Re: Auto Patching
Post by: PhinnFort on January 17, 2006, 04:28:30 pm
I thought rsync did just what you mentioned in 1). So you can probably borrow some code there.
And for 2), how about the updater simply downloading an executable updater? You would of course need some hashes to make sure it doesn't get trojaned. That way you can make sure it gets updated even if the updater is broken/bugged.

-PhinnFort