Silverlight Sports Game Contest Results
The TeamZone Sports Silverlight Sports Game Contest is over, and the judges have weighed in. We had some great entries but could only pick 3, so here they are:
First Place: Hook Shot by Andy Beaulieu
Second Place: Ball Blocks by Matt Casto
Third Place: John Brummel University's Blunderbuss Olympics Vol. 1 by David Sushil
You can check out the winners and all of the entries here:
http://www.teamzonesports.com/silverlightgamecontest
A much cleaner Game Loop in Silverlight 2 RC0
Silverlight 2 RC0 is now available. See the details here:
http://weblogs.asp.net/scottgu/archive/2008/09/25/silverlight-2-release-candidate-now-available.aspx
They've made it much easier to do a game loop now with a new event that has been added. This event fires before the rendering of each frame. So now you don't need an empty Storyboard or a DispatcherTimer. Let's see how we can animate a rectangle, here's the page.xaml:
<UserControl x:Class="SilverlightApplication34.Page"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Width="400" Height="300">
<Canvas x:Name="LayoutRoot" Background="White">
<Rectangle x:Name="rect" Fill="Red" Width="50" Height="50"/>
</Canvas>
</UserControl>
Then for the game loop, all you need to do is something like the following:
public partial class Page : UserControl
{ double x = 0;
public Page()
{ InitializeComponent();
CompositionTarget.Rendering += new EventHandler(CompositionTarget_Rendering);
}
void CompositionTarget_Rendering(object sender, EventArgs e)
{ x+=.3;
rect.SetValue(Canvas.LeftProperty, x);
}
}
You can then add things like elapsed time between renders, etc. I'll follow up with a post on converting the game loop logic covered before to use this method.
Silverlight Sports Game Contest deadline tonight
I can't believe it's already here, but we're reaching the deadline for submissions in the TeamZone Sports Silverlight game contest. If you've been working on a game, make sure it's submitted by Midnight Eastern time on Monday September 8.
Submission instructions here: http://www.teamzonesports.com/silverlightgamecontest/submit
Drop me a note if you have any questions.
Tampa User Experience Users Group First Meeting September 10
The Tampa User eXperience User Group will have its first meeting next Wednesday. The presentation will be MS Ajax Client Script 101 by Jay E. Kimble.
We will be meeting at Answers Systems (4029 Tampa Road, Oldsmar, Fl 34677... right next to the Oldsmar Fleamarket).
Pizza and drinks will be supplied, so come on out. One lucky winner will walk away with an MSDN Premium subscription!
No web site yet, but go to Jay's blog here if you plan on coming and let him know:
http://theruntime.com/blogs/jaykimble/archive/2008/09/03/tux-tampa-ux-is-next-wednesday-sept.-10th-at-630pm.aspx