How to arrange physics objects and UI Elements

Jul 24, 2011 at 9:47 PM

How can I arrange a UI Element such as a text block to be in front of all the physics objects? I've noticed that the UI Elements are always behind the physics objects.

Jul 25, 2011 at 11:43 AM

Here are a couple of ideas -

- Add the TextBlock in your XAML after your main Game Canvas (the canvas with the PhysicsController Behavior). Since the TextBlock appears after the Canvas in the XAML, it will be rendered on top


- If you absolutely need the TextBlock to be inside the game Canvas, Set the Zindex value of the TextBlock to be greater than the elements in the canvas.