Posts tagged game dev
GDC 2018 wrap-up

By Jon Manning (@desplesda), co-founder of Secret Lab.

Alec Holowka accepting the Seumas McNally Grand Prize for Night in the Woods at the 2018 Independent Games Festival.

So, I’m back from GDC 2018.

We’ve been going to GDC for 9 years now. If we go next year, I’ll have been wandering in and out of the Moscone Centre for a decade.

We started going to GDC because we were living in California, and happened to have the spare resources and time to attend it. We were always attending from the viewpoint that it would be useful to have an idea of what the game dev community is like, and to try to do the thing that business types call “networking” and regular humans call “making friends”. We didn’t realise they were the same thing until our fifth year of going.

Like many attendees at GDC, we were going aspirationally. While we’ve always been game developers—our first ever release was a tiny little competitive puzzler called Culture, in 2008—we never felt like we were part of the larger conversation, and I’m pretty sure that that feeling I shared with most people I see who aren’t frequently seen in groups in the halls.

I don’t have any advice here for people who want to change that for themselves. All I have is that, around the time we started working on Night in the Woods, I had a group of friends who all work in the same field and never see each other except at international gatherings like GDC. While not all of these people are team members on the game we worked on, having a thing that serves as the anchor for a group that we’re part of made my experience significantly less lonely, and a lot more focused.

This is the second GDC that I’ve given a talk at. This year, I talked about Grabthar’s Hammer, the compression technique that we built for the iOS version of Night in the Woods. People liked the talk! I had a number of people with questions afterwards, and I think I answered them pretty well. They’ll have ended up on the recording. I’ll probably end up cringing hugely when I review the video. Worth it.

This is the first GDC in which a game we worked on was up for awards at either the Independent Games Festival or the Game Developers Choice Awards. Night in the Woods was up for three awards in each. People like the game, I think. That’s nice.

Night in the Woods won two awards, both of them in the Independent Games Festival. We won Excellence in Narrative, and the Seumas McNally Grand Prize, and it felt weird and good to be at the table and hear it. For each of the awards that we were nominated for, I’d picked out a game that wasn’t ours that we were rooting for, and at the moment of the announcement, I was crossing my fingers for them. For the awards that we didn’t win, my picks won about half the time; for the times we did win, it was a huge surprise. I think I remember loudly shouting “what the fuck” when the announcement for the Grand Prize was made.

We’d already met before the event, and talked about what our plans were if we won. We didn’t want to bore the audience with everyone having a chance to talk, so we decided to limit who was going to talk; Scott, as the primary face of the game, would speak, and if we won the grand prize, we’d take advantage of the fact that it was the end of the event to get others to say a few words.

I don’t remember much about the journey up to the stage. I do remember focusing on the fact that I was potentially on camera, so I had to maintain my stage face. I do remember noticing, for the first time, that you can’t hear what the person at the microphone is saying. I had to wait until I was back home and could watch the recording to hear what Scott, Alec, Bethany and Bekah had said.

After you’re done giving whatever remarks you have, you’re taken off stage, and led into an area with cameras and people who want to take pictures. I don’t remember much about this either, but I do remember being formed into a line and having pictures taken. There are selfies on my phone with Adam and Bekah that I only fuzzily remember.

We ended up leaving the awards shortly after the final award we were nominated for was announced. We walked down to Zero Zero, and ordered pizza. Adam proposed a toast. It was the same toast he’d given last year, less than a week after the game’s launch: “It shouldn’t have worked.”

People usually warn against putting people on pedestals. Having attended GDC and other community events as a face in the crowd, it’s hard to avoid doing that. This is the GDC in which a lot of my heroes came down off the pedestals, and I ended up just hanging out with them and making friends. I left GDC more emotionally fulfilled than when I came in. The indie games scene (which is a very specific thing, and is not the only group of people independently producing games) relies very much on personal networks of friends, and until you have that relationship, it can feel quite isolating.

