Skip to main content
GameDev.net gamedev.net

PRO Tired of ads? Read GameDev.net ad-free and help keep the community independent with GameDev Pro — $3/month.

[Ynamar Engine] #6 - Map Editor

[Ynamar Engine] #6 - Map Editor

Zotesso
Zotesso
Ynamar Engine · · 2 min read
1,047 0

Repository: https://github.com/Zotesso/YnamarEngine

As said in my last devlog, I have recently worked on the Map Editor of the Engine, and that took plenty of time. In reality, recording and editing a video about the creation of the Map Editor was the thing that consumed most of my time.
So I would like to share with you:

https://youtu.be/2b9I49p0RVg?si=7mfSyHWH-YVnjIuP

Starting the Editor

Created a whole new project inside the engine: the Engine Editor.
In the future, the Engine Editor will include new features — the Item Editor, NPC Editor, Skills Editor, etc.

After creating the project, I installed the main libraries: MonoGame and Gum.

Added the resource panel — the place where tilesets are displayed and can be selected.

Created the DrawMapGrid function in the Graphics class, which is basically a copy of how the map is rendered for the client, but with grid lines to help the developer.
When you click in the resource panel, a selection box will appear, and when you click on the map, the tile in that position receives the selected tileset’s properties.

On the Server Side

Installed the .NET library for using Web APIs.

Saving the entire map, with all its objects and relationships, would be too heavy for sockets — but not for HTTP.
Created the service and the controller to save the map using protobuf.
Then created the service method and controller method to get the map from the database via HTTP — to use in the Map Editor (and maybe in the client as well, idk yet).

Back on the Map Editor

Included tile events — tiles that can trigger some kind of event, like healing, teleporting the player, or (the one I’ve already implemented) the BlockEvent, to prevent the player from accessing that tile.

Switched to another panel exclusive to events, with acronyms to indicate on the tile if that tile is filled with some type of event.

Future Step:

The next step will probably be continuing the creation of other editors — the Item Editor and the NPC Editor.
Then, I’ll add a tab to include NPCs in the map via the Map Editor.
Besides these editor features, I’ll also try to work on the character creation screen, to give a very customizable experience for the final user to create their own character.

Thank you for reading again, I'll be even more thankful if you could give me some advice to accomplish that journey.

Thanks again,

Zotesso


Discussion

Loading comments...