2/22/2018
Posted by 
2d Game Using Wpf2d Game Using Wpf

I started to program computers when I was 11 years old, as a hobbyist, programming in AMOS Basic and Blitz Basic for Amiga. At 12 I had my first try with assembler, but it was too difficult at the time. Then, in the same year, I learned C and, after learning C, I was finally able to learn assembler (for Motorola 680x0). Not sure, but probably between 12 and 13, I started to learn C++.

What would be my options if i would like to create a 2D action game in WPF(for the ease of building UI Layout) without having noticeable performance loss? Apr 25, 2008 Currently my plan is to make a Viewport3d and just have camera face down on a 2D plane, but I'm not sure how to do that. Christian Moser's WPF Tutorial. An elaborate tutorial about the Windows Presentation Foundation with hunderts of samples.

I always programmed 'in an object oriented way', but using function pointers instead of virtual methods. At 15 I started to learn Pascal at school and to use Delphi.

At 16 I started my first internship (using Delphi). At 18 I started to work professionally using C++ and since then I've developed my programming skills as a professional developer in C++ and C#, generally creating libraries that help other developers do their work easier, faster and with less errors. Want more info or simply want to contact me? Take a look at: Or e-mail me at: paulozemek@outlook.com Codeproject MVP 2012, 2015 & 2016 Microsoft MVP 2013-2014 (in October 2014 I started working at Microsoft, so I can't be a Microsoft MVP anymore).

Hi, thanks for the added links. Interestingly, one of them points to Andy Bealieu's PhysicsHelper project, which I used for several years (until it was abandoned). What I'm trying to do now is a replacement for that - a very simple game engine for first year programming students. In other words, exactness or performance is not so important. Also, it doesn't really have to be WPF, but since XNA and Silverlight are gone, then what else is there that isn't very different (apart from UWP)? I think from reading up on your links that CompostitionTarget_rendering would be the best bet (checking now). – Oct 18 '17 at 14:44 •.

Hi again, thanks - really appreciated How To Install Switch On Pfsense. . I'm not sure how to use it though and there are very few examples of Composition..

I have my MainWindow and a canvas in there where the action is. Th MainWindow.xaml.cs calls GameController.cs which takes care of the game logic (like the game loop).

The BoardSetup class's DrawGame() method is then called from the GameLoop() method and redraws the objects on the canvas. So where should I add the event handler?

I try to call it in MainWindow.XAML.cs and in the game loop but the UI hangs on me. – Oct 18 '17 at 15:45 •.

Actually, calling my gameloop from the CompositionTarget.Rendering event does the trick. I have now successfully tried with 30 dynamic objects as well as 300 dynamic objects. The objects are not moving smoothly if I have 300 moving objects, but the time is accurate: I have run the game for four minutes (exactly, and the time is correct to the second (at least - I'm confirming with my cellphone's timer:) ). I will write an article about my game engine within a few weeks hopefully.

If anyone needs my code now, then just PM me or so. – Oct 19 '17 at 16:28.