Skip to content

Writing Student Transfer Scenarios#

For Dummies and the not so programming proficient

Now filled with even more excruciating detail and the recommendation to probably go grab a snack before sitting down to read this.


This guide will describe (in the aforementioned excruciating detail) the process of creating a new scenario for the Scenario Mode of Student Transfer. It is a bit of a long read, but it will go over everything in detail to help you get going.

Getting up and Running#

First and foremost we need to obtain the game. You can do this by visiting the game entry on the TFGamesSite database and using one of the links there to download the most recent version of the game. Make sure to select the correct version for your operating system! This may take some time as the download has about the same footprint as our world's carbon emissions but don't worry, you'll get there eventually.

The downloaded file will be a .zip file (except for people on macOS, in which case it will be a .dmg), which means that it is a compressed archive and has to be extracted. If you are on Windows, do note that double-clicking this file may show you its contents rather than extracting it, and starting the game out of the archive file will cause errors and likely crash relatively quickly. Instead you should right-click on the downloaded file and select the Extract menu option, on Windows at least. macOS and Linux users will probably know how to do his already (no offense Windows people).

Tip

Use a program like 7-Zip for managing ZIP and RAR archives. People often use outdated versions of WinRAR, which might have problems with handling ZIP files similar to what Student Transfer is distributed as. If you have trouble extracting the game, try this program first.

After the extraction process is finished, a new folder will appear named StudentTransfer-X.X-Y(X depending on the game version and Y depending on your system, either linux, mac or pc). This is the object of our desire. Enter this folder and start the respective executable for your operating system. On Windows this file will end on .exe, while macOS peeps should use the one ending on .app. Linux users can start the game through the command line by running ./StudentTransfer.sh when cd'ed into this directory. On some distributions you may also be able to double-click it as well. If the game launches alright and does not explode, you're good. We're all set for the next part.

Game Structure#

Before starting on a new scenario, you should familiarize yourself at least roughly with the structure of the game as you will need to navigate it at one point or another.

Warning

On macOS the folder structure is slightly different than for the other platforms. If there is nothing but a .app file in the extracted folder, you will have to do some preparations first. To get you on the same page as Windows and Linux users, right-click on the StudenTransfer.app application and choose Show Package Contents. This will get you into the application files. Now enter the Contents/Resources/autorun folder. It is a bit of a dig, but at the end of this path you will be in the main folder of the game.

If you take a look at the files in the top level, you will see something akin to the following:

- game/
- lib/ (only on Windows and Linux)
- renpy/
- ... (other files)

The only folder relevant to us is the game/ folder. It contains all the data for the game, like music, images and the actual story files. Let's take a look:

- cache/
- images/
- python-packages/
- scenario/
- audio.rpa
- bg.rpa
- cg.rpa
- gui.rpa
- misc.rpa
- scripts.rpa
- ... (other files)

Right, this is a bit more interesting. First off, the files ending on .rpa are archive files, a bit like the one you've downloaded this game as, and they contain all the assets that you won't need to have direct access to. It is safe to ignore them for now. The cache/ folder is also not important, it contains temporary files that Ren'Py uses internally. For those of you blessed with an especially curious nature, you can take a look at the images/characters/ folder, where all the individual assets for our character sprites are stored. The scenario/ folder is what we're after. This is where all our work will be based in. If you enter it, you will find there are already some folders in there:

- example/
- stuck/

Info

With every version of Student Transfer we customarily ship a selection of hand-picked community scenarios, so what you see in this folder will differ somewhat between versions.

These are scenario packages. Each folder beneath the scenarios/ folder denotes an independent scenario, containing all the files necessary to run it. If we take a peek at the example scenario, we'll see something akin to this:

- assets/
- bg/
- characters/
- movies/
- music/
- sfx/
- story/
- scenario.yml

If you just want to start writing, then the story/ folder is where it's at. In it, you will find .rpy as well as .rpyc files. The good news is that you can ignore 50% of those, as the ones ending on .rpyc are, just like the aforementioned cache/ folder, mere helper files for Ren'Py internally. You can have as many files in there as you need for your scenario, so you can split it up into chunks for easier maintainability once it grows above a size feasible to put into a single file. The other two folders are for custom images, should you not be able to find what you're looking for in the ones provided by the game. How they work will be explained later on, in the section on using and adding custom images.


Last update: November 9, 2020