Publishing Your Game - ThePix/QuestJS GitHub Wiki

Uploading was briefly covered in the tutorial, but is worth expanding on.

There are two sides to this:

  • the technical issue of how to get your game on a web site
  • the recommended procedure to give a quality game

With regards to the second, before you even think about releasing your game, you need to thoroughly check to make sure it works properly, and that it has sensible responses for things that a player might reasonably type while playing it. To create a good game is a lot of hard work, and while it might be tempting to release your first efforts after a minimal amount of testing, your players won’t thank you for it. It will get poor reviews, and less people will want to try it out.

There is a list of pre-release checks here.

Beta-testing is discussed here, and is vital. For a sizeable game, you should be looking at getting a dozen people to beta-test, if you can.

Uploading

If you have renamed the game folder, you will probably need to rename it to "game" in your upload (more here).

Prepare a ZIP file for TextAdventures.co.uk, IFComp, Itch.io or Borogrove.io

All four sites offer hosting for free. For IFComp you will need to enter the competition, of course.

These all require a ZIP file, and the same file can be used for all. You will also need an account on the site.

How you create a ZIP file depends on your operating system and software. If you are using Windows, I recommend 7Zip, which is free and open source. There are versions for Mac and Linux, but it looks like they are unofficial, and I cannot comment on them, having never used them. You might also want to look at FreeArc for Linux or iZip for Mac.

7Zip will add extra options to the context menu in Windows Explorer, making it easier. The process for 7Zip on Windows is:

  • Check settings.playMode in settings.js is right - "beta" if this is for beta-testing, "play" for release (more below); update the version number in settings.js; save the file
  • In Windows Explorer, go to the QuestJS folder
  • Select index.html and the relevant folders: lib, lang and assets, as well as your game folder (hold the Ctrl down while clicking to select multiple folders)
  • Right click one of them, and go to 7Zip - Add to archive...
  • Give a suitable name, check the format is "zip", and click Okay
  • If your game folder is not called "game", right click your new .zip file, and go to 7Zip - Open archive. Right click on the game folder, select Rename, and change the name to "game".
  • Optionally, you could remove unwanted files; right click your new .zip file, and go to 7Zip - Open archive, then delete the files you are sure you are not using.

Upload to TextAdventures.co.uk

On the Text Adventurers web site, log in, then click on Create at the top, then Upload game below that. Then just follow the instructions. You should upload you game as "Unlisted" until you have completed beta-testing. You might want to upload a cover image too.

Upload to IFComp

On the Ifcomp.org web site, log in, then click on Participate at the top, then Register and manage your entries below that. I would advise using the "preview" facility to make sure the upload was successful (no files missing).

Upload to Itch.io

Itch.io offers the opportunity to make money from your game. That said, do not expect to make a fortune from interactive fiction!

On the Itch.io web site, log in, then go to the Creator Dashboard, then click on Create new project. Then just follow the instructions. The default viewpoint is pretty small, you might want to try 900 by 700, and see how that looks. There are a lot of options to think about, but they can all be edited latter.

Itch.io (wisely) forces you to publish unlisted at first. Once you have it set up right, publish it publicly.

Upload to Borogrove.io

Borogrove.io is a site that specialises in interactive fiction, so may be a better fit than Itch.io.

On the Borogrove.io web site, log in (requires a Google account), then go to Upload, and just drag the .ZIP file into the box. The "autodetect" option should be fine, but if not, select "HTML". I have yet to try this, and there may be further steps, but I would expect them to just involve telling the site about your game - what tags to use, etc. - and uploading a cover image.

Uploading to Your Own Website

If you want to host the game on your own site, you should upload the game files directly, rather than in a ZIP file. You need to ensure they end up in the correct folders.

You will presumably already have a way to upload web pages (FileZilla and WinSCP are popular tools). The best way to proceed is to create a new folder named after your game (I suggest all lowercase, no spaces or special characters). Then simply upload index.html, together with the folders, to that location.

  • index.html
  • lib folder
  • lang folder
  • assets folder
  • your game folder (rename to "game" after upload if necessary)

Some web site platforms are designed such that the author edits the pages directly (this web site is an example). That makes things a little more difficult, but it should nevertheless have a way to upload media and it should be possible to upload your game using that. You may encounter two issues. The first it that it might consider JavaScript files a security risk, and just not allow them. If that is the case, the best you can do is find another platform, unfortunately.

The other issue is that you need to be able to use folders. How that works will depend on the platform. For example, in WordPress, media by default gets put in a folder depending on the month it is uploaded. That is not going to work! It does, however, have a "Media Library Folders" extension that gives the author full control.

