Mastodon Icon RSS Icon GitHub Icon LinkedIn Icon RSS Icon

How to manage a Videogames Bibliography in LaTeX

There is a common question in academia for people working on videogames: “Is there a consensus on how to cite videogames in academic papers?”. Obviously not, there is no consensus and probably never will. However, I will try to show you a solution to this problem that I enjoyed a lot in the last months. It is clear, it is customizable and it is the most formal way I’ve found to do that.

Use BibLaTeX

The first prerequisite is to use BibLaTeX. BibLaTeX is a replacement for BibTeX (the default bibliography manager for LaTeX). It is more flexible and powerful than BibTeX, therefore, even if it is a bit more complicated to set up, it is worth the switch in any case.

In order to switch to BibLaTeX you can follow the simple steps described here. It is not hard. There are just three things you have to do. First, load the BibLaTeX package with

1
\usepackage[style=<somebiblatexstyle>,<other options>]{biblatex}

Second, load your bibliography with

1
\addbibresource[<options for bib resources>]{<mybibfile>.bib}

And, at last, print your bibliography.

1
\printbibliography[<options for printing>]

Create your videogame bibliography

Cool. Now, what we want to do is to create our personal videogame bibliography. Ideally, we want a new LaTeX command \citegame{game_id} for managing videogame citation. First, however, we have to create our videogame.bib file. Inside this file, we will add entries for videogame in this way:

@software{bioshockinfinite,
  author = {{Irrational Games}},
  title = {BioShock: Infinite},
  url = {http://www.bioshockinfinite.com/main.php},
  version = {1.1.25},
  date = {2013-03-26},
}

Pro Tip. It is possible that you want to print your videogame bibliography in a separate section (different from your hard books and papers bibliography). You can do this in this way:

% Print the standard bibliography.
\printbibliography[title={Bibliography},nottype=software] 
% Print your Videogame/Software Bibliography
\printbibliography[title={Videogames},type=software]

Add a custom cite command

Now it is time to implement our custom cite command! In the preamble of your LaTeX file insert this code:

\DeclareCiteCommand{\citegame}
  {\boolfalse{citetracker}%
   \boolfalse{pagetracker}%
   \usebibmacro{prenote}}
  {\ifentrytype{software}{%
  	\printfield{title}%
    \setunit{\addspace}%
    \printtext[parens]{%
    \printnames{author}%
    \setunit{\addcomma\space}%
    \printfield{year}}}{\GenericError{}{Not a game entry}{}{}}}
  {\multicitedelim}
  {\usebibmacro{postnote}}

This command creates a custom \citegame{game_id} that you can use to cite videogames. You can customize the format but in my documents I use the “Title (Developer Year)” format presented above. For instance, you can use the following code:

\caption{Elizabeth in \citegame{bioshockinfinite} is an AI companion which, 
among the other tasks, will randomly provide ammo, medikits and money for the player.}

To get a result like this: Latex videogame Example

Latex Videogame Bibliography

Conclusion

I hope enjoy this very small tutorial! Feel free to update and improve it. There are still some rouge edges that I would like to remove. In any case, share it with your colleagues if you like!