Matrix Games Forums

Forums  Register  Login  Photo Gallery  Member List  Search  Calendars  FAQ 

My Profile  Inbox  Address Book  My Subscription  My Forums  Log Out

RE: MAPGEN (A WITP:AE Map Dumper/Repacker)

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
  Printable Version
All Forums >> [New Releases from Matrix Games] >> War in the Pacific: Admiral's Edition >> Scenario Design and Modding >> RE: MAPGEN (A WITP:AE Map Dumper/Repacker) Page: <<   < prev  1 [2]
Login
Message << Older Topic   Newer Topic >>
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/21/2017 9:45:31 AM   
Dili

 

Posts: 3705
Joined: 9/10/2004
Status: offline
I feel young again!

(in reply to RyanCrierie)
Post #: 31
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/22/2017 1:45:02 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
2.3.20 Stacking Limit (Byte 49) in the latest PWHEXE.DAT is currently set to 00 = Unlimited for the whole map.

_____________________________


(in reply to Dili)
Post #: 32
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/22/2017 1:53:34 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
Sub Map has been completely dumped.




Attachment (1)

_____________________________


(in reply to RyanCrierie)
Post #: 33
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/22/2017 1:54:10 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
Entry Zones as well:




Attachment (1)

_____________________________


(in reply to RyanCrierie)
Post #: 34
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/22/2017 8:11:09 PM   
Dili

 

Posts: 3705
Joined: 9/10/2004
Status: offline

quote:

ORIGINAL: RyanCrierie

quote:

1: If i make a map of the size of WITP map the coordinates will respect the WITP coordinates numbers?


It should. AFAIK, there's only one WITP:AE map size; and making maps bigger or smaller is done through the scenario file setting XLOC and YLOC; it's how the "War in the West" European Map was done.

quote:

My issue is that i already have given the coordinates to the locations and units so it is not viable to change them even if it is just one hex to the side.


I highly advise you not do any real changes right now using MAPGEN; I still need to:

1.) Refactor the hexside dump/repack routines to work in Python 3+ and with the new "paste blitted image" engine used now for speed.

2.) Check on the Repacker routines for them all.

3.) Develop a Map Legend Feature -- when a map is dumped, create a legend file; e.g for:

WITPAE_DUMP_HEXTYPES.PNG,

the following file would get created:

WITPAE_DUMP_HEXTYPES_LEGEND.PNG

which would have an example hex and a legend next to that example hex; so that you know what color does what, rather than guessing (Important on the oddball maps)

4.) Find the right mix of colors for the Terrain Type Map. There's a lot of terrain types to cover and I want to find the right mix of colors that are distinct from each other yet suggestive of the type of terrain there.

5.) Make a map splitter mode (Optional) to split the map into 41 different images that align with the WPEHxx.bmp and WPENxx.bmp graphics files in /ART.

quote:

2: What initial quality the image should have, is Google Maps image for reference good enough to recognize the features? I guess no issue between land vs and sea vs desert vs green. But what about mountains with forest? The idea is to edit the map to ease the application work. Not as the final graphic map.


Well, google maps/earth satellite should be good enough to tell what type of terrain it is. Biggest issue you (or anyone) will face is correctly resizing the image so that it's accurate to the hex scale of the dumped map.




Thanks i'll follow your advice like i said i want to do a Mediterranean map.
If you want any help, anything specific to test just ask.

(in reply to RyanCrierie)
Post #: 35
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/22/2017 10:10:02 PM   
cardas

 

Posts: 117
Joined: 4/8/2016
Status: offline
quote:

2.3.20 Stacking Limit (Byte 49) in the latest PWHEXE.DAT is currently set to 00 = Unlimited for the whole map.


Check the (reasonably commonly used) extended map with stacking limits from DBB:
https://sites.google.com/site/dababeswitpae/

(in reply to RyanCrierie)
Post #: 36
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/23/2017 2:02:18 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
Here's the Stack Limit from DBB with the old system.




I'm working on a new system to dynamically generate colors for these specific issues where you can have up to 200 color combinations.

Attachment (1)

< Message edited by RyanCrierie -- 3/23/2017 2:33:18 AM >


_____________________________


(in reply to cardas)
Post #: 37
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/23/2017 2:16:13 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
Here's the dynamically generated DBB Extended Map Stack Limits:

I need to work a bit on it to make it clearer; perhaps make stack limits:

x01 to 1/2 way thru: Red
1/2 way thru to FF: Blue




Attachment (1)

_____________________________


(in reply to RyanCrierie)
Post #: 38
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/23/2017 2:32:46 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
Alternate method to show stacked stuff, given that DBB only has 35~ separate values for stacking.




Attachment (1)

_____________________________


(in reply to RyanCrierie)
Post #: 39
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/23/2017 6:16:28 AM   
Gary Childress

 