Whatever system you are using, you need to upload the index.html page first, then upload the other folders into the same place, making sure that you end up with index.html and all the other uploaded folders in the same folder on the server. You should check the contents of each game folder to ensure the platform has not tried to do something "clever" and extract its contents.

A "Flat" upload...

If you have no option to put files within folders, you will need to do a "flat" upload, i.e., put everything into a single folder.

I suggest creating a new folder on your computer, and assembling everything there. Copy across the files from the relevant folders, "lib", "lang", "assets/css" and your game folder, as well any other files, such as icons, images, etc.

You will need to set the relevant folders to an empty string in settings.js.

  settings.imagesFolder = '',
  settings.iconsFolder = '',
  settings.soundsFolder = '',
  settings.videosFolder = '',
  settings.cssFolder = '',

You will also need to edit index.html so the other files can be found. Open the file up, and replace lines 18 to 26 with these lines:

  <script src="_util.js"></script>
  <script src="_settings.js"></script>
  <script>
    document.writeln('<script src="settings.js"></scr' + "ipt>"); 
  </script>
  <script>
    settings.writeScript()
  </script>

Open up the index.html file in your new folder in a browser, and check it still works and images, etc. are still in your game.

It might also be worth checking there are no files with the same names already on your web site. The problem one is likely to be index.html, as this is the standard default file for a web site. You can, however, rename the Quest 6 file to anything you like (as long as it ends .html). Just remember to use that file name for the web address.

If all is well, you can upload the files.

Your game's address

You then need to work out the URL (web address) of the index.html file, so players can find it! In WordPress, it will tell you the link. If you are using FTP, it will end in the folder name, followed by "/index.html".

Files and folders not required

Optionally, you may want to delete files from the folders you are not using. This will make you game smaller - though not by much, so arguably not worth the bother. Where it may be significant is the images, videos and sounds folder, if there are files in there you are sure are not used.

You can delete any language files you are not using from the "lang" folder, and any library file not used from "lib" (any starting with an underscore are required, as are any you have included with settings.libraries.push in your settings.js file).

Do not delete assets/icons/favicon.png; this is used by the browser - but feel free to use your own icon.

Publishing

Public upload

Once all the bugs are sorted, upload your game again, just as before. Check the game listing text is fine, and set who can access the game to everyone (if on TextAdventures). Congratulations, your game is now live!

Announcement

Now all you have to do is tell people about it, so they will play it.

You can announce your game on:

Notes

Size Limitations

The TextAdventures web site has a 20 Mb upload limit; for Itch.io it is 1 Gb. This is the size of the ZIP file, and in terms of game, that is a huge amount, and you will be doing well to build a game that is even 1 Mb (the tutorial game is 0.16 Mb and my entry for IFComp 2021 is 0.24 Mb). However, images, videos and sounds can seriously inflate the file size.

If you are uploading to your own web site that limitation does not apply, but it may still be worth reducing file sizes anyway, as it will make downloads faster.

You can reduce the size of your game by:

  • Removing files that are not used
  • Use smaller or lower quality images, videos and sound clips (I have heard Pixillion Image Converter and Switch Sound Converter are useful here)
  • Host larger video/image/sound files on another web site (you will need to modify the Content Security Policy in the index.html file to allow this)

Cover Image

The Text Adventures web site allows you to add an image to your file listing. In Quest 5 you can add that to your game, in Quest 6 you need to upload it separately. Go to your game listing, click "Edit Image", then upload the file.

I think somewhere there is a recommendation that the image is 512 by 512 pixels, however the front page will stretch and squeeze it to fit the page, so it does not matter that much.

IFID

To get listed on IFDB, your game needs an IFID; a unique identifying number. To get one, just go to this page. I suggest you copy it into your setting.js file, like this (though currently it will not make any difference if you do not):

settings.ifid = 'FFFBBB6B-E49E-4E76-B77C-C0D906C1E543'

Updates

Remember to update the version. Apart from anything else, this allows you to test the upload worked, just by going into the game and typing ABOUT.

Also remember to set the play mode as appropriate.

The textaventures.co.uk web site can be slow to update your game. When you first upload it, it is there immediately, but when you upload an update it can take an hour or so before it takes effective (I would guess games are cached somewhere). You just have to be patient! Using a different file name seems to help. It also seems to forget your cover image when you update, so remember to add that each time.

Capitals in file names

Some operating systems are case sensitive (Linux?) and some are not (such as Windows). If you develop your game on Windows, and then upload it to a server with a case sensitive file system, you may find files are not getting loaded because there is a capital in the name but not in the settings where you specify it or vice versa.

I would therefore recommend keeping everything in lower case.

Be aware that windows might give a file a capitalised extension, but hide the fact from you. Do check the extension as well.

⚠️ **GitHub.com Fallback** ⚠️