Download
![]()
In order to get going you need to first download the Sparrow package.
There is a download package containing everything you’ll need: The source code, a demo project and a scaffold for your own games.
Test-Drive
The package contains a sample application in the form of an Xcode project. Open the project and build it – everything should work out of the box. As a primer, we recommend you just have a look around – the Demo shows you how to accomplish the most common tasks.
Creating your own game project
There are two easy ways to create your own Xcode project with Sparrow. You can either start with a copy of the “Scaffold”-project (a bare-bone Sparrow application), or you install the Xcode project templates. Whatever you choose, you have to set up a few things first.
Preconditions:
Sparrow is linked to your application via Xcode project references. This has the advantage that it’s easy to update Sparrow (just download a new release and overwrite the old one in the same directory) and that you can easily step into Sparrow source code, in case you want to do so.
This has to be done only once:
- Set up a shared build output directory that will be shared by all Xcode projects.
- In the Xcode preferences, tab: “Building”, set “Place Build Products in” to “Customized location” and specify a common build directory (anywhere you want).
- Set “Place Intermediate Build Files in” to “With build products.”
- Add a “Source Tree” variable that Xcode can use to dynamically find Sparrow.
- In the Xcode preferences, tab: “Source Trees”, create a new Source Tree variable.
- For Sparrow, create SPARROW_SRC and let it point to /some_valid_path/sparrow/src/
Creating your new project
a) Xcode Project Templates
Our friend from sodeso.nl has created custom code templates for Sparrow. Just click here to download the templates. Installation instructions are included!
b) Scaffold Project
If you don’t want to install anything, there is an alternative. In the folder “samples/scaffold”, you will find an Xcode project that contains a bare-bone Sparrow application. Follow this steps to use it as a basis for your game:
- Copy the “scaffold”-folder to the place where you want to have your game project.
- Open “AppScaffold.xcodeproj”
- Build and run – just to see if everything works fine. If it does not work, check if you have created the SPARROW_SRC variable in Xcode, and if it points to the right place.
- In Xcodes menu, click on “Project” -> “Rename …”
- Enter the name of your game.
- That’s it! Now you can start to develop your game with Sparrow.
