Bletchley Park, 1942. A component from the Bombe machine, used to decode intercepted German messages, has gone missing. One of the cryptographers is waiting to be interviewed, under direst suspicion. Is he stupid enough to have attempted treason? Or is he clever enough to get away?
The Intercept is a small demo game written in ink and Unity that we built to demonstrate how to author a simple project. See how we like to structure our own ink files, and how easy it is to use the Unity plugin within a real game. We built The Intercept in a couple days for a game jam!
Download the game for Mac and Windows on our website
-
Clone the git repository. If you're unfamiliar with git, you may want to try using GitHub Desktop.
-
Open Unity and choose Open from the welcome dialog.
-
Find your repository's folder in the open dialog and choose Select Folder.
-
If you're presented with an Opening Project in Non-Matching Editor Installation dialog, no worries--just choose Continue:
-
After some time, you should see the Unity editor window. Locate the Project window at its bottom-left, expand the
Assetsfolder if necessary, and select theScenessubfolder inside it. Then double-click on theDemoscene that appears in the panel to the right of it:
-
Play the game in your editor by clicking the play icon at the top of your editor window (or press Ctrl+P on Windows, Cmd+P on Mac).
-
When you're finished playing, press the play icon again to stop the game.
Now that you've got the hang of playing the game in the editor, you might want to tinker with the story itself.
-
In the Project window, select the
Inksubfolder and click on theTheIntercepticon in the panel on the right. Then locate the Inspector window on the right side of the Unity editor and click the Open button:
Once you click Open, Unity will open the story's ink script in a text editor.
-
Around line 75 of the ink script, you'll see the game's familiar starting text:
They are keeping me waiting. Change this to something else, likeI am a hamburger:=== start === // Intro - - They are keeping me waiting. + - I am a hamburger. * Hut 14[]. The door was locked after I sat down. I don't even have a pen to do any work. There's a copy of the morning's intercept in my pocket, but staring at the jumbled letters will only drive me mad. I am not a machine, whatever they say about me.
-
Save the file and switch back to Unity. You may briefly see a terminal window open and close itself in an instant: this is just ink-Unity integration's Auto Compilation functionality at work.
-
Play the game in the editor again; the story should now open with the text "I am a hamburger."
Hooray! Now you know how to tinker with the story, but it will quickly become annoying to have to wait through the whole introduction and play through part of the game just to interact with the part of the story you've changed.
Notice that underneath the Open button in the Inspector window is another button labeled Play. If you click it, the Ink Player window will appear:
This is a really quick way to try out changes to your story without needing to re-play the actual game. It also gives you greater visibility into the state of your story, such as the values of its variables, which can aid in debugging.
Perhaps you've tinkered with your story, but now you'd like to try it out in-game, just to make sure everything looks and feels just right. But you don't want to have to sit through the introduction every single time you do this.
Fear not! The creators of The Intercept also had this concern, and they implemented a handy way to skip the introduction entirely.
-
Locate the Hierarchy window on the left side of the Unity editor. Click the entry called
Main. -
On the right side of the Unity editor, the Inspector window will contain information about the
Mainobject. Under theMain (Script)entry will be a checkbox titledSkip Intro:
Checking this and then playing the story will skip the introduction.
The Intercept and ink are released under the MIT license. Although we don't require attribution, we'd love to know if you decide to use ink a project! Let us know on Twitter or by email.
Newtonsoft's Json.NET is included, and also has the MIT License.
Copyright (c) 2016 inkle Ltd.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
