Results 1 to 12 of 12

Thread: Changing captain battle models

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Default Changing captain battle models

    Hi,
    I've been trying -- and failing miserably! -- to replace the captain model in the mod I want to use (SS 6.2) with the Spanish captain from Kingdoms' Americas mod, for a few factions. For simlicity, I've started out with trying to do it just for France. Getting the strat model to work was easy, but I just can't get the battle model to work. If anyone could give me a hint (or fourteen) to what I'm doing wrong, that would be much appreciated.

    This is what I've done so far:

    -- Copied the entire spanish_capn folder from Americas' unit_models\_generals_and_captains folder, which has the mesh and texture files I need, and pasted it into the _generals_and_captains folder of my mod.

    -- In the descr_character file I've changed the battle_model entry under "type general" for France to nw_captain, which is what is entered in the same place in the Americas' folder.

    -- In the battle_models.modeldb file I have added one to the counter at the top, since I have added one more unit.

    -- At the end of the same file I have pasted the nw_captain entry copied from the Americas modeldb file. I have been careful, and checked and re-checked, that I haven't made any errors with spacing etc in the file.

    This all result in persistent CTDs when the game loads, so obviously I'm missing something critical. But what is it?

    I'm not sure it means anything, but the modeldb file in Americas seems wonky. I can't change anything in it, like using enter to separate lines, even though I'm mindful of not adding spaces or changing or breaking it's structure in any other way. If I do use enter even once, the screen just goes black and I get the arrow cursor, when trying to run the mod. But I can use enter to separate lines in the modeldb file in SS without problem. I have no idea why it works differently in the two cases. Since I'm just copy pasting from Americas modeldb file, maybe the wonkyness carries over to SS and that explains my problem? However, I do not believe this is the case, because the crash I get when starting SS 6.2 up is different; it CTDs after a brief moment of showing the first load screen.

    Thanks.

  2. #2
    /|\/|\/|\/|\/|\/|\/
    Join Date
    Jun 2005
    Posts
    10,770

    Default Re: Changing captain battle models

    It will be your battle_models entry causing the CTD. Try just writing it instead of copying. If you know where the files are, and where you need to put spaces, then you'll have no problem.

  3. #3

    Default Re: Changing captain battle models

    Thanks, I'll try that tomorrow.

  4. #4

    Default Re: Changing captain battle models

    Now I've tried to modify the modeldb file by hand typing, both in the middle of the file and at the end, but it just won't work. I've tried to type it both formatted with lines separated and as a single, long entry exactly matching the bit from the Americas modeldb file. I don't know what else to try, but I am sure the problem is not due to a typo or incorrect spacing.

    It's not a big deal; I just wanted to be able to get era specific generals and captains in my campaign with some simple text file switching.

    If someone else would like to try to get it to work, just do what I described above and see what happens. Or if I did something wrong or missed anything, please tell me.

    This is what the entry for nw_captain in Americas' modeldb file looks like:
    Spoiler Alert, click show to read: 
    nw_captain 1 1 68 unit_models/_Generals_and_Captains/Spanish_Capn/nw_captain_lod0.mesh 6400 5 7 england 88 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_england.texture 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_normal.texture 0 6 france 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_france.texture 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_normal.texture 0 5 spain 86 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_spain.texture 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_normal.texture 0 5 slave 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_rebels.texture 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_normal.texture 0 4 merc 86 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_mercs.texture 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_normal.texture 0 5 7 england 61 unit_models/AttachmentSets/Final General_england_diff.texture 61 unit_models/AttachmentSets/Final General_england_norm.texture 0 6 france 60 unit_models/AttachmentSets/Final General_france_diff.texture 60 unit_models/AttachmentSets/Final General_france_norm.texture 0 5 spain 59 unit_models/AttachmentSets/Final General_spain_diff.texture 59 unit_models/AttachmentSets/Final General_spain_norm.texture 0 5 slave 59 unit_models/AttachmentSets/Final General_slave_diff.texture 59 unit_models/AttachmentSets/Final General_slave_norm.texture 0 4 merc 58 unit_models/AttachmentSets/Final General_merc_diff.texture 58 unit_models/AttachmentSets/Final General_merc_norm.texture 0 4 4 None 15 MTW2_Non_Shield 0 1 18 MTW2_Sword_Primary 0 5 horse 18 MTW2_HR_Non_Shield 0 1 18 MTW2_Sword_Primary 0 8 elephant 18 MTW2_Elephant_Crew 0 1 18 MTW2_Sword_Primary 0 5 camel 18 MTW2_HR_Non_Shield 0 1 18 MTW2_Sword_Primary 0 -1 0 0 0 0 0 0 10

    Or, just for the French faction:
    Spoiler Alert, click show to read: 
    nw_captain 1 1 68 unit_models/_Generals_and_Captains/Spanish_Capn/nw_captain_lod0.mesh 6400 1 6 france 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_france.texture 87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_normal.texture 0 1 6 france 60 unit_models/AttachmentSets/Final General_france_diff.texture 60 unit_models/AttachmentSets/Final General_france_norm.texture 0 4 4 None 15 MTW2_Non_Shield 0 1 18 MTW2_Sword_Primary 0 5 horse 18 MTW2_HR_Non_Shield 0 1 18 MTW2_Sword_Primary 0 8 elephant 18 MTW2_Elephant_Crew 0 1 18 MTW2_Sword_Primary 0 5 camel 18 MTW2_HR_Non_Shield 0 1 18 MTW2_Sword_Primary 0 -1 0 0 0 0 0 0 10

  5. #5

    Default Re: Changing captain battle models

    Why don't u try to make changes on a formatted version of Americas BMDB file?
    You can download it here.

  6. #6
    /|\/|\/|\/|\/|\/|\/
    Join Date
    Jun 2005
    Posts
    10,770

    Default Re: Changing captain battle models

    Here's the smaller entry, I just formatted it:

    Code:
    10 nw_captain 
    1 
    1 
    68 unit_models/_Generals_and_Captains/Spanish_Capn/nw_captain_lod0.mesh 6400 
    1 
    6 france 
    87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_france.texture 
    87 unit_models/_Generals_and_Captains/Spanish_Capn/textures/spanish_captain_normal.texture 0 
    1 
    6 france 
    60 unit_models/AttachmentSets/Final General_france_diff.texture 
    60 unit_models/AttachmentSets/Final General_france_norm.texture 0  
    4 
    4 None 
    15 MTW2_Non_Shield 
    0 
    1 
    18 MTW2_Sword_Primary 
    0 
    5 horse 
    18 MTW2_HR_Non_Shield 
    0 
    1 
    18 MTW2_Sword_Primary 
    0 
    8 elephant 
    18 MTW2_Elephant_Crew 
    0 
    1 
    18 MTW2_Sword_Primary 
    0 
    5 camel 
    18 MTW2_HR_Non_Shield 
    0 
    1 
    18 MTW2_Sword_Primary 
    0 -1 0 0 0 0 0 0 10
    It seems fine... I added a space at the end, and at the end of the normal attachment texture, after the 0. And I added the character count for the entry name. I imagine the end space and the character count were lost when you copied it into your post, but I thought I should mention it.

    I note that you say you've increased the serialization count. Is the last entry, before the one you've just added, working fine? And, have you tried moving the new entry to the middle of the file?
    Last edited by Taiji; July 29, 2010 at 08:57 AM.

  7. #7

    Default Re: Changing captain battle models

    Thanks guys, after manually typing in the bits from Taiji's cleaned up entry and closely comparing it to the formatted Americas file Ishan linked to, the game will actually load the modeldb. Yay! So, I must have repeated some mistake again and again without spotting it - I'm probably going retarded or something...

    However, now the game crashes at the first load screen instead. If I change the battle_model entry for my French captain back to the original, it loads without a hitch. Does that mean there is something wrong with the mesh or texture for the nw_captain? I don't see how there could be, since I just copied and pasted the entire Spanish_Capn folder from Americas into my mod's_Generals_and_Captains_ folder.

    Could it have anything to do with the lack of a sprite entry for the unit in the modeldb? There is none in Americas for the nw_captain, though. And what about having only one lod entry, instead of three or four, as for most unit entries? Would changing the lod from 6400 to some other magical number do anything. I have tried it for a bit without results, but I don't know what numbers to try.

    Thanks.

  8. #8

    Default Re: Changing captain battle models

    Quote Originally Posted by No_Pants_On View Post
    Thanks guys, after manually typing in the bits from Taiji's cleaned up entry and closely comparing it to the formatted Americas file Ishan linked to, the game will actually load the modeldb. Yay! So, I must have repeated some mistake again and again without spotting it - I'm probably going retarded or something...

    However, now the game crashes at the first load screen instead. If I change the battle_model entry for my French captain back to the original, it loads without a hitch. Does that mean there is something wrong with the mesh or texture for the nw_captain? I don't see how there could be, since I just copied and pasted the entire Spanish_Capn folder from Americas into my mod's_Generals_and_Captains_ folder.

    Could it have anything to do with the lack of a sprite entry for the unit in the modeldb? There is none in Americas for the nw_captain, though. And what about having only one lod entry, instead of three or four, as for most unit entries? Would changing the lod from 6400 to some other magical number do anything. I have tried it for a bit without results, but I don't know what numbers to try.

    Thanks.
    The entry given by Taiji in the above post is flawless. He has used the nw_captain that u are trying to replace and pasted the entries for spanish_capn which u said are there in the right place coz u have simply pasted the entire directory for it.
    The attachments in the the Taiji entries use french textures which will be loaded from the .pack files without question coz they are the default files of vanilla.

    Now on to some facts:-
    Sprite won't cause a crash coz they are not mentioned in the BMDB entry for the that particular unit.
    The number 6400 simply refers to the distance till that particular .mesh file will be displayed on the battle map. After the distance of 6400 u won't be able to see the unit.
    It has nothing to do with 3 or 4 types of mesh file coz u see the entries are generally like
    mesh1 121
    mesh2 900
    mesh 3 2500
    mesh 4 6400
    So it's clear that from distance 0-121 mesh 1 will be displayed from 121-900 mesh 2 and so on.

    Now i suggest that u paste the default formatted version of the americas BMDB file and load the game. If it loads right then the game is alright.

    After that paste the Taiji's entry in it and mind u that u don't have to add a new entry but replace the existing entry for nw_captain.

    After that make sure the corresponding paths of the files mentioned in the BMDB entry for nw_captain are at the right place. Then load the game and everything should work fine.

  9. #9
    /|\/|\/|\/|\/|\/|\/
    Join Date
    Jun 2005
    Posts
    10,770

    Default Re: Changing captain battle models

    Does the log say anything?

  10. #10

    Default Re: Changing captain battle models

    I finally got it to work! Thanks a bunch, guys! I only repeated once again what you already told me to do, so I must have screwed up something awful before. Your patience with my noobishness is appreciated. I had completely forgotten about the log, and it confirmed that the problem was what you said all along.

    And to think I'm such a noob that I can't even give you rep...
    Last edited by No_Pants_On; July 30, 2010 at 01:57 PM. Reason: spelling

  11. #11

    Default Re: Changing captain battle models

    Glad to help u bro.

    U can rep Taiji and me once u are a member for more than a week and have more than 25 posts.
    To learn more about Reputation read this here. It will also fill out your other queries regarding TWC.
    Enjoy the modding experience and good luck.

  12. #12
    /|\/|\/|\/|\/|\/|\/
    Join Date
    Jun 2005
    Posts
    10,770

    Default Re: Changing captain battle models

    Well done for getting it working, No_Pants_On!

Posting Permissions

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