Team Night in the Woods, on the last day of GDC 2018. From left to right: Jon Manning, Alec Holowka, Em Halberstadt, Adam Saltsman, Rebekah Saltsman, Bethany Hockenberry, Scott Benson. Photo taken by Felix Kramer.

We need to get back to work on Night in the Woods now! More from us soon...

How Night in the Woods Uses Yarn Spinner

We recently announced that we're building Night in the Woods for mobile! We're super excited about this, so we thought that we'd share a bunch of technical behind-the-scenes stuff on our blog over the coming weeks and months. This is the first of those posts! 

Yarn Spinner is the dialogue engine that we wrote, and was used in Night in the Woods. It’s open source, freely available, and we think it’s pretty powerful.

One of the reasons why we think Yarn Spinner is powerful is that it’s designed to focus on as little as possible. There’s literally only three things that Yarn Spinner can do with your game: it can send lines of dialogue, ask for a selection among a group of options, and send a command for your game to interpret.

The idea behind this is that your game can add what it needs to on top, rather than being forced to fit inside the ideas that we had when we first wrote the system. There are several excellent dialogue systems that are designed to be very good at operating within the structure of a role-playing game, or a choose-your-own-adventure system (Twine is a great example of this last one), but for Yarn Spinner, we wanted the system to be more generalised, and able to be applied to a wide variety of games systems.

The consequence of doing that, however, is that a game needs to do more work to add the features that it needs. While we built Yarn Spinner with NITW in mind, there are several features that are quite specific to the game. 

In this post, we’ll highlight some of the cooler things that Alec Holowka, the lead developer of Night in the Woods, built on top of the Yarn Spinner system to support its needs.

Example Dialog

Here’s an example of the kind of dialogue that exists in Night in the Woods. Here’s Mae and Gregg, planning on going to Donut Wolf:

Gregg: They got pancakes now! :)
<<close>>
//angus walks across the screen and off the left//
<<walk Angus AngusOffLeft>>
<<wait 3>>
Angus: fine.
<<lookUp Mae>>
<<lookUp Gregg>>
Gregg: \o/ D:
Gregg: RIDE THE CHARIOT!
<<dilate Mae .85 .5>>
Mae: TO DONUT HELL!!! \o/
<<runNextLinesTogether 2>>
Mae: {width=8}[shake=.05]AWOOOOOOOOOOOOOOOOO!![/shake]
Gregg: {width=8}[shake=.05]AWOOOOOOOOOOOOOOOOO!![/shake]

This dialogue is part of the raw source code of Night in the Woods. When the scene loads, the dialogue attached to the characters is parsed; first, it’s parsed into a data structure called a parse tree, which is then converted into a simple binary representation. This process is quite similar to how other code gets compiled into a binary that can be run on a machine.

At the end of this process, the resulting bytecode for the above dialogue snippet is this:

Node GreggFQ4Intro:
     0   L0:
             RunLine         GreggFQ4Intro-0           
             RunCommand      close                           
             RunCommand      walk Angus AngusOffLeft                      
             RunCommand      wait 3                          
     5       RunLine         GreggFQ4Intro-1          
             RunCommand      lookUp Mae                      
             RunCommand      lookUp Gregg                      
             RunLine         GreggFQ4Intro-2         
             RunLine         GreggFQ4Intro-3        
    10       RunCommand      dilate Mae .85 .5                      
             RunLine         GreggFQ4Intro-4       
             RunCommand      runNextLinesTogether 2                      
             RunLine         GreggFQ4Intro-5      
             RunLine         GreggFQ4Intro-6     
    15       RunCommand      close                           
             RunCommand      irisOut 1 wait                      
             RunCommand      sectionTitle GreggFQ4Intro BeaCar                      
    18       Stop                                            

String table:
GreggFQ4Intro-0: 
    Gregg: They got pancakes now! :) (GreggFQ4Intro:1)
