Page 1 of 1

[Help]About the Web Updater

Posted: Sun Feb 11, 2018 10:36 am
by klifton21sg
Hi, can anyone teach me how to use the Web Updater feature in RenPy? I have been reading through the documentation again and again and I'm still not 100% sure I get it.
I am intending to develop an episodic visual novel and I wish to use the Web Updater feature to update my game with the new episodes each time.
The part that I understand is that I need to purchase my own host server for my game, Things that I need guidance for are:

1) Where do I input this in Options.rpy (build.include_update to True) I am a complete noob when it comes to programming. I tried to input it somewhere in Options.rpy and I still don't see the Build Updates feature appearing in my launcher.
2) updater.update - What do I need to include in the parenthesis if I want to push down updates to include the next latest episode?

I hope RenPy Masters will be able to provide me some guidance, maybe show me a detailed example on how this feature actually works. I am working really hard in order to stop being a noob ^_^
Many thanks in advance!

Re: [Help]About the Web Updater

Posted: Sun Feb 11, 2018 3:32 pm
by Imperf3kt
Put all of these files on your server in its own folder somewhere:
updates.json
package.sums
package.update.gz
package.update.json
package.zsync

These will be found in the built files.
From there, add something like this to your main menu:

Code: Select all

## Updates via this button are for PC only
textbutton _("check for updates") action updater.Update("<my host>/renpy/game_name/updates.json")
Now whenever someone clicks that button a new screen called updater is called and the game checks for any updates you have uploaded.
According to the documentation:

Code: Select all

To customize the look of the updater, you may override the updater screen. The default screen is defined in common/00updater.rpy.

Re: [Help]About the Web Updater

Posted: Sun Feb 11, 2018 4:16 pm
by xavimat
I need to ask a question:
- Is there a reason why you want to do an "episodic" program?
I explain my question: You can plan an episodic VN in a single program, and develop bit by bit, letting the players to update it with all the episodes (already made) included. This, in the end, will be a simple program with a VN in episodes (so, with chapters, like most normal VNs), and the update thing is only provisional, while you are creating the VN. In this way, the users will download the entire program in every update. I suggest this option if your game is not huge. This is technically easier than the next option.
Another option is to create different parts of the program that will be downloaded separately. This would be recommended if every episode is huge, or maybe if you let the player to download only the episodes they want, and not necessarily all of them. This is a little trickier in the renpy side, because you have to define DLC in a couple of places (builds and some screen where the update will be applied), but it's perfectly doable.
- Do you know how many episodes do you plan to do? Or maybe you don't know and simply plan to add content in the future. I ask this because you'll need to plan, in the original game, some way to add content later. (I'm thinking in the screen with downloadable episodes; you need to put this screen in the original game and maybe you don't know how many "download" buttons you'll need to put., it's also doable, but implies some thinking, to avoid the need of updating the entire game with every new episode.

Re: [Help]About the Web Updater

Posted: Sun Feb 11, 2018 5:05 pm
by xavimat
Well, and some answers (sorry for double post) to your questions:

- First, there are also free hosting options, not only payed ones.

1) I include the line build.include_update = True at the start of the build options (before the "build.classify" part).
2) Imperf3kt's answer will download and update the entire game. It's the simple way. To have separated DLC you'll need to build them separately and create different updater.Update buttons to the same updates.json file but with the "add" parameter (the doc in this point is pretty minimal and not easy to understand, but we can guide you step by step once we know what exactly you need).

Also, the list of files Imperf3kt has listed will be longer, the updates.json file is the same, but you'll need four files for every system (4xWIN/4xMAC/4xLINUX or 4xPC/4xMAC). I prefer separated builds for win and linux, so I have 12 files for the updates.

Re: [Help]About the Web Updater

Posted: Mon Feb 12, 2018 2:27 am
by klifton21sg
Thanks guys! I am going to do some experimenting with the Web Updater based on your advice. The reason why I want to do an episodic VN is that the current one I am working on is quite large to do it in one go. I have a day job so I can only work on the VN a few hours a day. I plan to release 8 episodes, 2 episodes per release.
The current plan is to release the first 2 episodes by this year, then to continue working on the next episodes and release them when ready so on and so forth.
Right now, I am in the planning phase for my VN so I first need to understand if what I want to do (Episodic release via Web Updater) is doable before continuing further.