Archive for October, 2009

BJBK 2, Comment (TortoiseSVN, Version control)

Friday, October 30th, 2009

In “Banana jump, Barrel Kick(BJBK) 2: TortoiseSVN, Version control” I have mentioned that not all the files should be committed from the XNA game project. I didn’t mention that the content folder and especially the .contentproj file should be committed as well. I didn’t commit it and the Content has become Unavailable for my project. I fixed this by creating a new content project and tinkering with the .csproj file. But you could avoid this if you try rebuilding your project and see if the Content is available after you committed and checked out.

Banana jump, Barrel Kick(BJBK) 2: TortoiseSVN, Version control.

Thursday, October 29th, 2009

TortoiseSVN is a free client for Subversion version control system. In respect to the lone programmer, version control saves a version of your source code or project each time you commit your project. You then can checkout or get a local copy of any version of your project you committed in the past. I will be using TortoiseSVN for BJBK.
The first place to go is the TortoiseSVN homepage. There you can find the Download Page and download TortoiseSVN. I downloaded the 64bit version.
Installation is pretty straight forward. After you install TortoiseSVN, I suggest reading the Help from the beginning. That is what I did.
A point of confusion, at some point the Help will tell you about using commands from the command prompt in windows. However, you will need to install the Subversion Command Line client in order for this to work. The download can be found here.
The steps I took to start using TortoiseSVN were to read the Help up to and including “The Repository”. There you will learn how to create a repository. I used the import command to create the folders structure. You can read the daily user guide to better understand how to use TortoiseSVN. But I think for starting out you only need to know how to Checkout and how to Commit.
Checkout is the process of creating a local copy from the repository. You need to create a new empty folder in windows explorer, then right click that folder and select checkout. Then you need to provide the repository address. If you already did the tutorials of a 2D game in XNA, as I recommended in BJBK1, you would have a C# project inside a specific folder. You can copy that C# project inside your local copy of the repository, and then right click the local copy folder and select Commit. You will then be asked which files you wish to commit. You should select the minimum files in your XNA game project required to build and run your game. I believe these should be all the .cs, .csproj, your artwork and resources files, the Content folder, and the solution file (.sln). The reason you shouldn’t commit the temporary build files, is because there might be a problem when someone else work with you on the same project. This might not be the case in this project, but you should get used to working like that. I must tell that I don’t have a lot of experience working like this, and I am telling you what I was told by others. But it make sense to me.
The final step would be to create a new folder in a different place in order to checkout another local copy of your project. This time with the XNA project you committed. You should do this to check you can build and run what you have committed.

That’s it, I hope next time we can start seeing some code. But before that I might need to research what type of license or agreement to choose for the source code I am going to show.

Artist Christa Wolf

Thursday, October 29th, 2009

I am working on the intro of Labyrinthica, and was thinking to include some hand drawn art in the intro.
I contacted Christa Wolf, and here are the results:

Sketchs of lima

Story sketch part 1

The first part of the story.

Unfortunately, I might not use this art work in the game and might try to create the needed art in a different way. Maybe I will do the art work on my own.

The power of inertia

Monday, October 26th, 2009

I had a rough time the last week. Some stuff related to my game were frustrating me, and some difficult events at work. The thing is, a week ago I had a lot of motivation and everything was going fine and smooth.
I am not sure this is accurate or the absolute truth, but there seem to be a matter of inertia in motivation and developing a game. If you are already feeling good about working on your game and you are excited about it, its easier to keep on doing it. However, something like events related and not related directly to your game, could stop your wheel from rolling. After you stopped developing and doing the stuff you enjoyed doing, suddenly its very difficult to get back to it.
I was too lazy to work on my game, even though I knew that two weeks ago I had a lot of fun doing just that. Then I told myself what I have already learned from these kind of situations, you have to force yourself to work on your game. Even though its boring, you have to start pushing the wheel, and its hardest to push a standing wheel.
But it didn’t help, I was still too lazy to do it. Then I had thought to refine this “force yourself” method. I know it worked for me before, but now its not working. The refinement would be, start with the easiest things at first that would motivate you. Such as writing this blog(another good reason to write development blogs). Another thing is to have others set deadlines for you. For instance, if you work with a sound guy, you can decide that you have one month to complete the sound effects. Soon he will be sending you sound effects and you will have to work on them, because you have set a deadline.
We can learn from this that not all the things have the same difficulty when you are unmotivated. And if you see that you are too lazy to do something, it doesn’t mean you can’t do anything. You just need to find easy things to do first, soon you will start catch up and do the harder stuff as well. Finding external motivators can also help, such as having someone you work with set up a deadline to force you work on stuff. And eventually, remember that starting is the most difficult part, and after you start it will soon become easier. Although you have to remember this might be more complicated, but it might still help you thinking about it.
I will be glad to hear about your own experience and your own insights.

Reading while building.

Monday, October 19th, 2009

For the project Banana Jump, Barrel Kick, I thought to use Tortoise SVN. I have used Tortoise at work a bit, but I never got to install it or read about it. After installing Tortoise I have decided to start reading the Help file. However, I was also working on Labyrinthia which means I had to work on either one of them, or both of them simultaneously.

Part of the builds and compiling of Laby took a long time, leaving me the option to read on one computer while my other computer is building. The first problem I encountered is that I didn’t know when the other computer completed a build. And since Laby is my primary project, that was a problem. I solved this in Visual C++ 2005 by simply adding a Dos command line that plays a wav file every time the build was completed.
In “Project->Properties->Configuration Properties->Build Events->Post-Build Event”, I have added the command line "c:\Program files\Windows Meida Player\mplayer2.exe" /play /close "D:\Projects\Music\MenuMusic.Wav"
This is a partial solution, because it would only play music if the build was successful. But that was enough for my needs at that time.

I was multi tasking reading and building for a while, but unlike the previous technical problem, I encountered a problem of a different nature. The Tortoise Help document has a few chapters in it. The first few chapters are short and can be read quickly. However, I reached a chapter that I feared was too long to be going back and forth, and I wouldn’t be able to understand it this way. This is a very important point, this fear was irrational. I wasn’t actually scared of anything, I just wanted to move back to the usual patterns in my brain that told me to work on only a single task at a time. I was back to working on a single task, developing Laby. Very quickly I found myself surfing the Internet, waiting for compilations to complete. It took me a while, but eventually I thought, what if I would read the Help file and work on Laby simultaneously, even though its a long chapter? The answer is, I didn’t have an answer. But I didn’t even try. Only by trying I would know if I could handle it. Then I also thought, what if I would read and won’t understand? I can always read it again and its better than just surfing the web. So there is no big loss here as well. That drove me to try read the “big” chapter and develop simultaneously. After actually trying to do it, I realized it was really easy. This might be just the case with me, but I think my brain don’t like to “break the patterns” and prefer to do what is familiar, even if its not the best choice.
I think trying to do something different than what you are used to, could be beneficial, even if you didn’t achieve the ultimate goal by doing that. And in respect to programming, you should try to work on two things simultaneously, even if you think you wouldn’t be able to.