Hi, I was a little bored over the weekend, and took a shot at this. File available here:
http://xnamatrix.com/xnareq.phpFirst of all, I needed to check whether or not people had .NET 2.0 installed. I search around and came up with this unique directory: C:\Windows\Microsoft.NET\Framework\v2.0.50727\
So I used NSIS to create an installer which checks for this directory's existence. If the directory does not exist, I use wget to download the file, and NSIS to subsequently execute it. Then, I combine it with my previous xna requirements checker app that I wrote a few months ago (
http://xnamatrix.com/xnareq.php) to check for DX/XNA.
First, I check the graphics card for pixel shader 1.1 or above. I also give a warning if it's below 2.0 (since a lot of xna stuff requires 2.0), but it will return as a success anyway.
For the DX portion, I queried a webpage (
http://www.xnamatrix.com/xnari/dx_required.txt) for a list that I can update at any time, such as when a new version is released. Similarly, I did the XNA portion using another web file (
http://www.xnamatrix.com/xnari/xna_required.txt), and I also did a check for version number of the assemblies. In this case, it's checking for 1.1 and above (i'm assuming that 1.1 means 1.0 refresh, since my current assemblies are at 1.1.x).
Once I determine which technologies I need to update, I download the redistributables and execute and install them. Finally, everything is locally stored on the client's computer until he or she uninstalls my program (XNARI). The client can always re-run my program to check for any new updates.
The final size of this program is about 400k (the bulk of which is wget.exe), and it will only download what is necessary to install all the prereqs.
Please try it out at let me know if anything breaks. Also, I'm wondering about the legalities of all this. I included the xna license agreement in my installer, but i'm a coder, not a lawyer, so i'm not sure what i should do. And if anybody has any better methods/ideas, i'd love to hear them.