Tips: Creating Custom Groundcover

Performance Custom Shaders Portable Install Navmeshtool Register BSAs Merging Objects Cleaning Plugins File Renames Atlased Meshes INI Importer OPENMW_PHYSICS_FPS

The nature of how MGE:XE groundcover (also known as "legacy groundcover") works creates problems when you use any mod which changes the landscape. You'll end up with missing or floating groundcover items. It is possible to generate custom groundcover for your load order, but it is not a trivial process.

Table of Contents

The process

Below I will describe the process I used to create the custom groundcover plugins I provide for this website's mod lists.

  1. Make sure you've got a functional install of vanilla Morrowind available.
  2. Make sure you've got a functional install of TES3CMD.
  3. Find all plugins that contain LAND records:
    • Using the recommended folder structure from this website makes it somewhat easy to do with some shell scripting. This is the fish shell snippet I used for finding them in my own setup:
    • #!/usr/bin/fish
      for p in (find $HOME/games/openmw/Mods -type f -iname "*.esp")
          tes3cmd dump --list "$p" 2>/dev/null | grep -aq LAND; and echo "$p"
       end
  4. Of the results obtained from the previous step, examine each to determine which need to be included for the purpose of generating grass.
    • This step requires you to know a bit about the mod you're looking at, but most times it should be obvious if you should include a mod or not.
    • For example, Tamriel Rebuilt might come up as containing LAND records, but nothing on this site's mod lists change those outside of it, so there's no need to recreate the groundcover. But something like Trackless Grazelands does affect the landscape in a way that affects groundcover (you'd have conspicuous missing groundcover where the roads used to be).
  5. Create a fake cfg file with just the plugins you need, each one per line with content= just like in a real openmw.cfg file. Here's mine:
  6. content=OAAB_Data.esm
    content=Solstheim Tomb of The Snow Prince.esm
    content=Patch for Purists.esm
    content=PortsOfVvardenfellV1.6-TR_Travels-TOTSP-Ald-ruhn-Vivec-City.esp
    content=Unofficial Morrowind Official Plugins Patched.ESP
    content=Clean_DA_Sobitur_Facility_Clean.ESP
    content=Clean_DA_Sobitur_Repurposed_1.ESP
    content=The Rise of the Tribe Unmourned.esp
    content=Concept_Arts_plantations.esp
    content=Clean_Mines & Caverns.esp
    content=Clean_Foyada Mamaea Overhaul.ESP
    content=Vurt's Grazelands Unique Trees.ESP
    content=OAAB_Grazelands.ESP
    content=Trackless Grazeland.ESP
    content=WhiteSuran2_MD_Edition.esp
    content=Clean_Stav_gnisis_minaret.ESP
    content=RR_Telvanni_Lighthouse_Tel Vos_Eng.ESP
    content=RR_Telvanni_Lighthouse_Tel Branora_Eng.ESP
    content=RR_Holamayan_Eng.ESP
    content=RR_Ghost_Gate_Fortress_Eng.ESP
    content=DD_Caldera_Expansion.esp
    content=Clean_Ald-ruhn.ESP
    content=Clean_Hla Oad.esp
    content=Seyda_Neen_Gateway.ESP
    content=Clean_Vivec City.esp
  7. Convert this to Morrowind's ini file format. I wrote a python script that does this, you can find it here. My converted file looks like this:
  8. [Game Files]
    GameFile0=Morrowind.esm
    GameFile1=Tribunal.esm
    GameFile2=Bloodmoon.esm
    GameFile3=OAAB_Data.esm
    GameFile4=Solstheim Tomb of The Snow Prince.esm
    GameFile5=Patch for Purists.esm
    GameFile6=PortsOfVvardenfellV1.6-TR_Travels-TOTSP-Ald-ruhn-Vivec-City.esp
    GameFile7=Unofficial Morrowind Official Plugins Patched.ESP
    GameFile8=Clean_DA_Sobitur_Facility_Clean.ESP
    GameFile9=Clean_DA_Sobitur_Repurposed_1.ESP
    GameFile10=The Rise of the Tribe Unmourned.esp
    GameFile11=Concept_Arts_plantations.esp
    GameFile12=Clean_Mines & Caverns.esp
    GameFile13=Clean_Foyada Mamaea Overhaul.ESP
    GameFile14=WhiteSuran2_MD_Edition.esp
    GameFile15=Clean_Stav_gnisis_minaret.ESP
    GameFile16=RR_Telvanni_Lighthouse_Tel Vos_Eng.ESP
    GameFile17=RR_Telvanni_Lighthouse_Tel Branora_Eng.ESP
    GameFile18=RR_Holamayan_Eng.ESP
    GameFile19=RR_Ghost_Gate_Fortress_Eng.ESP
    GameFile20=DD_Caldera_Expansion.esp
    GameFile21=Clean_Ald-ruhn.ESP
    GameFile22=Clean_Hla Oad.esp
    GameFile23=Seyda_Neen_Gateway.ESP
    GameFile24=Clean_Vivec City.esp
    GameFile25=Vurt's Grazelands Unique Trees.ESP
    GameFile26=OAAB_Grazelands.ESP
    GameFile27=Trackless Grazeland.ESP
    GameFile28=OAAB Dwemer Pavements.ESP
  9. Paste that load order into your vanilla Morrowind install's Morrowind.ini file. Make a backup beforehand, if you wish.
  10. Read this guide to understand what the various options of the mesh generator do. Technically optional, but highly recommended.
  11. Make sure the configuration ini files for the groundcover you wish to generate are available. In many cases, the mods themselves come with these or have them available as an optional download.
  12. Run the mesh generator exe.
    • Folks that rely on wine need not worry; I generated this website's custom groundcover with wine, it works well enough but is prone to crashing (no different than Windows, unfortunately).
    • You want to make two plugins for each ini config; one for the the modded changes you may have, and another to cover the rest of the untouched vanilla cells.
    • When generating the plugins for modded land, you want to exclude the vanilla game .esm files (Morrowind.esm, Tribunal.esm, and Bloodmoon.esm).
    • When generating plugins for vanilla content, leave only Morrowind.esm selected for "Data files to search".
  13. In the mesh generator GUI, click "Browse" to find the ini file for the groundcover you wish to generate. Many mods make these available on a per-region basis, and these tend to be less crashy in my experience.
  14. Morrowind location should auto-fill, if not enter that correctly.
  15. Give the generated plugin a unique name.
  16. If generating a plugin for vanilla content, leave only Morrowind.esm selected for "Data files to search".
  17. If generating a plugin for modded content, click "Import from Ini", and then remove Morrowind.esm, Tribunal.esm, and Bloodmoon.esm.
  18. Click "Generate".
    • For vanilla content, I didn't get many crashes. But when I generated modded content I did seem to get the occasional crash. If this happens, you can simply re-enter everything into the GUI and try again. Sometimes I had to try several times before it worked, don't get discouraged.
  19. With plugins generated for all of your modded and vanilla content, it isn't a bad idea to dump just the cell records into a new plugin for each one. Something like this could be done for each plugin you've generated:
  20. tes3cmd dump --type cell --raw-with-header momw_AesAdGrass_AC_Grass_cells.esp momw_AesAdGrass_AC_Grass.esp
  21. Now you must determine which cells are changed by your modded plugins so that you can delete them from your vanilla plugins. This fish shell snippet is what I used:
  22. #!/usr/bin/fish
    for region in "AC" "AI" "AL" "BC" "GL" "WG";
        for cell in (tes3cmd dump --type cell momw_AesAdGrass_"$region"_Grass_cells.esp | grep CELL | awk -F\( '{ print $2 }' | awk -F\) '{ print $1 }');
            echo tes3cmd delete --type cell --id \'\\\($cell\\\)\' mw_AesAdGrass_"$region"_Grass_cells.esp
        end
    end
  23. The snippet from the previous step will print out several tes3cmd delete commands that you can copy and paste into your shell to run. Each one will delete a cell that was found in your modded plugins. Here's a sample of some of the commands I generated and subsequently copy-pasted to run:
  24. tes3cmd delete --type cell --id '\(2, -12\)' mw_AesAdGrass_AC_Grass_cells.esp
    tes3cmd delete --type cell --id '\(12, -8\)' mw_AesAdGrass_AC_Grass_cells.esp
    tes3cmd delete --type cell --id '\(12, 14\)' mw_AesAdGrass_AC_Grass_cells.esp
  25. At this point, you should have fully functional modded and vanilla groundcover plugins.

Review

A final step would be to run the game with your new plugins and look for errors. I created the OpenMW-Lua mod show-current-cell, which prints your current cell's name and x, y grid coordinates when you press the = key, to aid in hunting down such problems. This makes it easy to see, in-game, what cell you're in.

When you know the cell x, y of where you're having problems, you can go back and look at what TES3CMD reported and find the offender. If you didn't save the output from running TES3CMD, it might be a good idea to redo those steps and save that output.

Caveats

Of course this process is not perfect. Here's some of what I consider to be its major caveats:

Credits

This guide (and, the custom plugins I created for this website) would not be possible without the valuable help of eddie5 and ezze. Thanks a ton!

Performance Custom Shaders Portable Install Navmeshtool Register BSAs Merging Objects Cleaning Plugins File Renames Atlased Meshes INI Importer OPENMW_PHYSICS_FPS

Settings
GPLv3 logo