Results 1 to 6 of 6

Thread: Tips and Tricks in modding ETW and NTW

  1. #1

    Default Tips and Tricks in modding ETW and NTW

    Tips and Tricks in modding ETW and NTW

    It is not in my intention to write another guide about making a mod, there are already so many of them. But I've seen many questions which normally they should not be and that means to me that tutorials are not clear enough. Also there are some useful tips and tricks that make my life easier with modding. Some of these ideas are not mine but it is impossible to remember where I've first met them.

    * If it is your first mod start with this guide.

    * Always create a working folder where you will place your new pack. There you should extract the db tables and files you want to add in your pack. For db\tables export there also their TSVs. In TSVs you'll make the changes and finally import them in your new mod pack.

    It is very helpful to have also available a second folder where you should export the TSVs of vanilla db\tables which you use in your mods. In this way you can easily copy\paste stuff to your TSVs.

    * A practical way to make a mod pack with many tables is by using a spread sheet. Use first sheet for example to copy there the lines with the units you will use from vanilla units.TSV. The second sheet can be used for units_stat_land, the third for uniforms and so on. When you are ready with your changes, copy in your working folder the vanilla TSVs. Then open every one delete all content except the 3 first rows with headers and title. Copy in there the rows from your spreadsheet with the modded data.

    * If you extract a file from a pack which it is inside several folders, PFM will extract full path. If for example you extract the units table you'll find it your working folder db which contains units file because in original pack the path is db\units. If you want to add units table in your pack you have first to place your pack in the same place with db folder and not with units!

    Emphasizing more on this if you extract the file hello from a pack which is in the path: wq\s\d\g\h\u\j\j\jk\g\g\f\d\e\t\yh\j\m\g\f\d\er\ty\jh\hello PFM will extract it's full path. If you want to add hello file or any folder of the previous path in your new pack you have first to place your pack in the same place with wq !!! So when you will add hello file PFM will insert it's full path wq\s\d\g\h\u\j\j\jk\g\g\f\d\e\t\yh\j\m\g\f\d\er\ty\jh\hello.

    * Avoid to make mod packs "movie" type just because you do not have to edit user.script.txt. In the future it is easy to be forgotten and they will cause conflicts with unexplained results. When you do not want them anymore or you want to use another mod you have to find and delete them. But for "mod" type mod packs it is enough to remove their command from user.script.txt or untick them in Mod Manager. Some type of packs like _loc or media have to be "movie" though, or they will not work.

    * Most of the times that your mod pack is not loaded, the reason is that you have not probably encode your user.script.txt as Unicode. Try it before you make your mod pack "movie" type.
    Spoiler Alert, click show to read: 

    * Always rename db tables in your pack even if you use all its contents. If you change the recruitment limit of one unit, you can have in your mod pack units table containing only one line with the specific unit. In that case you have to rename table (e.g. my_units). If you rename table, the game will load the vanilla units table and then it will change only the unit that is included in your pack. But if you do not rename it the game will overwrite whole vanilla units table with yours that contains only one unit and you'll get a CTD.

    Some modders (even experienced) when they use all the table content they do not rename the table. If you change the limit in all units then the game will overwrite the vanilla table with yours but since it contains all the units it won't crash. But when an update comes with some new units from CA (free or DLC) then the things change and your game will crash unless you update your mod. But if you had renamed the table you'll have no rush to do it. Your mod will still be loaded without a problem. You won't have the new units available but you can update your pack taking your time and not under the pressure of "problem after latest CA patch" messages.

    * A very annoying error that happens in db tables is the space that accidentally can be at the end of an entry. I still remember that when I was trying to add Lancers in several factions for my Startpos Mods, for some factions worked but for some did not and CTD!!! I was hopeless trying to understand why this strange thing happened, until I discovered that in some tables I had entered the unit name "Lancers " with an accidental space at the end. Since in other tables the name was correct "Lancers" without space, the game considered that these were 2 deferent words and crashed in loading.

    * When you make your localisation.loc pack short your data in alphabetically order. Export as TSV, short it, make your changes, import back. This will make your life easier and will allow you later to make some changes straight in PFM without exporting TSV.

    * You cannot add new stuff in game like regions, cities, town, armies, etc. The Hybrid technique gives a solution up to a point.

    * When you are working with startpos and you want to make more than one change, test almost after every single change and keep often back up of your file. Except a wrong change accidental mistakes often happens which are almost impossible to be found later.

    * Always save your changes in startpos.esf before exiting by clicking File, Save. If you try to close the editor with the X in upper right corner and save after the message prompts you to save, your changes will not be saved and you have to do them again.

    * You can change the government through startpos. There is one change that cannot be done thus changing Republic to any type of Monarchy.

    Also there is a usual possible mistake that happens in this modification. There are 2 changes to be made: one in FACTION\GOVERNMENT that is usually forgotten and causes CTD and the second in GOV_IMP.
    Spoiler Alert, click show to read: 

    * Never change the order of regions in regions.esf or you'll get a CTD.

    * Split large mod packs to smaller:

    Some mod packs become very large especially those containing custom units and models, graphics, etc. Uploading large packs is not only uncomfortable but become a really pain in the ass when you have to update them often. One good solution to that is to split in 3 or 3 smaller packs. Keep models, graphics separate (e.g. unitmodels, ui, rigidmodels, etc.) and a separate with db/tables. The last one will be very small even if contains many tables. There is one disadvantage doing so and that is that you have to enter more lines (as many as the packs are) in user's script. But this is nothing comparing with advantages.

    Your small pack with db tables will be the one that you'll need to make the updates most of the times. So now it will be easy enough to do it in short time. But even if you want to change something in the other packs you still need to update only the small pack. Then upload it and ask from the players to install the original version of the mod with the old db pack and then apply the update overwriting it. Let's see an example like changing model and texture of an existing custom unit:

    Even if models and textures are in a separate large pack you'll update the small pack with db tables. Just go in the related db tables (unit_stats_land and both warscape_animated) assign new names for your new model and texture of the existing units, add then in the pack with db tables your new model and texture and upload it. Your small pack will have now one model and one texture and your models pack will have an unused one which will not cause any problem. Your job will be done much quicker than updating the large pack. In this way you can add, replace or delete existing stuff, by adding the changes to your small db pack. After some updates of this kind you can make a large update updating all your packs but this can be scheduled by you whenever it is convenient.



    To be continued....
    Last edited by husserlTW; July 24, 2010 at 09:52 AM.




  2. #2
    r3deed's Avatar Semisalis
    Join Date
    May 2010
    Location
    unspeci
    Posts
    416

    Icon14 Re: Tips and Tricks in modding ETW and NTW

    at last.....

    thank you

    thank you

    thank you

    thank you

    thank you

    thank you

    thank you

    thank you

    thank you

    thank you



    thank you

  3. #3
    alpaca's Avatar Harbinger of saliva
    Join Date
    Sep 2005
    Location
    Germany
    Posts
    4,811

    Default Re: Tips and Tricks in modding ETW and NTW

    And the corresponding wiki page:

    http://www.twcenter.net/wiki/NTW_modding_tips

    No thing is everything. Every thing is nothing.

  4. #4

    Default Re: Tips and Tricks in modding ETW and NTW

    Edit: Next tip below has been added:

    Split large mod packs to smaller:

    Some mod packs become very large especially those containing custom units and models, graphics, etc. Uploading large packs is not only uncomfortable but become a really pain in the ass when you have to update them often. One good solution to that is to split in 3 or 3 smaller packs. Keep models, graphics separate (e.g. unitmodels, ui, rigidmodels, etc.) and a separate with db/tables. The last one will be very small even if contains many tables. There is one disadvantage doing so and that is that you have to enter more lines (as many as the packs are) in user's script. But this is nothing comparing with advantages.

    Your small pack with db tables will be the one that you'll need to make the updates most of the times. So now it will be easy enough to do it in short time. But even if you want to change something in the other packs you still need to update only the small pack. Then upload it and ask from the players to install the original version of the mod with the old db pack and then apply the update overwriting it. Let's see an example like changing model and texture of an existing custom unit:

    Even if models and textures are in a separate large pack you'll update the small pack with db tables. Just go in the related db tables (unit_stats_land and both warscape_animated) assign new names for your new model and texture of the existing units, add then in the pack with db tables your new model and texture and upload it. Your small pack will have now one model and one texture and your models pack will have an unused one which will not cause any problem. Your job will be done much quicker than updating the large pack. In this way you can add, replace or delete existing stuff, by adding the changes to your small db pack. After some updates of this kind you can make a large update updating all your packs but this can be scheduled by you whenever it is convenient.




  5. #5
    Lexandro81's Avatar Centenarius
    Join Date
    Apr 2010
    Location
    Bavaria
    Posts
    876

    Default Re: Tips and Tricks in modding ETW and NTW

    Absolutly awesome!!!! This changes so much for the modding-community !!!

  6. #6
    Salvo's Avatar Maréchal de l'Empire
    Join Date
    Mar 2008
    Location
    Poland
    Posts
    2,160

    Default Re: Tips and Tricks in modding ETW and NTW

    Nice job husserlTW,
    I know all this stuff, but I translated it to Polish and published on Polish TW forum, so have a REP++ from Polish fans

Posting Permissions

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