Results 1 to 13 of 13

Thread: battle_models coding/editing help!

  1. #1
    Kurry's Avatar Civis
    Join Date
    Jan 2010
    Location
    The Netherlands
    Posts
    164

    Default battle_models coding/editing help!

    10 tarlantir
    1 1
    64 unit_models/_generals_and_captains/tarlantir/tarlantir_lod0.mesh 6400
    2
    5 turks
    62 unit_models/_generals_and_captains/tarlantir/tarlantir.texture
    69 unit_models/_generals_and_captains/tarlantir/tarlantir_normal.texture 0
    65 unit_models/_generals_and_captains/tarlantir/tarlantir_sprite.spr
    6 sicily
    62 unit_models/_generals_and_captains/tarlantir/tarlantir.texture
    69 unit_models/_generals_and_captains/tarlantir/tarlantir_normal.texture 0
    65 unit_models/_generals_and_captains/tarlantir/tarlantir_sprite.spr
    2
    5 turks
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_diff.texture
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_norm.texture 0
    6 sicily
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_diff.texture
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_norm.texture 0
    1
    4 None
    20 MTW2_Halberd_Primary
    22 MTW2_Halberd_Secondary 1
    17 MTW2_Pike_primary 1
    17 MTW2_Pike_primary
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002

    does any of you see a problem in the coding here?

    I tried to add a custom general with his own model&texture, all the files are in the directed places with their correct names, I added one to the number of models in the battle_models file at the top and all the numbers before each line are correct.... any advice?

  2. #2
    Kiliš Alý's Avatar Domesticus
    Artifex

    Join Date
    Feb 2011
    Location
    Italy
    Posts
    2,114

    Default Re: battle_models coding/editing help!

    I know nothing about models, but I think you should say to people who will read this:
    1 - what does the game do: CTD (if yes, when), ignores the addition, some weird thing?
    2 - what does your log say


    Cheers

    Member of the Imperial House of Hader, proud client of The only and sole Ferrit

  3. #3

    Default Re: battle_models coding/editing help!

    If you've added the mesh, you need to add a number to the top of the file.

    At first glance the first line is wrong, it should read
    Code:
     9 tarlantir
    , there may be other errors there too, i haven't checked.

    If you search around in here, you'll find some model.db tutorials and there should be model.db cecker in there too.
    http://www.twcenter.net/forums/showthread.php?t=92488

    Code:
    10 tarlantir
    1 1 
    64 unit_models/_generals_and_captains/tarlantir/tarlantir_lod0.mesh 6400 
    2 
    5 turks
    62 unit_models/_generals_and_captains/tarlantir/tarlantir.texture 
    69 unit_models/_generals_and_captains/tarlantir/tarlantir_normal.texture 0
    65 unit_models/_generals_and_captains/tarlantir/tarlantir_sprite.spr
    6 sicily 
    62 unit_models/_generals_and_captains/tarlantir/tarlantir.texture 
    69 unit_models/_generals_and_captains/tarlantir/tarlantir_normal.texture 0
    65 unit_models/_generals_and_captains/tarlantir/tarlantir_sprite.spr
    2
    5 turks 
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_diff.texture 
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_norm.texture 0 
    6 sicily 
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_diff.texture 
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_norm.texture 0 
    1 
    4 None 
    20 MTW2_Halberd_Primary 
    22 MTW2_Halberd_Secondary 1 
    17 MTW2_Pike_primary 1 
    17 MTW2_Pike_primary 
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002
    Last edited by danny X; February 21, 2012 at 06:09 AM.


  4. #4
    Emperor of Hell's Avatar SPA-NED 1-5
    Join Date
    Jul 2011
    Location
    Netherlands
    Posts
    5,747

    Default Re: battle_models coding/editing help!

    Code:
    10 tarlantir
    1 1 
    64 unit_models/_generals_and_captains/tarlantir/tarlantir_lod0.mesh 6400 
    2 
    5 turks
    62 unit_models/_generals_and_captains/tarlantir/tarlantir.texture 
    69 unit_models/_generals_and_captains/tarlantir/tarlantir_normal.texture 0
    65 unit_models/_generals_and_captains/tarlantir/tarlantir_sprite.spr
    6 sicily 
    62 unit_models/_generals_and_captains/tarlantir/tarlantir.texture 
    69 unit_models/_generals_and_captains/tarlantir/tarlantir_normal.texture 0
    65 unit_models/_generals_and_captains/tarlantir/tarlantir_sprite.spr
    2
    5 turks 
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_diff.texture 
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_norm.texture 0 
    6 sicily 
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_diff.texture 
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_norm.texture 0 
    1 
    4 None 
    20 MTW2_Halberd_Primary 
    22 MTW2_Halberd_Secondary 1 
    17 MTW2_Pike_primary 1 
    17 MTW2_Pike_primary 
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002
    Delete the red parts. There might still be some more errors

  5. #5
    Kurry's Avatar Civis
    Join Date
    Jan 2010
    Location
    The Netherlands
    Posts
    164

    Default Re: battle_models coding/editing help!

    my game would ctd on start. So even before the loading screen and stuff.

    I fixed my obvious mistake with the number before tarlantir. Thanks for the heads up. xD

    Thank you Emperor!!!! removing those 0's fixed my problem. I've got him ingame now. Thank's guys for your quick replies.

    I have one last question: How do you make your general/family member use the 2H animations? I know its possible because Curufin who made the Call to arms submod for TATW was able to add a working general(Angbor) with a 2H battle axe. thank you for your time guys.

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

    Default Re: battle_models coding/editing help!

    Use Gracul's battle_models sweeper and you'll never have to deal with probs like this.

  7. #7
    Kurry's Avatar Civis
    Join Date
    Jan 2010
    Location
    The Netherlands
    Posts
    164

    Default Re: battle_models coding/editing help!

    thank you for the suggestion Taiji Ill try it out, can you shed some light on my other question?

  8. #8
    /|\/|\/|\/|\/|\/|\/
    Join Date
    Jun 2005
    Posts
    10,761

    Default Re: battle_models coding/editing help!

    Basically just duplicate his battle_models entry and then swap in the skeleton and animations coding from one of your 2handers.

  9. #9
    Kurry's Avatar Civis
    Join Date
    Jan 2010
    Location
    The Netherlands
    Posts
    164

    Default Re: battle_models coding/editing help!

    Quote Originally Posted by Taiji View Post
    Basically just duplicate his battle_models entry and then swap in the skeleton and animations coding from one of your 2handers.
    I don't think I quite understand this. Do you mean that I have to have 2 Tarlantir entries? one with the normal anims&skeletons and the other with halberd/2H anims&skeletons?

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

    Default Re: battle_models coding/editing help!

    Yes, but you don't need to, sorry for the confusion (I also forgot to mention renaming the duplicate). You can just replace the anims for the one you're changing, if you like.
    Last edited by Taiji; February 21, 2012 at 09:29 AM.

  11. #11
    Kurry's Avatar Civis
    Join Date
    Jan 2010
    Location
    The Netherlands
    Posts
    164

    Default Re: battle_models coding/editing help!

    Spoiler Alert, click show to read: 
    9 tarlantir
    1 1
    64 unit_models/_generals_and_captains/tarlantir/tarlantir_lod0.mesh 6400
    2
    5 turks
    62 unit_models/_generals_and_captains/tarlantir/tarlantir.texture
    69 unit_models/_generals_and_captains/tarlantir/tarlantir_normal.texture
    65 unit_models/_generals_and_captains/tarlantir/tarlantir_sprite.spr
    6 sicily
    62 unit_models/_generals_and_captains/tarlantir/tarlantir.texture
    69 unit_models/_generals_and_captains/tarlantir/tarlantir_normal.texture
    65 unit_models/_generals_and_captains/tarlantir/tarlantir_sprite.spr
    2
    5 turks
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_diff.texture
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_norm.texture 0
    6 sicily
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_diff.texture
    73 unit_models/_generals_and_captains/tarlantir/final_tarlantir_norm.texture 0
    1
    4 None
    11 MTW2_2H_Axe 0
    2
    19 MTW2_2H_Axe_primary
    14 fs_test_shield 0
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002

    with that entry my general still has the 1h sword animation , what is wrong?

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

    Default Re: battle_models coding/editing help!

    Oh yeah, I remember now it's restricted by settings in descr_character.

    Problem is I think it might be this line:

    battle_equip gladius, chainmail shirt helmet and rectangular shield

    And I don't know how you'd set that up for 2h.

    If you're sure of what you saw then I suggest you ask Curufin how he managed it
    Last edited by Taiji; February 21, 2012 at 10:18 AM.

  13. #13
    Kurry's Avatar Civis
    Join Date
    Jan 2010
    Location
    The Netherlands
    Posts
    164

    Default Re: battle_models coding/editing help!

    okay then, Ill send him a PM. Thanks for your help and time Taiji

Tags for this Thread

Posting Permissions

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