Sign in to follow this  

ModestMapper source and exe

This topic is 3633 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey, I've developed a modest mapping utility that I hope can be of use to those designing a 2D RPG. The source is also included if anyone would like to build on this foundation. ModestMapper is indeed modest, but supports all the basic functions you'll need to get a 2D map quickly and easily into a binary format. Tiles of any size are supported, as well as options to account for any offsets or padding in the tilemap itself. Unfortunately, right now only .bmp is supported. SDL is used for the map viewport to ensure smooth scrolling. Win32 controls are used for the GUI. Maps are outputted in a simple compact binary format. Instructions are included with the download. I'll be using this for my upcoming project, and I hope others may find it useful. Download here.

Share this post


Link to post
Share on other sites
Looks like a nice start. It still lacks some, in my opinion, important tools, and it's not very polished - it even crashes when you paint outside the map area - but those issues can be worked out.

Just out of interest, how long did it cost you to create this editor?

Share this post


Link to post
Share on other sites
Hey, thanks for the feedback. The editor took about a month of on and off again programming total. I realize that there are other tools such as Mappy out there, but I went into this as a learning experience. Building a tool, or a complete Win32 application for that matter, is something I had yet to do.

As far as practical time savings, I know I could be pretty far along into an actual game if I had done otherwise, and any game I do make will likely not contain a large amount of content. Still, I think I've learned a great deal (especially about Win32, and secondly, about the choices I made for the user interface). Were I to do it again, I'd approach the map creation process with a wizard-style set of menus, instead of the weird smattering of dialogs.

As far as missing features, I know there's a lot of room for improvement. A minimap or zoom feature for one, support for more image types, and an undo/redo system would be helpful. I could go about implementing all of that, but I'm not sure how far I want to take it. For my purposes, I consider it sufficient.

As someone trying to break into game development, I'm approaching this from the perspective of what puts me further in that direction. If you have any advice on what direction I should take, please let me know. Also, if I missed any of the features you were thinking of, what were they?

P.S., the OOB error is something I thought I'd checked for, I'll have to take another look at that.

Thanks.

Share this post


Link to post
Share on other sites
Quote:
Original post by Zeugmal
Hey, thanks for the feedback. The editor took about a month of on and off again programming total. I realize that there are other tools such as Mappy out there, but I went into this as a learning experience. Building a tool, or a complete Win32 application for that matter, is something I had yet to do.

It's quite nice for a first tool. I'm not sure how relevant Win32 experience is these days, I haven't found the need to use it in years now, but I guess it's always good to know a bit about how it works. A month is quite some time, though. Perhaps you should look into Python and Pygame, perhaps combined with a GUI library such as wxPython. I've just built a tool a few days ago that accepts an image, checks it for unique tiles and outputs these as either separate images or a tileset image, and optionally compresses their filesize. Took me 2 hours. Of course, the grunt work is done by Python Imaging Library and PngOptimizerCL, but does it matter that I didn't write all of that myself? It works for me... :)

Quote:
As far as missing features, I know there's a lot of room for improvement. A minimap or zoom feature for one, support for more image types, and an undo/redo system would be helpful. I could go about implementing all of that, but I'm not sure how far I want to take it. For my purposes, I consider it sufficient.

That's a wise attitude. A tool should save you time on the long run. Though there's another important aspect: a good tool allows a designer to build better levels, because he can focus on the design, rather than the tedious technical details. An undo/redo option makes it easy and convenient to make small changes, because if they turn out wrong, they can be reverted quickly. Without that, a designer feels less comfortable tweaking his levels because he has to remember how to revert the changes.

Quote:
As someone trying to break into game development, I'm approaching this from the perspective of what puts me further in that direction. If you have any advice on what direction I should take, please let me know. Also, if I missed any of the features you were thinking of, what were they?

If you're into game-development, build some games. Tools are fine and usefull, but once you've built a few games, you'll get a better idea about what tools you could really put to good use. I'm working on a few Flash games and while doing so, I've found myself repeating several tedious tasks. I've written scripts to automate these tasks, to save myself some time and to prevent human mistakes. I've also written various in-game editors, both for myself and for players. Those were relatively easy since I had a lot of code already in place, the editors are essentially levels with different controls and interfaces, and import/export capabilities.

As for features, I've created levels for Half-Life and various other games for about 7 years, so I think I know a bit about what a good editor needs. In particular, I missed the following things:
  • Persistent tileset data: don't ask me every time I start a new level, remember it for me, I'll select a new tileset when I want to. In general, any option that doesn't change frequently should be stored somewhere, don't bother the designer with it each time. He'll change it when he needs to.
  • Smooth scrolling, and perhaps scrollbars for the map: the current movement is too abrupt. A level-designer can spend a lot of time looking around his levels to get inspiration, or to get an idea of how the level flows, or whatever. It's just important. ;)
  • Better tileset display. Currently, only 4 or 5 tiles are visible at the same time. Less space between them, and more tiles on a row should reduce tile search times and at the same time, give the designer a better view of what tiles he has at his disposal, increasing inspiration.
  • Selecting multiple tiles and copy-pasting them. Usefull for levels with repeating elements that consist of multiple tiles, such as your trees.
  • Undo/redo of course!
  • Hotkeys for common actions. Granted, currently there aren't many special actions available, but it's something to keep in mind for later.
  • Less popup boxes. Yes, I'm sure I want to fill the whole map, don't interrupt me please. If I accidentally performed that action, I can always undo it. And while it's good that the program asks me if I want to save my work before starting a new map, it doesn't have to do that if there are no unsaved changes. Warnings in critical cases are good, but they're easily overdone, which is distracting.


Quote:
P.S., the OOB error is something I thought I'd checked for, I'll have to take another look at that.

I created a 20x20 map, moved a bit up and to the left, and clicked there. That should probably result in negative indices. You may want to restrict movement to the map area only, as it's unclear where that area actually ends.

Oh, and I quickly skimmed through your code. You don't seem to know about std::vector. I'd recommend reading up on it and using it instead of arrays or dynamic arrays. It'll make your life easier. Well, at least the programming part of it. :)

Share this post


Link to post
Share on other sites
Thanks again Captain P for the great information. I'll have to check into Python and Pygame, I've heard a lot of good things about them.

As for the OOB error, I was checking for positive bounds, and indeed going to the left causes an index into a negative number.

Share this post


Link to post
Share on other sites

This topic is 3633 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this