Chapter releases

Nottravis

Sci-fi Smutress
Donor
Game Developer
Jun 3, 2017
5,132
27,280
Wonder if I can bother you chaps for a bit of help on something?

So the first chapter of my little game came out and, to my surprise, wasn't a disaster. So far so good. I'm now working on Chapter two of it and I've been looking at various solutions for an issue down the line in terms of file size. The game consists of ten chapters and each one is around (best guessed based on the compressed size of Chapter one) 600Mb.

Now, no way anyone can be expected to download a 6Gb game of course and I was just wondering, rather than me trying to do this from first principles, if anyone has any experience or views on multi chapter releases? The game is Renpy based.

Thanks for reading and any views gratefully taken.
 

Avaron1974

Resident Lesbian
Aug 22, 2018
25,860
89,143
I know some games compress their releases.

By that I mean they release barely any content but the downloads are manageable for those with 2 tins on a bit of shoe string internet.

Although I suppose you want a serious answer.

I have no idea.

You're welcome, any time :D
 

Nottravis

Sci-fi Smutress
Donor
Game Developer
Jun 3, 2017
5,132
27,280
I know some games compress their releases.

By that I mean they release barely any content but the downloads are manageable for those with 2 tins on a bit of shoe string internet.

Although I suppose you want a serious answer.

I have no idea.

You're welcome, any time :D
*laughs*

Well I did say any views gratefully taken, no? :)
 

HiEv

Member
Sep 1, 2017
384
785
I haven't checked out your game yet, so apologies if you're doing this already. That said, from what I've seen so far, it looks like you might not be.

So, if your story tends to take place in the same locations, what you can do is make background images (possibly in different day/night versions) and then overlay them with the characters using transparent backgrounds. Obviously that won't work in all cases, but this technique works fairly well for things like conversation scenes. This way you can make a couple of different poses and expressions, and then reuse them over various background images (possibly with a tweak to the character's hue, saturation, and luminance to match the location's lighting). That should greatly cut down, not only the file size, but the number of renders you need to do.

In fact, if you want to get really tricky, you could do the same poses in the different outfits you'll need, and then you'd just need to place the outfits over the (semi?)nude base-model. That would allow you to even further cut down on the file size, though the difficulty of doing this properly goes up a bit.

The down side is that for anything that needs transparency, you'll need to use a lossless format, like PNG. However, it should more than make up for the slightly larger file size by greatly reducing the number and complexity of images you'll need in the future.

Another down side is that this front-loads a lot of your work. You'll have to do a lot of backgrounds and poses at the beginning, but once you get that done you'll have a lot more time to do the sexy-time scenes and such in the later parts of development.

Also, you may find that your scenes are somewhat less dramatic. That said, most people who are used to visual novels will probably barely notice, as long as you throw in fully rendered scenes with the character "baked-in" to the image in the dramatic/important/sexy scenes and you have a sufficient variety of character expressions/poses that you semi-regularly change during the scenes where you're using the transparent overlaid characters. I noticed that you use a lot of close-up headshots for your images, presumably because this saves time with posing and backgrounds, however using this technique will give you a chance to show off the characters' bodies a bit more, since you only have to make a couple of really good poses which you can then reuse.

Final note, if you make the transparent overlay character images so that they're a bit under a third of a screen width (at their widest poses), then you make it easy to interact with up to three other characters at once this way.

Hope that helps! :)
 

Saki_Sliz

Well-Known Member
May 3, 2018
1,403
1,011
I tried your game, and wasn't sure what kind of review I wanted to give it yet, but I did notice the file size. I know quite a few ways to reduce the file size (which is mostly due to your amazing art work), but they either introduces compromises, or are advance techniques that will require you to rebuild your game. For now, if you can make each chapter it's own release, that may be the best compromise you can make other than having your game be massive.

The two main reason your file size could be as big as they are have to do with the images and how you use them. The first issue is the style of your game's art. Not that your style is wrong or bad, it's pretty good, but going for realism adds shading, when there is shading and noise in an image, .png compression, which is what I assume your images are, is a form of lossless compression, so as your image gets noisier or more realistic, the larger the files become to preserve the details. using jpg images usually doesn't change file size the more realistic the art gets, but it does add loss and artifacting. consider using gimp, open the images, and export as .jpg, before it exports you can adjust the quality, play around with that till you think you have good quality and good file sizes for each image. other than that this issue can not be avoided.

