Instructions - .NET - Command Line

This article shows you how to get started creating a SwinGame using the Command Line version of either the C#.NET or VB.NET SwinGame SDK.

Requirements
You will need the following to use the Macintosh and Unix Mono versions of the SwinGame.

Instructional Video
Watch the video of process for installing, compiling, and starting your game.

Requirements
You will need to following to use the .NET Template version of SwinGame.
 * A Text Editor or Visual Studio 2005 Express (Minimum)
 * Microsoft .NET Framework 2.0
 * The SwinGame .NET Template (either C# or VB) SDK - download
 * [[Media:SGSDK-1-1-3-C--win.zip|SGSDK-1-1-3-C&#35;-win.zip]]
 * [[Media:SGSDK-1-1-3-VB.NET-win.zip|SGSDK-1-1-3-VB.NET-win.zip]]

Installing
The file downloaded contains all the files you need to start making the game. You will not need to install this, just copy the contents of the zip file to wherever you like. The following files are included in the SDK.
 * GameLogic- The main game source file. You will be writing your game to this file.
 * GameResources - Resource manager (Explained in here)
 * build.cmd - A script to compile the game.
 * bin folder - A compiled game will go in here.
 * lib folder - Contains the SwinGame libraries.
 * Resources folder - Contains the resources used in a game.

Starting a Game
In order to run the game you need to do the following:
 * 1) Open the SDK Command Prompt (Comes with Microsoft.Net FrameWork SDK 2.0
 * 2) Move to the project directory
 * 3) Compile the game using the build.cmd script, be sure to execute the game within the SDK Command Prompt
 * 4) Run the .exe file in the bin folder.

That's all. You have now setup SwinGame and are ready to create your own games.

Upgrading
The following instructions indicate how to upgrade an existing project to a new version of the SDK.
 * To 1.1.5 - from 1.1.4
 * Delete the lib folder in your project
 * Copy lib folder from v1.1.4 into your project
 * To 1.1.4 - from 1.1.3
 * Delete the lib folder in your project
 * Copy lib folder from v1.1.4 into your project
 * To 1.1.3 - from 1.1.2
 * Delete the lib folder in your project
 * Copy lib folder from v1.1.3 into your project
 * To 1.1.2 - from 1.1.1
 * Delete the lib folder in your project
 * Copy lib folder from v1.1.2 into your project
 * Rename GameResources in your project
 * Copy GameResources into your project from v1.1.2
 * Merge in changes to the LoadImage, etc. routines from your old GameResources source file
 * To 1.1.1 - from 1.1.0
 * Delete the lib folder in your project
 * Copy lib folder from v1.1.1 into your project
 * Rename GameResources in your project
 * Copy GameResources into your project from v1.1.1
 * Merge in changes to the LoadImage, etc. routines from your old GameResources
 * Copy new images from v1.1.1 Resources folder

Distributing your Game
When your game is complete you can distribute it by packaging up all of the files in the bin folder. These can then be distributed to anyone running Windows. They run the game by double clicking the executable. They do not need to install anything to run the game.

To Run this game on Mac or Unix you will need to follow the Mono Instructions, because you'll need Mono to run the game on Mac or Unix, the packing script for Mac application, and the Mac/Unix Libraries.

Enjoy programming with SwinGame!

Also See
Compiling SwinGame SDK for Visual Basic .NET and C# .NET (Command Line) (YouTube)