XNA Dragable Selection Utility

The game I have been working on lately had a need to select multiple items at one time.  Something pretty common in the RTS world, especially on the PC platform.  It’s almost second nature to simply click and drag to select multiple items on the screen in those kind of games – and in everyday computer use I suppose.

So I wanted something similar, however for the most part the game is targeted for the Xbox under the Xbox Indie Games umbrella.  That is not to say that the same functionality couldn’t be driven by the controller of course.  Or you could go the direction of something like Halo Wars – which had more of a larger selection bubble that you just spanned over the units.  Either way it got me thinking, and realized that at least at first glance I wasn’t exactly sure how they even accomplished this kind of thing in games like stracraft, etc. I still don’t know exactly how they do it, but after toying around a bit last night I got what I think is a pretty good representation of it.

On the surface it seems simple enough especially to a user that is just used to the ability to do such a thing – but it probably made me think a bit more than anything I have done recently in XNA.

Leave a Reply

Get Adobe Flash playerPlugin by wpburn.com wordpress themes