The other issue is how your game handles graphics. It looks like it just uses images mainly. As far as I can tell, for most of the images and scenes, you use one image for each unique moment. So say a girl turns her head, then that is a new image, same background, but the character is only slightly different. for each pose I assume you have a complete and unique picture. So when the background is the same, each picture have their own copy of the background. You can use tricks with game mechanics and rendering processes (plus some photoshopping) such that you can use a lot of smaller images that reuse parts of other images to minimize the data you need, but such tricks are considered advance techniques for non professional dev's and artist. I could teach you it, but if you want to preserve the same artistic quality of your game the amount of work to do so using these tricks will basically force you to completely rebuild the whole game, which I am guessing is not something you want to do. (and some of the tricks I have in mind, I am not confident that a renpy game could do them without direct control over how images are placed in the scene)

I see your game is a renpy game. Never used it myself (although I am quite tempted), so I don't know if you are allowed to run any custom code. If I were in your situation of file size issue, I'd do one of two things. Code my game such that you can export a save, and let users download each chapter independently, as they go along, in the next chapter they load the save. This is only really possible if your save files are processed by your own custom code and not by the engine's. Secondly, and something I am still playing with, I am trying to get my games to connect to a server, the server will control patreon content automatically and allow for on demand downloading as players progress.

Not sure if any of that really helps you out tho, since this looks to be your first game (although very well made for a first game and first release, such as the PDA tool I liked). Best of luck
 

Nottravis

Sci-fi Smutress
Donor
Game Developer
Jun 3, 2017
5,132
27,280
Gents, a lot to digest there for my little brain but -very- much obliged for both taking the time to give me such detailed responses and ideas.

I'll be honest. I'm a writer first, an artist second and a coder third so I'll need some time to digest this!

I'm loathe to compromise on the art tho, even if that could solve my problem. Largely as I don't think it's good enough as it is :)

Looks, at first glance, like the individual chapter route is the way to go. But I shall read fully and consider once I've had more coffee :)
 

OhWee

Forum Fanatic
Modder
Game Developer
Jun 17, 2017
5,882
29,892
So, it'll depend on what you mean by chapter releases.

If you are planning on doing each release as a standalone, yeah you can just build each chapter separately.

Fortunately, you are using Renpy, so there are ways to 'segregate' your content into chapters, applying patches to previous chapters to add later chapters.

Some people get intimidated by this, but once they've added a mod to a Renpy game the first time or two, it's a fairly straightforward process. You can go about this a couple of ways, but here's my suggestion for the moment:

Divide your game files into chapters (as an example, DMD likes to 'sort' it's pics by day) so you'd simply have an images/Chapter2 folder for chapter 2. Similarly, at the end of your chapter one script, you'd included a jump at the end of your last label script to a suitably named label in a new 'Chapter2.rpy' file (name it whatever you'd like), where for now you'd place a simple label that has your 'to be continued' graphic and a suitable end sequence for your game at that point in the Chapter2.rpy file.

Then just start your chapter 2 script in your version of the Chapter2.rpy file, and give it a similar treatment at the end (jump to label in a Chapter3.rpy file, to be continued). When you have Chapter 2 ready for release, you simply include your Chapter2.rpy file, and the associated images, in a separate .zip, which people will 'merge' with the Chapter 1 files they already have for your game. As a modder, I simply 'duplicate' the directory structure for my mods, and have people drag the /game folder of my mods into the main game folder of the game (so this merges /game with /game).

Note that you'll be overwriting the 'to be continued' Chapter2.rpy file with a new one when they merge the folders when installing the new chapter, and adding the 'to be continued' Chapter3.rpy file at the same time.

You can make installers that do this, so that people are less intimidated as well, but I'm not the guy to ask on that. I've never felt the need to make an installer.

