Launch XNA Tile Editor

I am writing a tile editor for a game and would like to be able to choose which level file to open. After opening, I would load the level into the XNA window and click to add / remove tiles to the level. When editing is complete, I will save the file layout back to the original file.

Currently, I see no way to integrate window shapes and XNA. Is it possible?

+4
source share
2 answers

When I was working on the small isometric game ā€œ2.5Dā€ in XNA, I found it necessary to have a separate version of WinForms that would simply display 2D from top to bottom using GDI. This was due to my inexperience with XNA and my (relative) comfort with WinForms.

This approach also had a useful side effect to ensure the separation between logic and rendering code. This made it easy (at least for me) to check the changes without worrying about how to handle the aspects of XNA rendering.

This may not be exactly what you had in mind, but it might be something to consider.

+2
source

WinForms and Xna can work together, but it is not recommended to use the Xna built-in in the Game class with WinFroms. There are two samples demonstrating this:

http://xbox.create.msdn.com/en-US/education/catalog/sample/winforms_series_1 http://xbox.create.msdn.com/en-US/education/catalog/sample/winforms_series_2

0
source

Source: https://habr.com/ru/post/1338195/


All Articles