GreggFQ4Intro-1: 
    Angus: fine. (GreggFQ4Intro:6)
GreggFQ4Intro-2: 
    Gregg: \o/ D: (GreggFQ4Intro:9)
GreggFQ4Intro-3: 
    Gregg: RIDE THE CHARIOT! (GreggFQ4Intro:10)
GreggFQ4Intro-4: 
    Mae: TO DONUT HELL!!! \o/ (GreggFQ4Intro:12)
GreggFQ4Intro-5: 
    Mae: {width=8}[shake=.05]AWOOOOOOOOOOOOOOOOOOOOOO!![/shake] (GreggFQ4Intro:14)
GreggFQ4Intro-6: 
    Gregg: {width=8}[shake=.05]AWOOOOOOOOOOOOOOOOOOOOOO!![/shake] (GreggFQ4Intro:15)

Each line of this bytecode is then executed, one after another, by Yarn Spinner, which sends along the lines, options and commands that it encounters. This is part of the standard behaviour of how Yarn Spinner works in any game; where Night in the Woods differs is what it does with its lines.

Character Names

Night in the Woods shows its dialogue in speech balloons that are attached to the characters. In order to correctly position them, NITW needs to know which character a line should be shown attached to; to figure that out, NITW looks at the start of each line, and figures out if it begins with a name followed by a colon.

Screenshot2.png

If it does, then the game checks to see if that character is in the scene; if they are, the speech balloon for the line is attached to that character.

Emoticons

Emoticons, or “what we used to use before emoji were a thing”, are those little faces that are composed out of plain text - stuff like :) and :(. Night in the Woods uses these to control player expressions, by looking for any emoticons that it recognises. When it encounters one, it triggers a corresponding animation action, such as animating from the neutral expression to a smile.

Screenshot3.png

There are several different kinds of emoticons. In addition to the smileys that control facial expressions, the game also includes several gestures as well; for example, whenever Mae puts her hands on her hips, it’s because the line included the emoticon “<o>”; when she throws her hands up into the air, it’s triggered by “\o/“.

This is true for other characters as well. When Gregg starts flailing his arms after Mae meets him in the Snack Falcon at the start of the game, it’s the result of using the emoticon sequence “:) \o/“

Screenshot4.png

Markup

Night in the Woods responds to custom syntax within lines that let a writer mark up the dialog for visual effects. For example, when a character needs to shout, the line contains markup like this: 

Mae: {width=8}[shake=.05]AWOOOOOOOOOOOOOOOOO!![/shake]

This causes the specific range of letters to be delivered in a shaky style. The markup also supports effects like character size, color, and balloon position, as well as fun effects like making a line of text wave.

Screenshot5.gif

Commands

Finally, Night in the Woods makes extensive use of commands. In Yarn Spinner, if you wrap some text in <<angle brackets>>, it won’t be sent to the game like a line of dialogue. Instead, it’s delivered as a command; the intent is that the game will manually parse its contents, and perform some action in the game.

Every time you see a character do anything besides talk, it’s the result of an action. There are a huge number of possible commands in the game; on top of the usually expected actions like sit, stand, walk, and jump, commands can also be used to control where and how a character is looking, the dilation of their eyes, and whether they’re visible or not. This last command is extremely important, since it’s used to control whether a character is present in a scene on a given day.

What’s interesting about NITW is that just about all of the gameplay logic is driven through Yarn Spinner. The language wasn’t designed to be a general game logic control system but it turns out it’s pretty good at this. That’s cool.

Taking it further

Several of these are very specific to NITW and its systems, while others are things that could probably apply to most games. As we continue to work on Yarn Spinner, we’re looking forward to making the project the best dialogue system it can be. For more information on Yarn Spinner, visit the project’s page on GitHub at https://github.com/thesecretlab/YarnSpinner.

If you're interested in more information on how we made Night in the Woods better with our open source software, check out Jon's talk from GDC 2017 on YouTube