Posts: 6549
Joined: 7/17/2005
From: The Divided Nations of Earth
Status: offline
All hail RyanCrierie!

Seriously awesome work!



_____________________________

Favorite/Awesome games from Matrix

War in the Pacific/AE
Panzer Corps
Commander Europe at War
Advanced Tactics Gold


(in reply to RyanCrierie)
Post #: 40
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/23/2017 3:05:23 PM   
chemkid


Posts: 1142
Joined: 12/15/2012
From: Monday Till Sunday
Status: offline

quote:

ORIGINAL: Gary Childress

All hail RyanCrierie!

Seriously awesome work!



+1!! absolutely love this project - makes me wonder what could be done with the game and what future
mapmods/scenarios could look like... man, wish i had the time for another map...

yo, alternatewars-man! good stuff! please continue to rock!!

cheers!
chem!

(in reply to Gary Childress)
Post #: 41
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/25/2017 2:57:26 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
quote:

ORIGINAL: cardas

I'm not looking forward to editing such a large bitmap either. I got a much newer laptop that is my "main" computer, however I generally do all my graphic stuff on a 10+ year old desktop with 2 GB RAM (and a CRT screen... yeah). From personal experience I can say that it's possible to edit such a large bitmap regardless if you are patient though


Problem Solved. Problem staying solved.



WITP Mapfile 10: Hex Type

Just coded an automatic split:

Do you want to split the map according to 'canonical' WITP:AE Map Splits? Y/N?

It'll split it according to the numbering for the official WITP:AE mapfiles; and at the same split points.

Attachment (1)

< Message edited by RyanCrierie -- 3/25/2017 2:59:44 AM >


_____________________________


(in reply to cardas)
Post #: 42
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/25/2017 2:58:46 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
BTW, out of curiosity, what's everyone's screen resolution? Is it at least above 1500 x 1500 pixels these days?

_____________________________


(in reply to RyanCrierie)
Post #: 43
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/25/2017 3:12:18 AM   
Gary Childress

 

Posts: 6549
Joined: 7/17/2005
From: The Divided Nations of Earth
Status: offline

quote:

ORIGINAL: RyanCrierie

BTW, out of curiosity, what's everyone's screen resolution? Is it at least above 1500 x 1500 pixels these days?


I believe mine is 1920 x 1080. But I'm not very computer hardware savvy.

_____________________________

Favorite/Awesome games from Matrix

War in the Pacific/AE
Panzer Corps
Commander Europe at War
Advanced Tactics Gold


(in reply to RyanCrierie)
Post #: 44
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/25/2017 7:15:15 AM   
Gary Childress

 

Posts: 6549
Joined: 7/17/2005
From: The Divided Nations of Earth
Status: offline
Hi Ryan,

How does MAPGEN work? My guess is that I run a python script for each map aspect (terrain type, roads, weather zones, etc.) which will dump the PWHEX data to a PNG file with the types of hexes color coded. From there I change around the colors of the hexes as desired, using the respective pre-set colors for each hex type to create whatever map layout I want for the PWHEX file. Then I repack the PNG image back into the PWHEX file where the program will read the various colors as corresponding hex types for the PWHEX file and alter the PWHEX file accordingly? Is that generally how it works? I'm a little lost right now.

Thanks for any help! And thank you for creating this!

_____________________________

Favorite/Awesome games from Matrix

War in the Pacific/AE
Panzer Corps
Commander Europe at War
Advanced Tactics Gold


(in reply to Gary Childress)
Post #: 45
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/27/2017 6:23:07 AM   
Dili

 

Posts: 3705
Joined: 9/10/2004
Status: offline
I have 1920x1080 which is the FullHD norm, and that is tendency anywhere even more in expensive ones. There are still many 15" laptops with 1366x768, but even with a cheap external monitor can go bigger i think.

< Message edited by Dili -- 3/27/2017 6:29:00 AM >

(in reply to Gary Childress)
Post #: 46
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/29/2017 1:12:06 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
Here's a v1 BETA.

It can only dump, but it dumps everything, and has a "split map file" option to split them along stock WITP:AE map file lines, for those of you with weaker computers.

http://alternatewars.com/Games/WITP_AE/MAPGEN/MAPGEN_V1_Beta.zip

Some notes:

The following folders must exist in the directory that MAPGEN_DUMP.EXE is run from for the program to function correctly:

\GFX with 45 files. These are the graphics documents used to paste/blit the map file image internally to allow this Python 3.4 version to somewhat recover the speed lost over the Python 2.x version following the version change. (the upgrade was necessary in order to make it into a stand alone executable that can be run on computers without python installed).

\DUMP. This is the folder that the program dumps stuff into.

You must have pwhexe.dat within the same folder as MAPGEN_DUMP.EXE or else it'll error out.

