Game Development Stack Exchange is a question and answer site for professional and independent game developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I was told by a company that better than putting an installer on a CD would be allowing the user to run the demo directly from the CD. Is this even possible when the demo might require things such as the XNA framework to run? Are they actually wrong and an installer is in fact necessary for the dependencies?

share|improve this question
That would be better, but XNA has external dependencies that need to be installed, so you're out of luck i believe. – George Duckett Oct 12 '11 at 10:48
They would have to have installed (or have to install) the dependency files. .Net and XNA redist will install to the HD, but once they're installed, the game should run off the CD. – Richard Marskell - Drackir Oct 12 '11 at 15:18
You could reduce it to one of those Silverlight XNA libraries; which would VASTLY simplify the installation experience - but that would limit it to 2D. – Jonathan Dickinson Oct 12 '11 at 22:39
up vote 4 down vote accepted

XNA, like many libraries, has dependencies on runtime components that must be in place in order for applications that depend on it to run. While you don't strictly speaking need an installer, the alternative is to ask or expect the user to have the appropriate dependencies installed or install them themselves (which makes for a very poor user experience).

You can create an autorun file on your CD which launches your installer. What many games do is have the launcher detect the presence of your game and/or its dependencies and have the installation app tailor itself to what's installed -- presenting install options normally, and if the game is already there, presenting a "launch" option or possibly even launching directly into the game (this may annoy users though).

Note that if you elect not to use existing installation solutions (NSIS, Inno, Windows Installer, et cetera) and write your installer shim yourself you have to be careful -- even C and C++ code requires redistributable components, so make sure to ensure the minimum OS level you support already guarantees them or build something that won't depend on them.

Once the dependencies are in place, the game itself can be launched from the disc so long as it won't try and write to any relative directories, such as its own .exe directory (a well-behaved Windows application shouldn't do this anyway).

Obviously the above applies only to XNA on Windows, as it's the only platform you can execute code off a disc on.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.