 |
|  |
 |
|
LookANinja
|
|
I have written a small program to facilitate in the creation of user created maps. Basically, what the program does is take input from a loaded bitmap and convert the information in the bitmap directly into a civ3 .bic file which can then be edited in civ3edit.
Some information about using the tool:
1) the bitmap is imported without any coast. This may seem like a pain at first, but once you have loaded the file into civ3edit. Changing any terrain square anywhere on the map will generate all of the coastline for you (call it a feature if you like).
2) The utility now supports terrain types. To change terrain values, use the included Palette file, or the bmp with the different colors and terrain values listed (both these files are included).
3) The bitmap must have the appropriate size for the map size you want to create (map sizes are stored with half the width)so for the maps, the following sizes apply:
*** Updated ***
The New terrain sizes are as follows:
Tiny=60X60
Small=80X80
Standard=100X100
Large=140X140
Huge=180X180
Giga=256x256
I haven't allowed free form sizes yet because I haven't been able to test them in the game, so I don't know if it works or not.
4) Using the program is simple.
-1st make your bitmap using a paint program, the saved bitmap can be any color depth, only the dimensions (see above) are important.
-run the program
-load the bitmap (from the file menu)
-generate the map (again, from the file menu)
-Output is written to the file "BMPToBIC Output.bic" which will be located in the same directory as the program is installed.
*** New features added in release 3 ***
5) You can now load in any .bmp, .bic or .sav file from civ3 and convert it into a map.
6) You can now zoom the view of the map to x2 or x4.
7) You can generate a 3D preview of the map to see what it would like on a globe. A few limitations apply to the 3d preview though, it currently only works in 24 bit color. 32 bit and 16 bit colors come out funny. It uses OpenGL, so if you have Windows 95 without the OpenGL drivers, install them. They are on the Civ3 CD.
8) If a save file is loaded, it is possible to view the different units and cities for each of the civilizations in that save file. You will notice that only the index of the CIV is displayed (i.e. 0 = Barbarians, 1 = Romans, 6 = Russians, etc.). This is because the save file does not store these strings. I plan to display the names in the future though.
9) Also with save files, holding the left mouse button down on a pixel where a unit or city is located will give some info about that city/unit.
I have included a huge (Its now a GIGA - 256x256) .bmp of earth which you can use as a basis to get you started (this image could use some tweaking however, as I noticed that Cuba comes out connected to Mexico, and the Aleutians have altogether disappeared.
This should make it real easy to overcome the limitation of having no small view with civ3edit, and should make it real easy to create super accurate maps of different geographys. If you would like to comment on it, please feel free.
For the next version I hope to address:
I have not implemented these features yet, basically they are pretty tough to figure out, and the results Iwas getting aren't as nice as the way that civ3edit does, hopefully I can come back to these in the future).
Rivers,
Coasts (Hopefully),
Free-form Map sizes
For the next release, I plan on giving you the ability to drag and drop things (units/cities) around in the map (without specifying coordinates like the other programs do. I also want to add additional things like FOW options, resources, etc.
Let me know what you think.
John
Attachment: bmptobic.zip
This has been downloaded 2822 time(s).
Last edited by LookANinja on 08-12-2001 at 05:27
|
|
|  |
 |
|
yumptoo
|
|
Dude, that rocks! Thank you for creating this.
|
|
|  |
 |
|
LookANinja
|
|
Once I figure out the exact procedure that is used to compute the different land features, I will extend the functionality to include this. I have it working partially, but there is still some stuff that needs to be done. Count on there being a specific palette that you will have to use in order to build the different terrain types.
Another thing I am in the process of adding is the ability to get a small map preview of maps that are built with the editor. This seems to be working pretty well. (It pretty much works in reverse of the importing).
As for the different sizes. The limitation appears to be a max of 256x256. Initially I thought there was some significance to the size of the file, but that doesn't seem to be the case, so I may remove the restrictions on bitmap size, but I need to test this further.
I hope to have something ready a bit later this week.
|
|
|  |
 |
|
Plumbean
|
|
madison ohio
Oct 2001 time: 00:16
|
|
Good job keep up the great work
|
|
|  |
 |
|
LookANinja
|
|
I have uploaded a new version of the utility. See the first post for more information. Suffice to say, this new version makes the program much more flexible and hopefully makes it even easier to build new maps.
|
|
|  |
 |
|
|
Hay thanks, but my bic keeps showing up in the civ edit program as a normal unedited water world...
I used your palette. Also when I go to preview it shows nothing but a white screen... I can still load my .bmp map though. Once I convert it seems that the output.bic file didnt get the info...
I am also using Windows 95 so this may be the problem... (Dont know why though). Should the program be installed in the same dir as the Civ3 edit?
I still have my bmp map. Its 180 x 180...
I could send it to you if ya want..
|
|
|  |
 |
|
LookANinja
|
|
Try loading up the file that is included in the .zip, and see if that works. I tested that bitmap, so if it works, then the program should be working ok, and we can try and figure out where you went wrong with your bitmap. As for the preview. I should have noted that it only works with map files that were created with civ3edit, and it will not work if you turn the rules editor on (I suspect that is the reason for the white preview). Turning the rules editor on causes several sections to be added to the file, which my program doesn't know how to interpret yet, but I plan to support this in the future. (save games will also not work).
|
|
|  |
 |
|
LookANinja
|
|
quote: Originally posted by LoD
LookANinja: may I publish this utility on my site ( http://www.civguild.prv.pl )?
Thanks in advance for the reply.
LoD |
I have no problem with that, however if someone experiences problems etc. please refer them here.
|
|
|  |
 |
|
|
quote: Originally posted by LookANinja
Try loading up the file that is included in the .zip, and see if that works. I tested that bitmap, so if it works, then the program should be working ok, and we can try and figure out where you went wrong with your bitmap. As for the preview. I should have noted that it only works with map files that were created with civ3edit, and it will not work if you turn the rules editor on (I suspect that is the reason for the white preview). Turning the rules editor on causes several sections to be added to the file, which my program doesn't know how to interpret yet, but I plan to support this in the future. (save games will also not work). |
Ok tried that, didnt work... Here is what I did step by step using your map...
1. Loaded .bmp file
2. Generated map, got the output.bic file
3. Tried to load it on the civ3edit program, noting but water world with polar caps.
I am using your latest version, with no success... And I am using the correct pallete... Both my map and the one in the zip have the same problems.... D/K I am only using coast and grassland colors, that way when I get into the edit program I can add the other info more accuratly...
NOTE to other users: Have any of you had these problems, or something simular.
|
|
|  |
 |
|
thecrazyroach
|
|
Boston, Massachusetts
Nov 2001 time: 05:16
|
|
no work. ocean and desert only. same pallette. included world map bmp no worky, either.
good program in theory.
|
|
|  |
 |
|
LookANinja
|
|
The only problem is that there are only a limited number of terrain types that are represented in the game. The Palette that is included should accurately reflect the majority of them (at least 90%). So I don't know what additional colors would do (other then duplicating existing terrain).
Now, one thing I want to do is add additional colors to represent things other than terrain types (rivers, etc), however in order to do this, I will need to pick terrain colors from pixels that are near the river, so that I can compute the underlying terrain for the tile that the river is on. For example, if the river runs through an area of grassland, the river tiles should be based on grassland tiles, etc. etc.
Does that help to answer your question?
|
|
|  |
 |
|
LookANinja
|
|
quote: Originally posted by Avahz_D
Ok tried that, didnt work... Here is what I did step by step using your map...
1. Loaded .bmp file
2. Generated map, got the output.bic file
3. Tried to load it on the civ3edit program, noting but water world with polar caps.
I am using your latest version, with no success... And I am using the correct pallete... Both my map and the one in the zip have the same problems.... D/K I am only using coast and grassland colors, that way when I get into the edit program I can add the other info more accuratly...
NOTE to other users: Have any of you had these problems, or something simular. |
I think I found the problem. It works fine on my machine (win2k) when using 16 bit color, however cranking it up to 24 bit color causes problems with some of the palette colors not being recognized and the Map comes out Kevin Costner style (obscure movie reference). I also tested this on a win98 machine with similar results at 32bit color,
Changing to 16bit color seems to fix things (although let me know if it clears things up with regards to the preview), so that should be the workaround until I can get a proper fix posted.
|
|
|  |
 |
|
LookANinja
|
|
quote: Originally posted by OmniGod
it helps... but what I have is my bmp map from CTP2... and in the conversion I'd like to have the ability to use all the terrain types that were in the the original map.. 20 or so I believe... while the terrains aren't made yet for some of them... it would be beneficial to create colours for the future terrain types.
Something else I'd like to know, could you list out the colours and terrain types... while I'm having problems with the colour conversion (running XP with Adobe) I figure I can fix it by knowing which colours represent which without having to do the colour 0,0,0 maps to using the convertor and editor... thanks... |
The colors and there associated terrain type are listed in the file: BMPToBIC Palette.bmp which is included in the .zip. I am about to post a fix for the problems that other users were having, (described above), and one result of this is that you will be able to change the color associated with a specific terrain type in the palette, and that change will affect the type of terrain that gets outputed from your bitmap.
(This is because the program will now load in the BMPToBIC Palette.bmp file, and extract the RGB value for a certain terrain type from the color swatch), that way the program is assured of picking the correct RGB value that is compatible with their display).
This will also make the .pal file in the .zip file obsolete, as you in effect can define your own palette. If you want,
For colors that you are using that are not recognized by the program, I can change the default terrain type from ocean to something else (grassland perhaps?), but since most of the terrain types are covered currently, I would think it would be easier to just floodfill those sections of your bitmap to the terrain color that most closely approximates an existing terrain type. You would also get a better representation that way.
|
|
|  |
 |
|
LookANinja
|
|
I was just thinking, you probably will want these until I can upload the modifications:
RGB(231,223,65); //Desert
RGB(206,166,74); //Plains
RGB(132,142,41); //Grassland
RGB(214,231,231); //Tundra
RGB(239,239,181); //Floodplain
RGB(171,99,33); //Hills
RGB(82,48,16); //Mountains
RGB(80,131,31); //Jungle
RGB(90,121,41); //ForestA
RGB(150,250,150); //Tundra Forest
RGB(61,101,61); //Forest B
RGB(16,121,132); //Coast
RGB(24,158,156); //Sea
RGB(0,65,82); //Ocean
|
|
|  |
 |
|
LookANinja
|
|
quote: Originally posted by Avahz_D
Ok tried that, didnt work... Here is what I did step by step using your map...
1. Loaded .bmp file
2. Generated map, got the output.bic file
3. Tried to load it on the civ3edit program, noting but water world with polar caps.
I am using your latest version, with no success... And I am using the correct pallete... Both my map and the one in the zip have the same problems.... D/K I am only using coast and grassland colors, that way when I get into the edit program I can add the other info more accuratly...
NOTE to other users: Have any of you had these problems, or something simular. |
Allright, I uploaded a (hopefully) corrected version that pulls the precise color data out of the included BMPToBIC Palette.bmp file, instead of the values being predefined in the program. This should eliminate any problems with display compatabilities, I tested it at 256 colors, 16bit, and 24bit, and it worked fine.
However, since I was not able to reproduce the problems you were having with the map preview, that portion may not be fixed. Let me know what kind of results you get.
|
|
|  |
 |
|  |
 |
|
LookANinja
|
|
quote: Originally posted by Slacker
I'm having no joy either. I load the file, convert it, get the output, and load it up...to see a blank map. I'm using an unusual map file, which might be the reason. It's based on a RPG I'm playing in on another forum, if anyone's curious.
Attached is the 256x256 version of the file. If something else is needed, please, tell me. |
Well, right off the bat, I can tell you that the reason that your bitmap is coming in all as water is because you are using the wrong colors in your palette. I converted the image over to the correct palette, and it imported fine. I have included the converted bitmap, and also the outputted .bic file in case you can't get it to work, but give it a shot with the new .bmp
Remember, it is imperative that you use the colors in the provided BMPtoBIC Palette.bmp file if you want the terrain types to be imported properly. Any other colors will automatically get converted into ocean tiles.
Attachment: seasofsteel.zip
This has been downloaded 45 time(s).
|
|
|  |
 |
|
LookANinja
|
|
quote: Originally posted by OmniGod
is it tough to remove the size requirement? The bic seems to stretch horizontally any maps I start off square... and I can't try a 256x128 map convert. |
This is because of how the map data is stored in the .bic there are actually 1/2 as many columns (x positions) as there are rows (y positions). So what the utility does is actually read every other x position (0,2,4) and skips half the data.
Originally, I required that the .bmp be opened in the same size as the map (so for a huge map, the bitmap would be 90x180), but I dropped this requirement because I felt it was easier to work on a bitmap that wasn't skewed so much.
I can tell you that I have played around with freeform map sizes, and haven't noticed any wierd results yet, but I am still not 100% sure that they are a good idea. as I can really see it messing things up with regards to things like Pathfinding AI, Corruption seed values, etc.
|
|
|  |
 |
|  |
All times are GMT. The time now is 05:16. Apolyton Time is 00:16. |
top of page
|
|
|
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
|
|
|
|
|
|