Introduction to XNA on Windows Phone 7 SILVERLIGHTSHOW.NET Webinar Peter Kuhn, June 30 th, 2011

Preview:

Citation preview

Introduction to XNAon Windows Phone 7SILVERLIGHTSHOW.NET WebinarPeter Kuhn, June 30th, 2011

About Me

• Peter Kuhn (34) - "Mister Goodcat"• MCPD/MCTS/MCC• Technical author• Trainer/consultant for .NET/Silverlight/WP7• http://www.pitorque.de – • Blog: http://www.pitorque.de/MisterGoodcat• Twitter: @Mister_Goodcat

2

Agenda

• Windows Phone 7• Mobile Games• Silverlight vs. XNA• Introduction to XNA• Live Coding Sample• More on XNA• Mango Demo• Outlook and Q&A

3

Windows Phone 7

• Microsoft's new mobile platform• Again, it's a mobile platform– Limited CPU power– Limited GPU power– Slower file system I/O– Network bandwidth limitationsDon't be paranoid, but careful and considerate

• Don't ever trust the emulator

4

Mobile Games

• Biggest market share for WP7

• Similar numbers for iOS + Android

• High demand from consumers

• Interesting chance for developers

5

Silverlight vs. XNA

• Two equally treated frameworks• Technologies can (partly) be mixed• No requirement to use XNA for games

(you can use Silverlight for games too)– Use Silverlight if the included controls, animation or

layout system is more effective– Use XNA for more complex games and for its unique

selling points like 3D rendering– Generally only do simple/static games in Silverlight– Mind the upcoming Mango update

6

XNA (1)• Managed environment,

but focuses on performance• More comfort = less performanceXNA has none of Silverlight's comfort– No declarative UI (XAML)– No layout system– No animation system– No data binding– No built-in controls and themes/styles– No sophisticated text rendering

7

XNA (2)

• Different programming paradigm to Silverlight• Puts you in an "active" role

instead of a passive consumer• Game loop as the central driving construct– Update: Handling input, executing logic– Draw: Rendering all the content to the screen

• "Think incrementally"

8

Live Coding Sample

9

XNA (3)

• Lack of comfort makes some things really hard– User interfaces (menus, option screens etc.)– Good looking text rendering (line wrapping etc.)– Complex screen layout (e.g. lists of data, scrolling)– User input (no text box etc., no SIP)

• One possible solution: the Mango update– Mixing Silverlight and XNA in the same application– Comes at the cost of worse portability

10

Mango Demo

11

Outlook

• XNA is much more than what we learned today– 3D, Sound and music, multi-touch input, etc.– Additional non-technical topics

• Full training also covers not so common topics:– Chances and limitations of an indie developer– Sharing experience from commercial game projects– Monetizing options– And a lot more…

12

Q&A

13

Thank you for attending.

14