Dims mapper troubleshooting

Discussion in 'Fallout General Modding' started by kokeeby, Oct 3, 2021.

  1. kokeeby

    kokeeby First time out of the vault

    46
    Jul 4, 2019
    I'm trying to use Dims mapper from https://github.com/FakelsHub/F2_Mapper_Dims. It works fine for vanilla F2, but I'm having difficulties with F2RP (killap's 2014 version). I can load every map except for 4 (EASTER, EPAMAIN1, EPAMAIN2, epax).

    EASTER - bad string in critters.lst error
    EPAMAIN1 - access violation error during proto files loading
    EPAMAIN2 - access violation error during tileset files loading
    epax - list index out of bounds during frm loading (7856)

    The setup I'm using is I copied the F2\master.dat, F2\critter.dat files and F2\data folder into my DimsF2 folder. Is anybody familiar with Dims and knows how to fix it? I'm paging @Mr.Stalin since it's his repo, but feel free to chime in.


    Edit: Now I noticed, that Dims creates a .log file. I'll have to look into this further.
     
    Last edited: Oct 3, 2021
  2. Lexx

    Lexx Testament to the ghoul lifespan
    Moderator Modder

    Apr 24, 2005
    Dims mapper is old and unsupported. You should just go with the BIS mapper - that one at least works.
     
  3. kokeeby

    kokeeby First time out of the vault

    46
    Jul 4, 2019
    yeah, probably some bug with the mapper itself. Wanted to check it, but it's Borland C++.
     
  4. Mr.Stalin

    Mr.Stalin Mildly Dipped

    529
    Oct 29, 2015
    I do not fix bugs in Dims mapper, it has not entered the release stage for all its 350 years. :boy:
     
  5. Radegast

    Radegast First time out of the vault

    12
    Jan 14, 2013
    I am working on a new map editor and I am using Dims Mapper's source code as a reference.

    The issue with easter.map was in how critters.lst is parsed. The Restoration Project added several new FRMs without comma-separated indexes to this file.

    If anyone wants to give it a try here is a fixed version of the mapper which successfully loads easter.map: https://github.com/JanSimek/F2_Mapper_Dims/releases/tag/v.0.99.4-pre1

    The issue with epax.map is a bit more puzzling. The problem lies only in the roof tiles of the main EPA building. These roof tiles refer to indexes in tiles.lst that are way too high - something like 7xxx while tiles.lst has only 3xxx lines. I will try to get BIS Mapper working and see if I can figure out which FRMs are used for the EPA roof.

    When all the fixes are tested I will submit a push request to Mr. Stalin's repository if he is interested. If not I will keep them in my separate fork.
     
    • [Rad] [Rad] x 5
  6. Lexx

    Lexx Testament to the ghoul lifespan
    Moderator Modder

    Apr 24, 2005
    You sure it's not using the art FID number? Those don't necessarily line up with the proto files.
     
  7. Radegast

    Radegast First time out of the vault

    12
    Jan 14, 2013
    You aren't talking about the tile issue, are you? Because tile IDs directly correspond to line indexes in tiles.lst and there is no other logic for them (as far as I can tell). The other bug in easter.map was not in getting the FRM ID but how the critters.lst file was parsed.

    I got the BIS Mapper running and surprise, surprise, the main EPA building roof tiles aren't shown there either (roofs of the other two buildings display fine).

     
  8. Mr.Stalin

    Mr.Stalin Mildly Dipped

    529
    Oct 29, 2015
    :mrgreen:
     
  9. kokeeby

    kokeeby First time out of the vault

    46
    Jul 4, 2019
    @Radegast Just checking, but has there been any new development?
     
  10. Radegast

    Radegast First time out of the vault

    12
    Jan 14, 2013
    Not really. The Easter and Epax maps now load fine but there are so many issues with the Epamain maps that I doubt I will figure them all out. At least I upgraded the project to the latest C++ Builder so it will look a bit nicer on newer OSes and I won't need to run Windows XP virtual machine anymore (it was a nice nostalgic experience though).

    I will be honest, I became extremely demotivated when I found out that this 20-year-old map editor is much faster than the new map editor that I have been working on up until now. On my PC Dims Mapper loads a large map within three seconds and my GECK editor takes up to 15 seconds! I will probably have to start from scratch :(
     
  11. kokeeby

    kokeeby First time out of the vault

    46
    Jul 4, 2019
    The fixed version (without the epamain maps) would still be helpful. There are some maps in FO1 that also don't work, but with the fixes of epax and easter they would probably work.
     
  12. Radegast

    Radegast First time out of the vault

    12
    Jan 14, 2013
    I submitted a patch for the Epax and Easter maps to @Mr.Stalin on Github. Hopefully, loading some FO1 maps should be fixed as well, but I haven't tested all of them.

    There seem to be so many issues with EPAMain maps that it is a miracle that map loads within the game. I just don't understand it.
     
  13. Lexx

    Lexx Testament to the ghoul lifespan
    Moderator Modder

    Apr 24, 2005
    You probably have to fork it and work on your own git repo. Last status is that Mr.Stalin doesn't want to work with evil americans / westerners anymore.
     
  14. kokeeby

    kokeeby First time out of the vault

    46
    Jul 4, 2019
    @Radegast thanks for the fixes. Tried the commit for the original C++ builder (https://github.com/JanSimek/F2_Mapper_Dims/commit/09ca0269d587d84019633107feae3365398631d0).

    As far as epax is concerned, I uncommented lines 796, 901 in main.cpp and 75, 80 in frmset.cpp to get the roof in epax to show. Turns out that the tile that it's asking for is not 7856, but 7856&0FFFh = 3760. If you look in BISmapper, the tiles with that id are roof tiles that are used in epa.
    The 4096 limit was actually present in the old DIMS, but it was commented out in this commit (https://github.com/FakelsHub/F2_Mapper_Dims/commit/e0a56958a744e21c3f417819a6f7753292dff19d) I don't know any of the internals of how maps or ids in Fallout work so make of that what you will...

    Other than that I tried all the maps from F1, F2 (vanilla), F2RP (2014), Nevada, 1.5 Resurrection and Olympus.

    F1, Nevada, 1.5 work completely.

    In F2 (vanilla) both NewR1a and NewR2a throw a memory access violation error during loading. They don't work even in the original DIMS from Stalin's repo (0.99.3 version). Apparently I missed them :) I looked at them in BISmapper, but they show up for me as empty maps? Without any tiles... Other maps work.

    In F2RP (2014) Epamain1 Epamain2 and NewR1a NewR2a aren't working, other maps work

    In Olympus oacave oaenter oamain also throw a memory access violation error during loading. Rest of the Olympus maps don't show any errors during loading. I haven't played Olympus so I can't really compare, but the maps seemed fine, I think all of the assets were loaded.
     
  15. Radegast

    Radegast First time out of the vault

    12
    Jan 14, 2013
    Great catch! I would have never figured it out. I remember noticing these commented-out lines but unfortunately, my brain will never understand how bitwise operations work so I did not even bother trying to understand what it does.

    The GECK map editor I am working on (which is basically a ripped-out skeleton from Falltergeist) is now able to load the aforementioned Olympus maps (oacave, oaenter, oamain) AND epamain1 and epamain2 from RP so it shouldn't be an issue to figure out what's different in the Dims mapper.

    Hopefully, there aren't any other nasty hacks to be found but I just know there are.
     
  16. .Pixote.

    .Pixote. Antediluvian as Feck
    Modder

    Sep 14, 2009
    Anyone out there that can answer my question - I'm trying to get Dims Mapper working on Windows 10 with a clean install of F2, but can't load any maps!

    The log message is -

    Palette init ... OK.
    Load LST files ... OK.
    Create PRO structure ... OK.
    Create FRM structure ... OK.
    Load MSG files ... OK.
    DDraw create failed.
    One or more of the parameters passed to the callback function are incorrect.
     
  17. kokeeby

    kokeeby First time out of the vault

    46
    Jul 4, 2019
  18. NovaRain

    NovaRain Casual Modder Modder

    Mar 10, 2007
    Just curious, what do I need for compiling the mapper? I tried installing Borland C++ Builder 6 on my Win2k server, but I can't get it open the project file.
     
  19. kokeeby

    kokeeby First time out of the vault

    46
    Jul 4, 2019
    Just Borland C++ builder. Although I'm compiling it on a Winxp VM. I'm using this borland https://rutracker.org/forum/viewtopic.php?t=3638325.
    Also when you try to compile it, I think it will complain about the bin directory missing in the folder with the source files. So either create an empty bin dir there, or change directory paths in Project options. This has nothing to do with opening the project though. That should work fine with no changes.
     
  20. NovaRain

    NovaRain Casual Modder Modder

    Mar 10, 2007
    Ah, thanks for the tip. I managed to build the mapper but got the same "DDraw create failed" error as Pixote. Then I tried "implib.exe ddraw.lib C:\WINNT\system32\ddraw.dll" ("-a" won't work) to replace the original library in the project. Now it works for most maps on Win7/10, with Radegast's code it can open easter/eapx but crashed/hanged at epamain1 & 2.