.com.unity Forums

.com.unity Forums (http://forum.shrapnelgames.com/index.php)
-   Scenarios, Maps and Mods (http://forum.shrapnelgames.com/forumdisplay.php?f=146)
-   -   Idiot's Guide to Making Custom Maps? (http://forum.shrapnelgames.com/showthread.php?t=35875)

Zylithan August 25th, 2007 05:48 PM

Idiot\'s Guide to Making Custom Maps?
 
Short Version:
Is there such a thing? I can't find one on the forums or the docs coming with the game...

Longer Version:
Apologies for my ignorance.. I am trying to learn how to make some custom maps for Dom3. I'm a noob to playing, and even worse at making maps. I looked through the stickies and forums, and can't find an Idiot's guide. I made some pretty map pictures, and I drew lines on them, and I put white dots in the middle of each province, then I load them into the map editor. And it usually recognizes all the provinces I marked with dots. But there is no or little neighbor connectivity. From the game docs, I gather I could use text editor to fix all of this - but I like GUIs and this seems slow. Is there any way using the map editor? It seems like right and left clicking on the flags help me make neighbors, but they always seem to get erased when I move on to do other provinces. If anyone could help I promise to try to make it worthwhile by making some maps...
If I missed something obvious, apologies!

Thanks!

Gandalf Parker August 25th, 2007 06:41 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
In the map editor :
Left-click will make a neighbor.
Ctrl-click wilol remove a neighbor.
Right-click will shift your attention to another province.

Moving to another province shows its neighbors only. If you move back to one you already did then you will see that it has remembered the neighbors you gave it.

I recommend that you save often.

Gandalf Parker

Zylithan August 25th, 2007 08:26 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
Hrm. I think I'm missing something. This is sort of what I assumed, but if I click on a province, select some neighbors by left clicking, and then right click on another province, then come back to the first (by right clicking again) it seems to not display the neighbors I assigned. Does it remember them, but not display them? Do I need to click something at left side (besides "save")?

Also, I notice when I open up the map to play on it, I notice two things. One is that the white dots I made still appear on the map, which is not ideal. This is probably because I put the white dots in my .tga file? If I don't do this, the editor doesn't find any provinces. Is there a way to do this so I don't get white dots on my maps?
Second, when I click on a place on the map (in game mode) sometimes it highlights the wrong province (not the one I click on). I think this is because it chooses the one closest to the white dot I made - I have not defined boundaries. How do I properly define boundaries.

Thanks very much!

Gandalf Parker August 25th, 2007 09:10 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
The white dots are the important thing. The dots should only be one pixel big. Thats the tiniest size possible. One touch of the thinnest pencil.

If you made the dots using the dot tool (a filled-in circle) then that would cause the problems you are talking about. When you click on the province, its jumping to a different pixel than the one you clicked on before.

When I actually WANTED the dots to be apparent, I used a single white dot and surrounded it with light yellow ones. That way it seemed like a bigger dot but still only had one of the total white (255,255,255) color for the game to target on

Ballbarian August 26th, 2007 12:02 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
Zylithan,
I just got your pm. Looks like Gandalf has answered your questions. The 255,255,255 that he is talking about is what is known as an RGB value (255 red, 255 green, 255, blue) with valid values being any number between 0 and 255. Your graphics program should allow you to see & change these values when selecting a paint color. As he has already pointed out, each province location is defined by the location of a single white pixel. If the white dot is made up of multiple white pixels, you will get multiple provinces clumped together which will cause the behavior that you are describing.

Assigning neighbors in the map editor can be a tedious process, but like anything worth doing, it can be done one step at a time. I always start in a corner and work progressively through sections and rows in as organized a manner as possible. Try to avoid skipping around randomly or else it will quickly get frustrating as you lose track of which neighbors have been set, and which have not.

Also, as Gandalf has pointed out, save often.

In case you haven't found it, there is a file called "mapedit.pdf" in your dominions3\doc folder. If you can't find it on your hard drive, then try searching your dominions3 cd. (I don't remember if it is automatically installed, or if you have to copy it from the disk like it was in dom2.)

Zylithan August 26th, 2007 12:08 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
Aha! I was using GIMP, but the opacity was dependant upon how long I held down my click, so my single dots were not 255,255,255 because of not having 100% opacity... that's why I went to bigger dots. Thanks for the advice. I think I'll probably have more questions in the future, but maybe I'm good for now? Two quick questions...

1. How does the map editor detect borders?
2. Is it going to be a problem if I make snowy maps, because there can't be any other 255,255,255 pixels?

Thanks!

Zylithan August 26th, 2007 12:10 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
Ballbarin - thanks for your comments, I didn't see them before my last post. I did see the mapedit.pdf, but that seems to start out by assuming you already have a working image. I wasn't to that part yet http://forum.shrapnelgames.com/images/smilies/happy.gif

Thanks!

Ballbarian August 26th, 2007 12:21 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
1. I believe it is a combination of proximity and if I remember correctly, it looks for red pixels (red province borders). I will sometimes start with solid red province borders to give the map editor a chance to auto detect neighbors, but I often end up clearing it and doing it manually anyhow. (You can always change the border colors later in gimp by using the "select by color" tools.

2. You should have no problem making snowy maps. Just be sure to not use pure white. For example, try using a color like 255/255/245. It is still white, just not pure white. http://forum.shrapnelgames.com/images/smilies/wink.gif

It is often useful to use gimp to select all white pixels on your image before placing your province pixels and if any are found, just change all of them to some subtle variation of white.

RamsHead August 26th, 2007 12:27 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
1. How does the map editor detect borders?

It doesn't. The little white dots are what it detects. If you connect two white dots in the editor, then they theoretically border each other (though you could make teleporting provinces). Borders are just drawn on for appearance.

2. Is it going to be a problem if I make snowy maps, because there can't be any other 255, 255, 255 pixels.

Just make your snow 245, 245, 245. It would still be white but shouldn't be identified as a province.


Ignore my first paragraph.

RamsHead August 26th, 2007 12:30 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
Quote:

Ballbarian said:
1. I believe it is a combination of proximity and if I remember correctly, it looks for red pixels (red province borders). I will sometimes start with solid red province borders to give the map editor a chance to auto detect neighbors, but I often end up clearing it and doing it manually anyhow. (You can always change the border colors later in gimp by using the "select by color" tools.

Hmm, I didn't know that it actually made borders. Still, drawing them gives you better control over what you want I would assume.

Ballbarian August 26th, 2007 12:42 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
It does not draw borders but it does detect red pixels in an effort to guess neighbors (or it did in dom2 and I am pretty sure it does in dom3).

I gave a lot of thought to this when I was working on my own custom map editor. If you draw an imaginary line between two points (provinces) and check each pixel's color along that line and set a flag when you hit a border (red) pixel, then skip ahead a few pixels (to clear a border that might be several pixels wide at that point) and if you reach the 2nd point without hitting another set of red border pixels, then you can say that it is likely for the 2 points to be neighbors. This is not 100% foolproof, but it can generate a fair guesstimate. http://forum.shrapnelgames.com/images/smilies/happy.gif

Gandalf Parker August 26th, 2007 01:02 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
Johan has says that red borders help the game detect province boundaries. Its not a necessity but it helps. Ive used red+blue for water borders and red+green for land borders. But just before distribution I like to hit them both with a good dose of transparency.

Zylithan August 27th, 2007 01:30 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
Alright, I'm back with more stupid questions/ better clarification of an old question.

I can make a map now, and assign neighbors. But when I play the map, if I right click on a province, sometimes it selects a different province - especially for unusually shaped provinces. There has to be some way for me to define the geometric boundaries of the provinces. I attached a simple map, as a .bmp ( normally I use .tga)
Depending on where I click in province 5 (as determined by visual red lines) in game, sometimes the computer decides I want info about 5, but often also 1,2,3,4,6. It chooses whichever white dot I am closest to I think. How can I tell it to identify the red lines with the geometrical outline of my provinces?

Thanks!

Edi August 27th, 2007 02:54 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
Every white pixel is a separate province. So if you have for example two white pixels next to each other, both will be provinces and will act accordingly, which may be part of your problem.

If this is not the case, then you need to right-click as close to the province flag as possible to select it.

Gandalf Parker August 27th, 2007 10:25 AM

Re: Idiot\'s Guide to Making Custom Maps?
 
The game doesnt actually recognize the boundaries as far as in-game clicking. Only the dots.

If your map is playing too small for comfort then you might want to change the defaultzoom in the .map file

Zylithan August 27th, 2007 02:04 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
I only have single pixel white dots now.

My problem is that when I click (in game) in a space that looks like part of one province, the computer selects a different province. Now, if I click right on the flag, I always get the correct province. But for long or irregularly shaped provinces (see my attachment) this is a problem.

Now, maybe this is how the game is... where you click on the overland map, it just selects the closest white dot. But I have never had this problem when playing a map I did not make personally. Then again, most provinces are roughly spherical in the maps I have played. So maybe this will be a problem on any map with dramatically nonspherical provinces. (This is my conclusion based on what Gandalf said above.)

The image I attached isnt meant to be a real map, of course, but it is a tool for explaining my problem, and for me learning the system.

Thanks!

Ballbarian August 27th, 2007 02:31 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
The attachment is not working for me.
404 file not found... attachments broken again?

lch August 27th, 2007 02:32 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
You haven't attached anything anywhere, from how I see it. The game counts mouseclicks towards the next nearest white dot, and depending on the shape of your provinces and placement of those white dot "centers", that might not be what you had in mind.

Zylithan August 27th, 2007 03:08 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
Ballbarin - it says 7 people downloaded the attachment about 6 posts up from here. Maybe they all failed? I don't know. Maybe I can PM it to you if you are interested?

Ich - What do you mean " counts mouseclicks towards the next nearest white dot"

Ballbarian August 27th, 2007 03:20 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
Download counts don't matter. 3 of those are me trying the link and getting a 404.

I think what Ich means is that wherever you click, the game selects the closest province marker to that point and that becomes the selected province.

The game does not know, nor care about the shape of the province or it's borders. All it cares about is the almighty white dot. http://forum.shrapnelgames.com/images/smilies/happy.gif

So imagine that "1" is a province that circles province "2".

111
121
111

If 1's white dot is located in the top center spot and I click on the bottom center spot, then province 2 is going to be selected, not 1.

Hope that helps to clear things up.

Zylithan August 27th, 2007 03:25 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
Ballbarin - yeah, that clears it up. That was sorrt of what I was worried was the truth. I was hoping there was some way for me to define boundaries for the map, so if I clicked anywhere in province 1, it would go to 1 in your above example, not province 2.

But I guess this is not possible. sad face. thanks for confirming that. I guess I have to limit my gerrymander provinces, or be okay with this issue happening.

thanks!

Gandalf Parker August 27th, 2007 04:19 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
Apparently red borders helps, but not much. It just wasnt efficient to put alot of "thinking code" into trying to figure out how much of a province is inside of a really crazy boundary. I think its one of the reasons we have the flags (which I mostly find irritating)

Zylithan August 27th, 2007 04:24 PM

Re: Idiot\'s Guide to Making Custom Maps?
 
Yeah, my test map has big solid red lines, but they didnt help really. I suppose its not supported in the current map format, but it would be a nice feature to allow us to map (x,y) coordinates of the picture on to provinces. Like, default could be just find the nearest white dot (wahtever it normally does), but maybe if I could define (by x,y pixels or something) boundaries.... it's probably too much work to code this, but it would be nice. If the mapmaker could autodetect red lines (like 255,0,0) and use those it would be super-neat.

But... you make maps with the mapmaking tools you have, not the mapmaking tools you wished you had.


All times are GMT -4. The time now is 09:25 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.