If you have any references to pics from chapter 1 (backgrounds, menu icons, etc.), you simply call those as you've been doing before (in Chapter 1), referencing the appropriate images in Chapter 1. You usually don't have to mess much with screen structures, etc. if you are happy with what you did in Chapter 1, but of course you can simply 'overwrite' screens.rpy (or whatever) with an updated version for Chapter 2, if it's simply a 'quality of life' enhancement that isn't chapter specific. If the screen changes in some fashion, well, you'd simply call out 'HUDScreenCh2' (or some other suitable name for your purposes) in your screen call, to point the game to the updated screen, and of course dismiss the 'old' screen if it is currently being displayed. You can also use tags for this, giving a tag assignment to similar screens, so that only one screen with the same tag will display at a time, dismissing all other screens with the same tag.

This will also allow players to play chapters back to back in the same install, as they are released, and use the same saves throughout the game. Of course, later saves won't work with versions of the games without the relevant chapters, but if a player wanted to backtrack to a previous save from a previous chapter, that shouldn't be a problem, as long as the associated screen files and such are still 'relevant/haven't been drastically changed' (thinking HUD here).


Now, as to how to 'build' a patch through Renpy...


This explains how to build a patch, but you could use a similar approach to chapters.

So the net result of this is that your existing players can simply download the new chapter, and merge it with their existing install, as you release chapters, hence keeping your download sizes manageable for each chapter. Sure, they will still eventually be downloading everything (you mentioned 6 GB of content), but it'll be in small increments, hence not as painful. And, more importantly, they won't have to 're-download' the images from previous chapters over and over if they don't want to.

You can also build 'full' releases, combining all of your chapters so far, for players that haven't downloaded your game before. Sure, it'll be a bigger download, but it'll include all of the relevant chapters so far. That way, they don't have to mess with merging folders/using the installer the first time around. You'd still have the 'to be continued in next chapter' label and associated Renpy file at the end of the last 'current' chapter, so that they can pick up with patches from that point forward.

I'm sure others will have interesting suggestions along these lines too, but that's how I've seen a few games handle this now, and it works pretty well. You just need to fall into the pattern of setting up a new script.rpy for each chapter, so that the next chapter can simply overwrite that file when it is released.

Note that you can declare new variables, characters, and associated pictures at the start of the new chapter file (just put them in an init block), or declare them at the point when they are first assigned/used in the story.

One other note, if your script.rpy isn't set up to do this currently, well it's a pretty tiny file, so you can simply overwrite it when Chapter 2 is released, with the new 'chapter structure' at the end of said .rpy file. Renpy compiles all of your labels into a 'chronological' list, it doesn't matter which file it finds the labels in, it'll just add them to the list. So your existing labels can stay as is, it's just the last label that you'd be setting up the 'to be continued' jump to the first Chapter 2 label.

Hope this helps!
 

Saki_Sliz

Well-Known Member
May 3, 2018
1,403
1,011
Fortunately, you are using Renpy, so there are ways to 'segregate' your content into chapters, applying patches to previous chapters to add later chapters.
Very informative, thanks for sharing, I may have to look into this further if I decide to move to renpy myself
 
  • Like
Reactions: OhWee

Epadder

Programmer
Game Developer
Oct 25, 2016
568
1,064
After extracting the images from your game with Unren.bat, I used XnConvert to compress the files into WebP at 97% quality Method 6. This reduced the size of the image folder to 191 MB vs the original 794 MB, to my eyes the difference in quality is insignificant.

After looking over the images and the type of renders you are making, I'm not sure doing character 'sprites' like @HiEv suggests fits exactly.

I have a different suggestion, since there are a lot of shots where things remain the same. You can edit the renders afterwards in GIMP/Photoshop/etc and select the parts of the image that have changed and clear the rest. Then in Ren'py you can take the images and combine the 'base' image with the images that only contain the areas that change between renders.

You can use or to achieve this, it would be easier to do composite images I believe without needing to re-code the whole game.

So for every image that is only part of the image you would do:
Python:
image 1anniec3 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2b.png",
    )

image 1anniec4 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2c.png",
    )

image 1anniec5 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2d.png",
    )

image 1anniec6 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2e.png",
    )

image 1anniec7 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2f.png",
    )

image 1anniec8 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2g.png",
    )

image 1anniec10 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec9.png",
    (0,0), "annie1/1anniec9b.png",
    )

image 1anniec11 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec9.png",
    (0,0), "annie1/1anniec9c.png",
    )

