Page 1 of 2 12 LastLast
Results 1 to 20 of 28

Thread: Resize map

  1. #1
    Juanjo1420's Avatar Foederatus
    Join Date
    Aug 2011
    Location
    On the other side of the Berlin wall
    Posts
    39

    Default Resize map

    I'm pretty sure that this already was answered, but I'm getting mad looking for some place where find what I want. I only want to know how can I resize a campaign map, I just want to cut a part of it.

    Greetings and thanks!

  2. #2

    Default Re: Resize map

    I am also intrigued if this is possible.

  3. #3

    Default Re: Resize map

    The strategy map is generated from several .tga files which can be found in data/world/maps/base. The dimensions of these .tga files correspond to the size of the map. For some of these files (map_regions.tga, map_features.tga, map_trade_routes.tga), the pixels in the image correspond to tiles on the strategy map. These files have maximum dimensions of 510x510. For the other .tga files in that folder, the maximum dimensions are 1021x1021. In these files, groups of 4 pixels correspond to each tile on the strategy map. Therefore, the dimensions of these files must be 2x the dimensions of the smaller files (so that there will be exactly 4x as many pixels). It is not possible to exceed the 510x510 map size dimensions without hacking the game or using a trainer to change the allowed maxima.

    You should use caution when editing these map files. Simply cutting part of a .tga file or resizing it could cause a crash due to conflicts with other files that place objects (settlements, armies, etc.) on tiles which no longer exist. The main offenders in that case would be descr_strat and campaign_script. You also need to remember that it is not sufficient to resize only one of the files in the world/maps/base folder. If you resize map_regions, for example, you must resize all the other .tga files to match your changes.

    Another thing to keep in mind is that, even if your resize doesn't cause a CTD, it may affect the coordinates of things placed on the map in descr_strat and campaign_script. The coordinates on the strategy map always start at 0,0 in the lower left corner of the map. If you reduce the size of the map by removing pixels from the western edge of the map then all of the coordinates will be changed. Likewise, if you try to make a map bigger by adding pixels to the western or southern edges all the coordinates will be changed.

    Once you are done making edits to the files in world/maps/base (including the .txt files in that folder), remember to delete the map.rwm file. This file can be thought of as containing the other files in world/maps/base and it will be regenerated the next time you start a campaign.

  4. #4

    Default Re: Resize map

    Thank you Callistonian, very useful informations! +rep

  5. #5
    Juanjo1420's Avatar Foederatus
    Join Date
    Aug 2011
    Location
    On the other side of the Berlin wall
    Posts
    39

    Default Re: Resize map

    Thank you Callistonian, I'm gonna try it with your tips +rep

    Regards

  6. #6
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: Resize map

    The Geomod tool can do that for you - but unless you are familiar with how the map works (and the map is tool compatible) it's not advisable. The major advantage of the tool is the rewriting of co-ordinates in descr_strat.
    The manual for it describes the steps if memory serves..










  7. #7

    Default Re: Resize map

    Quote Originally Posted by Gigantus View Post
    <a href="https://www.twcenter.net/forums/showthread.php?t=352216" target="_blank"><strong>The Geomod tool</strong></a> can do that for you - but unless you are familiar with how the map works (and the map is tool compatible) it's not advisable. The major advantage of the tool is the rewriting of co-ordinates in descr_strat.<br>
    <a href="https://www.twcenter.net/forums/showthread.php?t=360228" target="_blank"><strong>The manual</strong></a> for it describes the steps if memory serves..
    <br>
    <br>So it 'could' be done with geomod but would take a lot of work? I actually just recently have been messing around with a vanilla map to see if i could make a map that shifts the focus from Europe to Africa... IE by removing all the provinces north of the Pyrenees and adding on a new sub Saharan land mass. I can extend the map southwards as far as i need easily enough but its the decreasing/removing of the more northerly provinces that geomod crashes on me. Maybe its easier just to create a whole new map of North Africa than try and alter the main vanilla map?

  8. #8
    Vladyvid's Avatar Wizard of Turmish
    Join Date
    Aug 2011
    Location
    Athkatla
    Posts
    2,132

    Default Re: Resize map

    Altering or extending the vanilla map, or any map, is not really difficult as its done by modifying graphic files. The problematic part is, if you already have a campaign set up using a smaller map and you want to extend that - all of the coded campaign locations of characters and armies have to be adjusted and its a slow and tedious process.

  9. #9
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: Resize map

    That's where the Geomod tool shines - it rewrites the co-ordinates in the descr_strat file. There is a section in my manual how to proceed.










  10. #10

    Default Re: Resize map

    Ah yeah, i think where i went wrong when trying to remove provinces was i didn't delete the features/resources/characters etc... Hence the geomod crash when i tried to resize. But all good now, i've removed all the necessary regions and have a working mod!

  11. #11
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: Resize map

    Glad you got it working, let us know if there are any other issues.










  12. #12

    Default Re: Resize map

    Hi to all
    To begin with, thanks to you GIGantus for all the tutos.
    I have a problem creating a campaign card, after following your tutorial and doing exactly the same,
    by opening the mod in Geomod it tells me that the map dimensions are too big.
    However the files measure 225*250 pixel. of bases and double +1 for the others.
    Please tell me how to solve this problem.
    Thanks in advance.

  13. #13
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: Resize map

    What is the setting in descr_terrains?
    Please list each map file with it's dimensions.

    Is itr possible that you have co-ordinates in the descr_strta file that are larger then the map dimension, eg larger then 225 and 250 for x and y respectively?
    Last edited by Gigantus; February 25, 2021 at 04:14 AM.










  14. #14

    Default Re: Resize map

    Yes,
    In descr_terrain 225*250

    map_climates : 451*501
    map_regions: 225*250
    map_heights: 451*501
    map_features: 225*250
    map_fog: 451*501
    water_surface: 256*256
    map_trade_routes: 225*250
    map_roughness: 450*500
    map_ground_types: 451*501

  15. #15

    Default Re: Resize map

    map_ground_types : 451* 501

  16. #16
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: Resize map

    The file dimensions are fine. Which editor do you use to edit TXT files?










  17. #17

    Default Re: Resize map

    I use Text document, on my computer desktop,

  18. #18

    Default Re: Resize map

    notepads

  19. #19

    Default Re: Resize map

    it's not even a one pixel error, I checked again

  20. #20

    Default Re: Resize map

    Is there an importance of volume in kb between the cards!
    Looking at the other mods, I saw that some maps have the same volume as others.


    Thanks in advance

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •