[HELP] Change the IFID of a template


A more serious looking post, but also a necessary one.

 IFID CHANGE 

========What is an IFID?

An IFID is a serial number assigned to every work of Interactive Fiction, and works like and ISBN for books. It helps especially for archiving.

In Twine, every project is automatically assigned an IFID when a project is created. Not every other IF system does so.

========Why change an IFID?

TLDR: like books can't have the same ISBN, IF games shouldn't have the same IFID. 

If a project is uploaded on Twine but has the same IFID as one already in the library, Twine will ask you whether the new project should override the old one or stop the upload.

Since every of my templates and guides are created with the same IFID, it is important to assign a new IFID to the file before uploading it on Twine and edit it.
Similarly, other SugarCube templates available out there have their specific IFID. If multiple people edit a same template to make their own project, you will get multiple games with the same IFID.

========How to change an IFID?

===== In Twine
  1. Upload the template on Twine
  2. Create a New Project
  3. Copy Paste the code in the different passages + JavaScript + Stylesheet
  4. Remove template from library
  5. Edit your project

OR 

  1. Upload the template on Twine
  2. Select the Template (but don't open it)
  3. Click the Duplicate option (on the Menu bar at the top, or pre Twine 2.4, clicking the cog next to the title project)
  4. Edit your new project
===== HTML file
  1. Open the HTML file (.html) in a source-code editor (like NotePad or VSCode)
  2. CTRL/Cmd + F -> IFID or tw-storydata
    1. [You should find something like this:
      <tw-storydata name="Name of your Game" startnode="3" creator="Tweego" creator-version="2.1.1+81d1d71" ifid="C15CE33F-61F6-4909-BB59-73EE7A3D57B1" zoom="1" format="SugarCube" format-version="2.36.1" options="" hidden>
      ]
  3. Generate a new IFID here:  https://www.tads.org/ifidgen/ifidgen
  4. Replace the old IFID with the new one (Copy-Paste ontop of "C15CE33F-61F6-4909-BB59-73EE7A3D57B1")
    1.  [It should look like this:
      <tw-storydata name="Name of your Game" startnode="3" creator="Tweego" creator-version="2.1.1+81d1d71" ifid="THE NEW IFID PASTED HERE" zoom="1" format="SugarCube" format-version="2.36.1" options="" hidden>
       ]
  5. Save before closing
  6. Upload the file on Twine and edit it at will.
======= Twee file

If you have the latest version of Twine, you can upload Twee files like HTML ones.
So when the IFID is changed, you can simply upload it to Twine.
 ~ Do note: the Twee files do not include the JavaScript or CSS, as they are located in separate files (.js and .css respectively).

If you are using Tweego, just add the files in the src folder in the correct place, change the IFID, and continue editing at will!

  1. Open the Twee file (.tw) in a source-code editor (like NotePad or VSCode)
  2. Find the {StoryData} passage:
    1.  [It should look like this:
        {
           ifid": "C15CE33F-61F6-4909-BB59-73EE7A3D57B1",
           format": "SugarCube",
           format-version": "2.34.1",
           start": "Start"
        }
      [
  3. Generate a new IFID here:    https://www.tads.org/ifidgen/ifidgen
  4. Replace the old IFID with the new one (Copy-Paste ontop of "C15CE33F-61F6-4909-BB59-73EE7A3D57B1")
    1.  [It should look like this:
          {
               ifid": "THE NEW IFID PASTED HERE",
               format": "SugarCube",
               format-version": "2.34.1",
               start": "Start"
        }
      ]
  5. Save before closing

Get 100% Good Twine Sugarcube Templates

Comments

Log in with itch.io to leave a comment.

Typo

In the first part of the post:

"TLDR: like books can't have the same ISBN, IF games should have the same IFID."

the second part of the sentence (after the comma) should read: "IF games shouldn't have the same IFID."

I know, for people who know what IFIDs are it's obviously a simple typo, but someone encountering the term for the first time might be confused.

Good catch!
Thank you~ just fixed it.