image 1anniec12 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec9.png",
    (0,0), "annie1/1anniec9d.png",
    )
Now I combined this technique with compressing to 97% quality webp and the compressed and composited version is 2.77 MB vs the 25.8 MB original (compressed and not composited is 6.68 MB). I also was going fast to not have errors and copied a larger section than is probably necessary for the parts of the images that changed.

I'm going to include jpg versions which don't represent the quality, but just the concept of compositing images. The white space would not be present in webp files.
 

Nottravis

Sci-fi Smutress
Donor
Game Developer
Jun 3, 2017
5,132
27,280
So, it'll depend on what you mean by chapter releases.

If you are planning on doing each release as a standalone, yeah you can just build each chapter separately.

Fortunately, you are using Renpy, so there are ways to 'segregate' your content into chapters, applying patches to previous chapters to add later chapters.

Some people get intimidated by this, but once they've added a mod to a Renpy game the first time or two, it's a fairly straightforward process. You can go about this a couple of ways, but here's my suggestion for the moment:

Divide your game files into chapters (as an example, DMD likes to 'sort' it's pics by day) so you'd simply have an images/Chapter2 folder for chapter 2. Similarly, at the end of your chapter one script, you'd included a jump at the end of your last label script to a suitably named label in a new 'Chapter2.rpy' file (name it whatever you'd like), where for now you'd place a simple label that has your 'to be continued' graphic and a suitable end sequence for your game at that point in the Chapter2.rpy file.

Then just start your chapter 2 script in your version of the Chapter2.rpy file, and give it a similar treatment at the end (jump to label in a Chapter3.rpy file, to be continued). When you have Chapter 2 ready for release, you simply include your Chapter2.rpy file, and the associated images, in a separate .zip, which people will 'merge' with the Chapter 1 files they already have for your game. As a modder, I simply 'duplicate' the directory structure for my mods, and have people drag the /game folder of my mods into the main game folder of the game (so this merges /game with /game).

Note that you'll be overwriting the 'to be continued' Chapter2.rpy file with a new one when they merge the folders when installing the new chapter, and adding the 'to be continued' Chapter3.rpy file at the same time.

You can make installers that do this, so that people are less intimidated as well, but I'm not the guy to ask on that. I've never felt the need to make an installer.

If you have any references to pics from chapter 1 (backgrounds, menu icons, etc.), you simply call those as you've been doing before (in Chapter 1), referencing the appropriate images in Chapter 1. You usually don't have to mess much with screen structures, etc. if you are happy with what you did in Chapter 1, but of course you can simply 'overwrite' screens.rpy (or whatever) with an updated version for Chapter 2, if it's simply a 'quality of life' enhancement that isn't chapter specific. If the screen changes in some fashion, well, you'd simply call out 'HUDScreenCh2' (or some other suitable name for your purposes) in your screen call, to point the game to the updated screen, and of course dismiss the 'old' screen if it is currently being displayed. You can also use tags for this, giving a tag assignment to similar screens, so that only one screen with the same tag will display at a time, dismissing all other screens with the same tag.

This will also allow players to play chapters back to back in the same install, as they are released, and use the same saves throughout the game. Of course, later saves won't work with versions of the games without the relevant chapters, but if a player wanted to backtrack to a previous save from a previous chapter, that shouldn't be a problem, as long as the associated screen files and such are still 'relevant/haven't been drastically changed' (thinking HUD here).


Now, as to how to 'build' a patch through Renpy...


This explains how to build a patch, but you could use a similar approach to chapters.

So the net result of this is that your existing players can simply download the new chapter, and merge it with their existing install, as you release chapters, hence keeping your download sizes manageable for each chapter. Sure, they will still eventually be donwloading everything (you mentioned 6 GB of content), but it'll be in small increments, hence not as painful. And, more importantly, they won't have to 're-download' the images from previous chapters over and over if they don't want to.

You can also build 'full' releases, combining all of your chapters so far, for players that haven't downloaded your game before. Sure, it'll be a bigger download, but it'll include all of the relevant chapters so far. That way, they don't have to mess with merging folders/using the installer the first time around. You'd still have the 'to be continued in next chapter' label and associated Renpy file at the end of the last 'current' chapter, so that they can pick up with patches from that point forward.