Follow us on Twitter for more news and updates: @thesecretlab


Small Towns, Small Screens: Night in the Woods is coming to mobile

Night in the Woods is coming to iOS in 2018!

We're thrilled to announce that we've partnered with Infinite Fall and Finji in porting Night in the Woods to iOS. We've been working on it for a while now, and we're incredibly excited to say that it's coming in 2018.

Porting a game like NITW to mobile devices is interesting for two reasons. First, a mobile phone often has much less memory than PCs or consoles, and a less powerful graphics chip, so we need to do all kinds of things to make the game fit. Second, bringing any game that was designed for controllers or keyboards to a touchscreen means you've got to completely re-design the game to account for stuff like the player's hands covering up the screen, and the fact that you can't physically feel your controls.

You might have seen Jon posting about his work over the last several months on a tool for compressing sprites. This tool is part of the set of technologies we've been developing to support the port, and we'll be sharing more about it in the near future.

ezgif-3-a33a80bea7.gif

NITW also uses Yarn Spinner, our open source tool for creating and managing interactive dialogue in games. We're thrilled with the community response to Yarn Spinner, and improvements that result from our porting work will be merged into the main project.

If you're going to GCAP 2017, come and see Jon talk about the port in more detail at 3PM on Tuesday, October 24th (TODAY!), where he'll also be sharing tips and tricks on how to make your game the best possible experience on iOS devices.

For more info, be sure to follow us on Twitter, at @thesecretlab, @parisba and @desplesda. We share lots of interesting behind the scenes stuff!

Talk more soon. This is going to be fun. For questions or inquiries, please email lab@secretlab.com.au

Yarn Spinner Localisation

Earlier this year, we were approached by the rad folks at Infinite Fall with a very interesting challenge: could we please add support for localisation in Yarn Spinner, the dialogue system we wrote, for Night in the Woods?

Yarn Spinner was written to be a more advanced interpreter for the Yarn language, a Twine-inspired tool for writing interactive dialogue. Yarn Spinner lets you write your game's dialogue in a very natural way, with minimal technical syntax and a strong focus on getting your words into the game.

Because Yarn Spinner has such a strong focus on minimising the amount of stuff you have to write on top of your dialogue, we have to be careful whenever adding new features to the language. Our goal is always to reduce the amount of stuff you have to think about when writing. However, any kind of localisation system requires you to add additional information, in the form of a key that links a line's original text that of a translated version.

We created what we think is a pretty neat solution to this: hashtags. To localise a line of text, you add a hashtag that contains a short tag, like this:

However, Night in the Woods has a lot of dialogue. Like, buckets of it. Tagging each and every line would be hugely laborious. Fortunately, we already have a tool that's very good at quickly and thoroughly processing large amounts of Yarn dialogue: Yarn Spinner itself!

We therefore put together a little tool that can extremely quickly (like, 2 seconds quickly) tag every single line of dialogue that needs it. The tool only counts text that needs localisation - that is, anything that a player will see. It ignores all other stuff, like if statements and other behind the scenes stuff, as well as any line that already has a tag, which allows you to run the tool on files that have been partially tagged. In other words, it's a tool you can feed your dialogue through without worrying about anything it's doing.

Once you have some tagged dialogue, you can then generate a file that contains every line's text, as well as its localisation tag. The tool generates a CSV spreadsheet, which is the easiest format for most people to read.

Once you have the spreadsheet, you can send it off to your translators. In our case, we sent it off to a translation team in Italy, who converted the entire text of the Night in the Woods demo into Italian. They then sent back a spreadsheet that contained the Italian versions of all of the lines. We then dropped this into the Night in the Woods demo, and presto: localised!

The code for the localisation tool has already been merged into the development branch of Yarn Spinner, and we'll be putting out more info on how to use it soon. We can't wait to see more games in more languages using Yarn Spinner. Stay tuned for more!