Memory Requirements About 400~ MB.

----------

CHANGES TO BE DONE BY NEXT VERSION:

Amphibious Zone
Stack Limit
Weather Zone

all use sort of really light/bright green colors; I'm changing them in future releases to be dark green like Malaria Zone since I don't want to burn out my eyeballs, so be warned when editing those files.

BETTER DOCUMENTATION:

Right now "Manual_MAPGEN.htm" in /Docs is kind of a barebones guide to offsets and variables in PWHEXE.dat. I need to populate it with colors and such; to better help you guys edit the map(s).

< Message edited by RyanCrierie -- 3/29/2017 1:16:22 AM >


_____________________________


(in reply to Dili)
Post #: 47
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/29/2017 1:26:31 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
Things of note that have occurred to me:

It's now possible, with the development of this codebase to alter the in-game split maps seamlessly. For example, if you wanted to know on-map where every narrow or wide strait was, it could be programmed to do this for you automatically.

Or overlaying red over every malarial zone hex, instead of having to rely on the jump map, etc.

_____________________________


(in reply to RyanCrierie)
Post #: 48
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/29/2017 1:39:46 AM   
RyanCrierie


Posts: 1221
Joined: 10/14/2005
Status: offline
quote:

ORIGINAL: Gary Childress

Hi Ryan,

How does MAPGEN work? My guess is that I run a python script for each map aspect (terrain type, roads, weather zones, etc.) which will dump the PWHEX data to a PNG file with the types of hexes color coded. From there I change around the colors of the hexes as desired, using the respective pre-set colors for each hex type to create whatever map layout I want for the PWHEX file. Then I repack the PNG image back into the PWHEX file where the program will read the various colors as corresponding hex types for the PWHEX file and alter the PWHEX file accordingly? Is that generally how it works? I'm a little lost right now.


Gary, that's pretty much exactly how it works; only with this release, I've made a single 8 MB binary using PyInstaller which creates a bundled self contained portable version of python so that you don't need to have or install python on your computer to run the scripts.

Currently, it's a binary dump everything or not operation; but with more time, I can add a option menu:

Dump
A.) Hex-Side Rivers
...
G:) Dump Everything.


< Message edited by RyanCrierie -- 3/29/2017 1:40:07 AM >


_____________________________


(in reply to Gary Childress)
Post #: 49
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/29/2017 2:21:46 AM   
Gary Childress

 

Posts: 6549
Joined: 7/17/2005
From: The Divided Nations of Earth
Status: offline

quote:

ORIGINAL: RyanCrierie

quote:

ORIGINAL: Gary Childress

Hi Ryan,

How does MAPGEN work? My guess is that I run a python script for each map aspect (terrain type, roads, weather zones, etc.) which will dump the PWHEX data to a PNG file with the types of hexes color coded. From there I change around the colors of the hexes as desired, using the respective pre-set colors for each hex type to create whatever map layout I want for the PWHEX file. Then I repack the PNG image back into the PWHEX file where the program will read the various colors as corresponding hex types for the PWHEX file and alter the PWHEX file accordingly? Is that generally how it works? I'm a little lost right now.


Gary, that's pretty much exactly how it works; only with this release, I've made a single 8 MB binary using PyInstaller which creates a bundled self contained portable version of python so that you don't need to have or install python on your computer to run the scripts.

Currently, it's a binary dump everything or not operation; but with more time, I can add a option menu:

Dump
A.) Hex-Side Rivers
...
G:) Dump Everything.



Fantastic! This will revolutionize map modding for AE! I take it that this BETA doesn't yet have the repack ability?

_____________________________

Favorite/Awesome games from Matrix

War in the Pacific/AE
Panzer Corps
Commander Europe at War
Advanced Tactics Gold


(in reply to RyanCrierie)
Post #: 50
RE: MAPGEN (A WITP:AE Map Dumper/Repacker) - 3/29/2017 2:40:20 AM   
Gary Childress

 

Posts: 6549
Joined: 7/17/2005
From: The Divided Nations of Earth
Status: offline
Just used the new BETA v1. It seems to be working great. I did a dump using the split feature and the only quirk I see so far is that the first 6 panels of the "Hex type" dump are separated from the rest of the files for that particular aspect by the absence of an underscore "_" in the file names.

_____________________________

Favorite/Awesome games from Matrix

War in the Pacific/AE
Panzer Corps
Commander Europe at War
Advanced Tactics Gold


(in reply to Gary Childress)
Post #: 51
Page:   <<   < prev  1 [2]
All Forums >> [New Releases from Matrix Games] >> War in the Pacific: Admiral's Edition >> Scenario Design and Modding >> RE: MAPGEN (A WITP:AE Map Dumper/Repacker) Page: <<   < prev  1 [2]
Jump to:





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts


Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI

0.189