I'm sure others will have interesting suggestions along these lines too, but that's how I've seen a few games handle this now, and it works pretty well. You just need to fall into the pattern of setting up a new script.rpy for each chapter, so that the next chapter can simply overwrite that file when it is released.

Note that you can declare new variables, characters, and associated pictures at the start of the new chapter file (just put them in an init block), or declare them at the point when they are first assigned/used in the story.

One other note, if your script.rpy isn't set up to do this currently, well it's a pretty tiny file, so you can simply overwrite it when Chapter 2 is released, with the new 'chapter structure' at the end of said .rpy file. Renpy compiles all of your labels into a 'chronological' list, it doesn't matter which file it finds the labels in, it'll just add them to the list. So your existing labels can stay as is, it's just the last label that you'd be setting up the 'to be continued' jump to the first Chapter 2 label.

Hope this helps!
Crickey....I'm so grateful you took the time out of your day for all that. Thank you.

This was sort of what I had in mind and the script layouts are subdivided in this type of format. I'll need to rejig some of the graphics folders to make it work properly going forward but that's no great hardship. Thank you! :)

And speaking of graphics...
After extracting the images from your game with Unren.bat, I used XnConvert to compress the files into WebP at 97% quality Method 6. This reduced the size of the image folder to 191 MB vs the original 794 MB, to my eyes the difference in quality is insignificant.

After looking over the images and the type of renders you are making, I'm not sure doing character 'sprites' like @HiEv suggests fits exactly.

I have a different suggestion, since there are a lot of shots where things remain the same. You can edit the renders afterwards in GIMP/Photoshop/etc and select the parts of the image that have changed and clear the rest. Then in Ren'py you can take the images and combine the 'base' image with the images that only contain the areas that change between renders.

You can use or to achieve this, it would be easier to do composite images I believe without needing to re-code the whole game.

So for every image that is only part of the image you would do:
Python:
image 1anniec3 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2b.png",
    )

image 1anniec4 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2c.png",
    )

image 1anniec5 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2d.png",
    )

image 1anniec6 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2e.png",
    )

image 1anniec7 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2f.png",
    )

image 1anniec8 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec2.png",
    (0,0), "annie1/1anniec2g.png",
    )

image 1anniec10 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec9.png",
    (0,0), "annie1/1anniec9b.png",
    )

image 1anniec11 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec9.png",
    (0,0), "annie1/1anniec9c.png",
    )

image 1anniec12 = Composite(
    (1920,1080),
    (0,0), "annie1/1anniec9.png",
    (0,0), "annie1/1anniec9d.png",
    )
Now I combined this technique with compressing to 97% quality webp and the compressed and composited version is 2.77 MB vs the 25.8 MB original (compressed and not composited is 6.68 MB). I also was going fast to not have errors and copied a larger section than is probably necessary for the parts of the images that changed.

I'm going to include jpg versions which don't represent the quality, but just the concept of compositing images. The white space would not be present in webp files.
Bloody hell that must have taken you an age to do. Thank you for going to so much effort on a stranger's behalf

Given that a number of my renders are very similar due to my preference for having "conversational" renders during chats the composite method would help hugely. I feel such a dunce for not thinking about that one.

But by crikey using the other conversion method makes a massive difference. I'd compressed them pre launch which halved it to its current size but this is something else entirely.

Thank you all -so- very much.

Given the combined suggestions have been such a benefit to me, would any of you object if I gave you all a credit in the next chapter? Seems the least I can do.

I'm hugely grateful to everyone in this thread for the assist.
 

OhWee

Forum Fanatic
Modder
Game Developer
Jun 17, 2017
5,882
29,892
Just a note.

If you go with something along the lines of my suggestion, you can leave Chapter One images right where they are now. Just start putting the Chapter 2 specific images in a new images subfolder titled Chapter_2 (with sub-sub folders for Chapter 2 inside that folder if you have those)...

This way you won't need to rework anything for Chapter 1. Except for the end of your existing script.rpy file of course (you'll need to move the 'to be continued' label to your Chapter2.rpy file). But of course, until you actually release Chapter 2, existing players can just use what you've released. They won't need the 'updated' script.rpy until Chapter 2's release.

