Even though it appears that I’ve fallen off the end of the earth, it’s not true. For the last 45 days, I have been at the top-secret Cyragon Games headquarters working on their latest hit game.
Title from the game Strategic Command
That’s right, Strategic Command!
Two armies. One battlefield. One victor. Will it be you?
Use strategy and deception to maneuver your armed forces into your opponent’s territory and conquer their headquarters. The winner will be crowned with glory and live to see their name thunder down the hallowed corridors of time. The loser will be buried in infamy.
The fate of the war is in your hands. What will you do, commander?
This will be our entry in the Silverlight Server Quest Game Contest.
Strategic Command Screenshot
We’re planning to do a postmortem on the game and make some other exciting announcements so check back soon.
Announcement, Silverlight games, Silverlight, StrategicCommand
#1 Visual Studio Express 2008 with SP1
www.microsoft.com/express/download/
You can download an ISO with all the express editions or just the Web Developer edition. The only one you need is Visual Studio Web Developer 2008 SP1.
If you don’t have SP1 for Visual Studio 2008, get it here:
www.microsoft.com/downloads/details.aspx?FamilyId=FBEE1648-7106-44A7-9649-6D9F6D58056E
#2 Silverlight Tools for Visual Studio 2008 SP1
Download the tools for developing applications of awesomeness here:
www.microsoft.com/downloads/details.aspx?FamilyId=c22d6a7b-546f-4407-8ef6-d60c8ee221ed&displaylang=en.
If you want some offline documentation, you can download that here:
www.microsoft.com/downloads/details.aspx?FamilyID=bce7684a-507b-4fc6-bc99-6933cd690cab&displaylang=en.
Optional: Expression Blend 2 Trial
This isn’t a requirement but it will give you a good place to start if you’ve never played with XAML. Download it here:
www.microsoft.com/downloads/details.aspx?FamilyId=5FF08106-B9F4-43CD-ABAD-4CC9D9C208D7&displaylang=en
and don’t forget Blend SP1
www.microsoft.com/downloads/details.aspx?FamilyId=EB9B5C48-BA2B-4C39-A1C3-135C60BBBE66&displaylang=en
or Expression Studio 2 Trial here:
www.microsoft.com/downloads/details.aspx?FamilyId=7AE2720C-72BA-489B-ADBB-EE6F3C79066D&displaylang=en
Optional: Deep Zoom composer
Needed if you want to develop deep zoom applications:
www.microsoft.com/downloads/details.aspx?FamilyID=457B17B7-52BF-4BDA-87A3-FA8A4673F8BF&displaylang=en
Optional: Silverlight Toolkit from Codeplex
Nice set of components from the community for you to use or extend in your Sliverlight applications. Download it here:
www.codeplex.com/Silverlight/Release/ProjectReleases.aspx
Other Options
If you want to go hardcore, check out this article on developing Silverlight applications in Eclipse: www.eclipse4sl.org/download/.
If you use Blender, the free open source 3D content creation suite, you might want to check out this XAML exporter. Not that it will fully work for Silverlight (it’s really for WPF). But it’s still pretty cool: www.codeplex.com/xamlexporter
That’s it! Go forth and develop!
Don’t forget to check out silverlight.net for videos, blogs, and forums. More resources: http://www.microsoft.com/silverlight/resources/tools.aspx.
Silverlight Blender, Eclipse, Silverlight, Visual Studio, XAML
Today I used LINQ to help implement a cleaner solution to a problem I was trying to solve. It’s really just some syntactic sugar and a chance to use a buzzword (LINQ).
My simple data class:
1
2
3
4
5
| public class ReturnRecord
{
public String FieldKey;
public String FieldValue;
} |
Basically, I needed to return an array with the key/value pairs found in a text document (of type ReturnRecord[]). RegEx was my obvious choice for parsing the text and finding the key value pairs. The keys and values will be decorated with #’s in the document.
Sample text:
1
| String text = "Blah blah #key#value# blah blah."; |
Here is my RegEx setup:
1
2
| Regex regex = new Regex("#(.+?)#(.+?)#");
MatchCollection keyvalues = regex.Matches(text); |
Now I can use a nifty LINQ query to create the array for me without having to write the usual for-loop plumbing. As you can see, LINQ creates the objects and initializes them for me in a single query.
1
2
3
4
5
6
7
8
9
| List<returnrow> results;
if (keyvalues.Count > 0)
{
results = (from Match m in keyvalues
select new ReturnRow
{ FieldKey = m.Groups[1].Value,
FieldValue = m.Groups[2].Value }
).ToList();
}</returnrow> |
All that’s left is to return
and I’m done. It’s that much less for me to maintain.
MSDN has some examples as well http://msdn.microsoft.com/en-us/library/bb882639.aspx or, check out this post http://schotime.net/index.php/2008/03/10/linq-and-regular-expressions/.
.NET C#, LINQ, RegEx