Geeks With Blogs

News Bob Taco Industries is an ISV focused on game and app development for Microsoft platforms headed up by Michael B. McLaughlin. Mike is a Microsoft Visual C++ MVP (previously an XNA/DirectX MVP from 2011-2013), a developer, a writer, a consultant, and a retired lawyer. If you're a developer who is just getting started, consider checking out the BTI website's section for developers for links to code samples and other helpful sites.
Bob Taco Industries Blogging Division tutorial Posts about how to perform a task to help you acquire a skill.
Leveraging MSBuild for Ruthless Productivity
(Warning: This is semi-advanced stuff. It’s not hard, per se, but it involves editing important project files manually, which, if done wrong, can render them useless making it so that your code won’t compile (and may not even load into Visual Studio). So back up everything or (better still) commit it to your source control repository before doing anything so that in case you mess something up, you can easily recover! You have been warned.) I’ve been steadily becoming more familiar with MSBuild over ......

Posted On Tuesday, September 6, 2011 8:26 AM

XNA Custom Content Pipeline Extensions Sample
For the longest time, the Content Pipeline was a magic transmogrification device to me. I would add content to a content project and it would get mystically turned into stuff I would load in my game with ContentManager. A few months ago I decided it was time to put an end to its magical aspects and learn how it worked and how I could put it to work. I thought it would be helpful to share what I learned so I created a sample. This sample has two different custom extensions. The first is a complete ......

Posted On Sunday, May 8, 2011 2:33 AM

Drag and Drop in a Windows XNA Game
XNA Games in Windows are hosted within a Windows Forms Form. This allows you access to many special Windows-only features, such as drag and drop, provided that you know the right code to put in to get access to that form. Someone on the App Hub forums had asked earlier today about how to enable drag and drop for a Windows-only XNA game. Since it sounded like a neat thing to learn how to do, I coded up a quick sample to display it. As always, the code is heavily commented so that it should be easy ......

Posted On Sunday, March 27, 2011 2:05 PM

CheckMemoryAllocationGame Sample
Many times I’ve found myself wondering how much GC memory some operation allocates. This is primarily in the context of XNA games due to the desire to avoid generating garbage and thus triggering a GC collection. Many times I’ve written simple programs to check allocations. I did it again recently. It occurred to me that many XNA developers find themselves asking this question from time to time. So I cleaned up my sample and published it on my website. Feel free to download it and put it to use. ......

Posted On Tuesday, March 1, 2011 11:30 AM

XNA RenderTarget2D Sample
I remember being scared of render targets when I first started with XNA. They seemed like weird magic and I didn’t understand them at all. There’s nothing to be frightened of, though, and they are pretty easy to learn how to use. The first thing you need to know is that when you’re drawing in XNA, you aren’t actually drawing to the screen. Instead you’re drawing to this thing called the “back buffer”. Internally, XNA maintains two sections of graphics memory. Each one is exactly the same size as ......

Posted On Friday, February 18, 2011 1:11 PM

Using WP7 Themes In Your XNA Game
If you’ve played around with the WP7 emulator, you may have gotten into the settings screen and may have noticed that there are these things called “themes”. The emulator’s default is the “dark” background with the “blue” accent. However the phone can also have a “light” background, and supports the following accents: “magenta”, “purple”, “teal”, “lime”, “brown”, “pink”, “orange”, “blue”, “red”, “green”, and an eleventh optional color that the manufacturer of the phone can set. Most people naturally ......

Posted On Thursday, September 16, 2010 6:26 PM

WP7, XNA, and XAP Size
This is just going to be a quick post on some techniques for getting your XAP size down when creating games for WP7. It is by no means exhaustive. First, XAP files are basically zip files with specific requirements re: mandatory content and directory layout. So any solutions that would involve zip-style compression will almost certainly result in a larger XAP sizes due to added code. So those type of solutions are off-the-table. But if you can shrink your source input in ways that zip compression ......

Posted On Thursday, September 2, 2010 1:40 PM

WCF and XNA on WP7 – Hack Free
Update 1 (Sept. 17, 2010): While the part below about using SLSvcUtil.exe to generate the service reference undoubtedly still works, it is no longer necessary. The RTM version of the Windows Phone Developer Tools now properly supports right-clicking on your game project's "References" item in the Solution Explorer and adding a Service Reference that way. ChannelFactory and related methods remain unsupported. For more details see (Networking ......

Posted On Monday, August 30, 2010 7:36 PM

Properly Exiting Silverlight-based WP7 Games
Anyone who has read the Windows Phone 7 Application Certification Requirements (PDF) knows that a WP7 game can never be more than two taps of the Back button away from quitting the game. In XNA this is easy since the Game class provides a method called Exit that can be called with relative ease. In Silverlight nothing quite so easy exists. One clever hack that’s been making the rounds is to create a new instance of the XNA Game class and call its Exit method. However this solution, clever though ......

Posted On Sunday, August 22, 2010 4:38 PM

How to pin your game or app's tile in the emulator (and I still love you WP7!)
I came across this by accident the other day and thought it was really neat. So I wanted to share it to help karma balance my last post (more on that at the end). As I’m sure you know, Silverlight apps install automatically in the application menu. For XNA games, you need to use this handy workaround. Once you do, after you’ve deployed your app or game, it stays installed for the duration of the emulator session. “Yes, yes, we all know that,” you say. Ah, but did you know you could tile your app? ......

Posted On Wednesday, August 18, 2010 11:15 PM

Copyright © Michael B. McLaughlin | Powered by: