Setting up your IDE

The first thing we are going to learn how to do is get Visual C# .NET set up to create and run our engine demos in a manner that lets us keep the engine code separate from the demos themselves so we can be sure that our 3D engine’s file only contain code that is important to the engine itself, and not any of the many hundreds of uses it could eventually have.

The best method of accomplishing this, in my opinion, is to have multiple projects within Visual C# that contain the code for different sections. We could even have multiple projects for the actual game engine itself and have them compiled into different libraries for use later. I will keep the engine all together in one project for this tutorial series, but feel free to separate them how you see fit.

Step 1: Making the projects

Lets start by making two projects in Visual C#. One of these will contain the code or our engine and one will contain the demo code that will use the engine to create small and hopefully interesting apps that we can use to show o what we have created.

Start out by opening up Visual C# (VC# from now on so I don’t have to type so much) and selecting File-New-Project. For the first project we are going to create a Class Library, so click that option and name it whatever you would like to call the engine. I am using Hazy Mind 3D Engine for my name, but anything will work. Click ok, and then depending on how you have your VC# set up it may create a folder and save the solution to start out, or you may have to manually save it now.

Before we save the solution as is though, lets remove the default Class1.cs file that is created. Now, go to File-Save All (or Save Solution As) and a Save Project box will pop up. your porject’s name will appear in the Name: box and in the New Solution Name: box as well. I don’t mind having a soultion with the same name as one of its child projects, so this is how I will leave mine. Browse to the location you would like to save this solution and click save. I also have it create a directory for my solution just to keep things organized.

Now that we have our engine library created, we have to make a project that will use this library and run our demos. We will accomplish this by right-clicking on our solution name in the Soltion Explorer window and choosing Add-New Project… Click Windows Application and name it something appropriate. I will call mine Hazy Mind Demo. Once again (because I like to start from scratch) lets remove the default files that were created in this new project and save the solution.

Now there is only one thing left to do to get this setup ready to run our engine, and that is to choose the correct start up project to use when we are debugging later. To do this, right click on your Windows Application project and choose Set As Startup Project.

That’s it! Once you have this all set up you are ready to follow the rest of the tutorials. Good luck and happy learning.

Leave a Reply

You must be logged in to post a comment.

Do NOT follow this link or you will be banned from the site!