Also, where is the banner for your game in your sig? I had to go to your Patreon to figure out the name of your game, then did a search here for the relevant thread. Advertising, Man!

Yeah, I get if you want to drive people to your Patreon, but a banner would still be nice, so that we know what game is yours, even if the banner itself doesn't link anywhere...
 
  • Like
Reactions: Nottravis

Nottravis

Sci-fi Smutress
Donor
Game Developer
Jun 3, 2017
5,132
27,280
Just a note.

If you go with something along the lines of my suggestion, you can leave Chapter One images right where they are now. Just start putting the Chapter 2 specific images in a new images subfolder titled Chapter_2 (with sub-sub folders for Chapter 2 inside that folder if you have those)...

This way you won't need to rework anything for Chapter 1. Except for the end of your existing script.rpy file of course (you'll need to move the 'to be continued' label to your Chapter2.rpy file). But of course, until you actually release Chapter 2, existing players can just use what you've released. They won't need the 'updated' script.rpy until Chapter 2's release.

Also, where is the banner for your game in your sig? I had to go to your Patreon to figure out the name of your game, then did a search here for the relevant thread. Advertising, Man!

Yeah, I get if you want to drive people to your Patreon, but a banner would still be nice, so that we know what game is yours, even if the banner itself doesn't link anywhere...
Thanks :)

And a banner...of course! Did I ever mention I'm a bit of a ditz? Thank you - again!
 
  • Like
Reactions: OhWee

79flavors

Well-Known Member
Respected User
Jun 14, 2018
1,607
2,256
The obvious feedback to image sizes is some sort of compression. I was going to add some links here, but I think everything you need is probably already included in the thread you started just before Xmas.

Whilst not everyone is going to want to play a non-consent game, clocks in as a 82meg download. When uncompressed, that's about 200+ 720p .jpeg images, totaling only 29meg for two chapters. Plus an additional 6 animations at only 4meg.
It shows that small image sizes don't automatically mean low quality images and bad color saturation.

Though another aspect of that game, which might reduce the size of your own game is the ratio of dialogue to images. Sometimes it's fine to leave a single picture on the screen while something is happening. Sometimes it's okay to swap back to an image you've already used before, if that makes sense... like two people having a to-and-fro conversation or the mc returning back to a place/situation they've been in.

The rest of the thread has gone off a bit talking about how to manage chapters in a multi release schedule. How to organize folders and name files to make life a little more predictable.

On that front... I'd like to add a bit of code I used in my patched version of Sister, Sister, Sister.
Whilst the original code was a single script.rpy file... I broke each chapter into individual chapterxx.rpy files.
I adopted a standard where each chapter started with a "label chapterxx_start:" statement and ended with a "label endof_chapterxx:" statement.
After the "endof_..." label, I had a bit of code that could check if the next chapter was available yet and go to the most relevant place.
It looks something like this...

Python:
# this is taken from chapter14.rpy

label chapter14_start:

    scene [...] blah, blah, blah.
    [....]
    jump endof_chapter14

# lots of other code, obviously. But finally...

label endof_chapter14:

    if renpy.has_label("chapter15_start"):
        jump chapter15_start
    else:
        jump thank_you_for_playing

# the end
So each time it reached the end of a chapter, if the next chapter exists (by nature of the right label existing)... it went there and carried on. If it didn't exist... then it jumped to the "Thanks for playing! Visit Patreon... blah, blah, blah".
I had a bit of code that figured out what the current chapter number was and added +1 to it so it would always say "See you in Chapter xx+1!" without me needing to alter that too.
The final chapter doesn't need this code. It just displays a final "Thanks for playing!" type image, without any of the extras.

The big advantage is that you don't need to go back to alter chapter14.rpy when you release chapter15.rpy.
 
  • Like
Reactions: Nottravis

FranceToast

Active Member
Donor
Jul 31, 2018
562
896
After looking over the images and the type of renders you are making, I'm not sure doing character 'sprites' like @HiEv suggests fits exactly.

I have a different suggestion, since there are a lot of shots where things remain the same. You can edit the renders afterwards in GIMP/Photoshop/etc and select the parts of the image that have changed and clear the rest. Then in Ren'py you can take the images and combine the 'base' image with the images that only contain the areas that change between renders.

You can use or to achieve this, it would be easier to do composite images I believe without needing to re-code the whole game.
This seems like a lovely compromise that allows for both integrated character/background rendering (something I like) with some of the savings of the sprite approach (something I'll probably need, LOL.) Thanks!
 
  • Like
Reactions: Nottravis

Nottravis

Sci-fi Smutress
Donor
Game Developer
Jun 3, 2017
5,132
27,280
The obvious feedback to image sizes is some sort of compression. I was going to add some links here, but I think everything you need is probably already included in the thread you started just before Xmas.

Whilst not everyone is going to want to play a non-consent game, clocks in as a 82meg download. When uncompressed, that's about 200+ 720p .jpeg images, totaling only 29meg for two chapters. Plus an additional 6 animations at only 4meg.
It shows that small image sizes don't automatically mean low quality images and bad color saturation.

Though another aspect of that game, which might reduce the size of your own game is the ratio of dialogue to images. Sometimes it's fine to leave a single picture on the screen while something is happening. Sometimes it's okay to swap back to an image you've already used before, if that makes sense... like two people having a to-and-fro conversation or the mc returning back to a place/situation they've been in.

The rest of the thread has gone off a bit talking about how to manage chapters in a multi release schedule. How to organize folders and name files to make life a little more predictable.

On that front... I'd like to add a bit of code I used in my patched version of Sister, Sister, Sister.
Whilst the original code was a single script.rpy file... I broke each chapter into individual chapterxx.rpy files.
I adopted a standard where each chapter started with a "label chapterxx_start:" statement and ended with a "label endof_chapterxx:" statement.
After the "endof_..." label, I had a bit of code that could check if the next chapter was available yet and go to the most relevant place.
It looks something like this...

Python:
# this is taken from chapter14.rpy

label chapter14_start:

    scene [...] blah, blah, blah.
    [....]
    jump endof_chapter14

# lots of other code, obviously. But finally...

label endof_chapter14:

    if renpy.has_label("chapter15_start"):
        jump chapter15_start
    else:
        jump thank_you_for_playing

# the end
So each time it reached the end of a chapter, if the next chapter exists (by nature of the right label existing)... it went there and carried on. If it didn't exist... then it jumped to the "Thanks for playing! Visit Patreon... blah, blah, blah".
I had a bit of code that figured out what the current chapter number was and added +1 to it so it would always say "See you in Chapter xx+1!" without me needing to alter that too.
The final chapter doesn't need this code. It just displays a final "Thanks for playing!" type image, without any of the extras.

The big advantage is that your don't need to go back to alter chapter14.rpy when you release chapter15.rpy.
Thank you -so- much. I love the coding solution.

Also I suspect your right 're the number of images for conversations. Some of the players made the same comment!

But that code is perfect. Together with the other suggestions here I should be able to reduce the size and do individual chapter releases more easily than I expected.

You've all saved me a ton of time which I'm hugely grateful for as I'd much rather be using it to write more content than renpy wrestle.

Thank you!
 

Epadder

Programmer
Game Developer
Oct 25, 2016
568
1,064
Bloody hell that must have taken you an age to do. Thank you for going to so much effort on a stranger's behalf

Given that a number of my renders are very similar due to my preference for having "conversational" renders during chats the composite method would help hugely. I feel such a dunce for not thinking about that one.

But by crikey using the other conversion method makes a massive difference. I'd compressed them pre launch which halved it to its current size but this is something else entirely.
No problem, it wasn't too bad... I couldn't get to sleep last night so it was something to do as a distraction :D.

Yeah so what I've noticed is that lossless webp is smaller than the raw PNG, but it isn't a miracle worker. There are programs that 'crush' PNG images to try and optimize them so that you get the best possible quality, but the more detailed the image the less effect trying to optimize the image has. By using the lossy compression method at a high quality instead, you can get more space savings with a lot less work :).

This seems like a lovely compromise that allows for both integrated character/background rendering (something I like) with some of the savings of the sprite approach (something I'll probably need, LOL.) Thanks!
I will say the compositing technique is one that I have just observed being used by quite a few Japanese VN developers over the years.

When trying to make these things ourselves it's a great idea to try and learn from the people who have been doing it for far longer :D.
 
  • Like
Reactions: Nottravis