Page 33 of 35 FirstFirst ... 823242526272829303132333435 LastLast
Results 641 to 660 of 689

Thread: How to add a new unit into game

  1. #641
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician Moderator Emeritus Administrator Emeritus

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,096
    Blog Entries
    35

    Default Re: How to add a new unit into game

    The entries look fine, line count is OK.
    1. Did you increase the model count in the first line of the modeldb file?
    2. I believe SS has already 500 entries in the EDU, which means your entry will exceed this limit.

    Attaching files: if they are small do it via the 'Go Advanced' options. Bigger files should be compressed (7Zip is freeware) and then attached or uploaded to one of the many free upload services.
    Last edited by Gigantus; April 06, 2015 at 11:43 PM.










  2. #642

    Default Re: How to add a new unit into game

    To answer your questions:
    1. Yes I increased the number from it from 1197 to 1198. I made sure of that early on since it seemed a recurring problem in many threads.
    2. You are correct. I took a look today and after the last entry in the EDU there is a semicolon followed by a 500 which I assume denotes the unit count.

    One question: does anything need to be changed in export_descr _buildings?

    Due to the 500 entries in SS I will try adding the unit to Thera and The Sundering to check if my .mesh and .texture files are correct. If I still encounter problems I will compress the files and attach them.

    Many thanks for your reply and your tips, they are much appreciated.

  3. #643

    Default Re: How to add a new unit into game

    I apologise for the double post but I have tried adding the units to The Sundering but I get the same result: after a few seconds of the first loading screen I get a CTD.
    Because of this I believe the problem lies with my normal map or with my groups in the MS3D file. As such, I have attached both the unedited and my edited TGA and MS3D files (from my RTW mod) to this post.

    Edited RTW Files [TGA and MS3D].zipUnedited RTW files [TGA and MS3D].zip

  4. #644
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician Moderator Emeritus Administrator Emeritus

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,096
    Blog Entries
    35

    Default Re: How to add a new unit into game

    Double posts - once you have reached 25 posts or have been a member for two weeks (?) then you will be able to edit your posts.

    The model looks fine - usually these immediate crashes are related to the text entries, not the model. I'll try to build it into my trusty Bare Geomod.

    Edit: I used your data and converted the milkshape model and TGA textures into the correct format and had no problem starting the game. My guess - you do not have a space at the end of each line in the modeldb file.

    Points to note:
    Does the sprite (ModelDB entry)exist?
    Do the officer models (EDU entry) exits?
    Last edited by Gigantus; April 11, 2015 at 12:03 AM.










  5. #645

    Default Re: How to add a new unit into game

    To answer your questions:
    -After reading your post above I decided to use the sprite of another unit in order to be certain it exists.
    -In "The Sundering" mod no officer lines are required in the EDU so I left those lines out.

    While I waited for your reply I added entries to the
    data\text\export_units.txt, export_descr_buildings, and used the RTW unit pics in ui\units\[faction name]\#coded name and ui\unit_info\[faction name]\coded name_info. [I consulted your thread 'Creating a World - Importing units from another mod']
    After making these changes and re-editing the modelDB file the game starts, but I can not find my unit in the custom battle roster for the faction or in campaign. There is no unit card or placeholder. So what mistake have I made this time?

  6. #646
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician Moderator Emeritus Administrator Emeritus

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,096
    Blog Entries
    35

    Default Re: How to add a new unit into game

    If you have used the EDU entry in post 640 minus the two officer lines then the unit should appear if the faction is available in custom battle. The only way to remove the unit from custom battles would be to use the 'no_custom' attribute in the EDU entry. Also try to use the 'all periods' (?) setting in custom battle.
    Have you made the unit recruitable in the EDB? Please copy the building part here if you are not sure.

    There is always the chance that some files end up in th evirtual store and new files will then not be processed correctly. Follow this tutorial from step 3 and then delete the medieval ii total war folder from the virtual store if it exists.










  7. #647

    Default Re: How to add a new unit into game

    Success; finally it works.

    Problem: After you mentioned the EDB file I looked in it and saw that I had two entries in the same building for my unit .

    After removing one I checked in game and there was my cohort.

    I sincerely apologise if I perturbed you with my amateur problems. Nevertheless, I must thank you very much for your help.

  8. #648
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician Moderator Emeritus Administrator Emeritus

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,096
    Blog Entries
    35

    Default Re: How to add a new unit into game

    No problem - one is glad to be of service










  9. #649

    Default Re: How to add a new unit into game

    Hi.
    I'm playing with Divide and Conquer mod, adding some new units.
    I created unit for edenwaith taking general model , and it seems to work fine
    Now i try to make mounted version, but game crashes after 1-2 of first screen.
    Here is orginal entry in EDU(foot soldiers)
    type Enedwaith Chosen
    dictionary Enedwaith_Chosen
    category infantry
    class heavy
    voice_type Heavy
    banner faction main_infantry
    banner holy crusade
    soldier Enedwaith_Chosen, 60, 0, 1.0
    officer enedwaith_flag
    officer Alcfud_Axemen
    mount_effect elephant -2, eorlingas horse -2
    attributes sea_faring, hide_improved_forest, very_hardy, can_withdraw, free_upkeep_unit, command
    formation 1.4, 1.4, 2.8, 2.8, 7, square
    stat_health 1, 3
    stat_pri 12, 8, no, 0, 0, melee, melee_blade, slashing, axe, 15, 1
    stat_pri_attr ap
    stat_sec 0, 0, no, 0, 0, no, melee_simple, blunt, none, 0, 1
    stat_sec_attr no
    stat_pri_armour 18, 4, 6, metal
    stat_sec_armour 0, 0, flesh
    stat_heat 3
    stat_ground 1, -3, 2, 1
    stat_mental 15, impetuous, trained
    stat_charge_dist 15
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 2, 780, 330, 125, 125, 780, 4, 78
    armour_ug_levels 2, 3, 4
    armour_ug_models Enedwaith_Chosen, Enedwaith_Chosen, Enedwaith_Chosen
    ownership teutonic_order, slave
    era 0 teutonic_order
    era 1 teutonic_order
    era 2 teutonic_order
    recruit_priority_offset 50

    And here is modified on(mounted)

    type Enedwaith Ramriders
    dictionary Ramriders
    category cavalry
    class heavy
    voice_type heavy
    banner faction main_infantry
    banner holy crusade
    soldier Ramriders, 40, 0, 1.0
    mount northern heavy horse
    officer enedwaith_flag
    mount_effect elephant -2, eorlingas horse -2
    attributes sea_faring, hide_improved_forest, hardy, free_upkeep_unit, can_withdraw
    formation 2, 4.4, 3, 6, 3
    stat_health 1, 3
    stat_pri 12, 8, no, 0, 0, melee, melee_blade, slashing, axe, 15, 1
    stat_pri_attr no
    stat_sec 0, 0, no, 0, 0, no, melee_simple, blunt, none, 0, 1
    stat_sec_attr no
    stat_pri_armour 18, 4, 6, metal
    stat_sec_armour 0, 0, flesh
    stat_heat 3
    stat_ground 1, -3, 2, 1
    stat_mental 15, impetuous, trained
    stat_charge_dist 15
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 2, 780, 330, 125, 125, 780, 4, 78
    armour_ug_levels 2, 3, 4
    armour_ug_models Ramriders, Ramriders, Ramriders
    ownership teutonic_order, slave
    era 0 teutonic_order
    era 1 teutonic_order
    era 2 teutonic_order
    recruit_priority_offset 50

    and BMDB

    orginal

    16 Enedwaith_Chosen
    1 1
    70 unit_models/_Generals_and_Captains/Generals/teutonic_general_lod0.mesh 6400
    2
    5 slave
    62 unit_models/_Units/enedwaith/textures/teutonic_general.texture
    69 unit_models/_Units/enedwaith/textures/teutonic_general_normal.texture
    37 unit_sprites/tribal_axemen_sprite.spr
    14 teutonic_order
    62 unit_models/_Units/enedwaith/textures/teutonic_general.texture
    69 unit_models/_Units/enedwaith/textures/teutonic_general_normal.texture
    37 unit_sprites/tribal_axemen_sprite.spr
    2
    5 slave
    49 unit_models/AttachmentSets/dun_att11_diff.texture
    49 unit_models/AttachmentSets/dun_att11_norm.texture 0
    14 teutonic_order
    49 unit_models/AttachmentSets/dun_att11_diff.texture
    49 unit_models/AttachmentSets/dun_att11_norm.texture 0
    1
    4 None
    9 MTW2_Mace 0
    2
    17 MTW2_Mace_Primary 14 fs_test_shield
    0
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002


    and modified


    9 Ramriders
    1 1
    70 unit_models/_Generals_and_Captains/Generals/teutonic_general_lod0.mesh 6400
    2
    5 slave
    62 unit_models/_Units/enedwaith/textures/teutonic_general.texture
    69 unit_models/_Units/enedwaith/textures/teutonic_general_normal.texture
    37 unit_sprites/tribal_axemen_sprite.spr
    14 teutonic_order
    62 unit_models/_Units/enedwaith/textures/teutonic_general.texture
    69 unit_models/_Units/enedwaith/textures/teutonic_general_normal.texture
    37 unit_sprites/tribal_axemen_sprite.spr
    2
    5 slave
    49 unit_models/AttachmentSets/dun_att11_diff.texture
    49 unit_models/AttachmentSets/dun_att11_norm.texture 0
    14 teutonic_order
    49 unit_models/AttachmentSets/dun_att11_diff.texture
    49 unit_models/AttachmentSets/dun_att11_norm.texture 0
    1
    5 Horse
    12 MTW2_HR_Mace 0
    2
    17 MTW2_Mace_Primary 14 fs_test_shield
    0
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002


    I added 1 to top of file. I tried it with exiesting unit as well and i have the same crash. Anyone can help ?

  10. #650
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician Moderator Emeritus Administrator Emeritus

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,096
    Blog Entries
    35

    Default Re: How to add a new unit into game

    I can only think of a formatting error - please upload the modeldb file (compress and attach).










  11. #651

    Default Re: How to add a new unit into game

    I think the problem is in these lines:

    type Enedwaith Ramriders
    dictionary Ramriders
    category cavalry

    In every unit, the tupe and dictionary lines have the same text (dictionary changes space bar separation by "_"). To avoid changes in BMDB file you can delete Enedwaith word from the type line. The result will be:

    type Ramriders
    dictionary Ramriders
    category cavalry

  12. #652
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician Moderator Emeritus Administrator Emeritus

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,096
    Blog Entries
    35

    Default Re: How to add a new unit into game

    I have never understood the need to have different spelling in type and dictionary - it leads to unnecessary problems. "One word to bind them all" is my motto there










  13. #653

    Default Re: How to add a new unit into game

    Thank you for your help. Unfortunatly it didn't help.
    Here is modeldb file.

    I'm learning by copying units form DaQ submod, and guys there use different entries for type, dictionary and sometimes model name in modeldb.
    Like here.

    type Enedwaith Heavy Axemen ;Moot Keepers AF2/MA1 AOR ;Alcfud Axemen
    dictionary Moot_Keepers
    category infantry
    soldier Alcfud_Axemen, 60, 0, 1.0
    officer enedwaith_flag
    officer Alcfud_Axemen
    armour_ug_levels 2, 3, 4
    armour_ug_models Alcfud_Axemen, Alcfud_Axemen, Alcfud_Axemen

    So model name is used in soldier and armor upgrades, dictionary in unit description. And type to add unit to campaign map. Am i right ?
    Is my problem can be coming from using general battle model and making it into whole unit? Yesterday I also tried to replace weapon on one of units (mace,shield to 2-h sword) and unit load into the game with jesus syndrome. Can it be fault of models created for submod? Should i start from experimenting with vanilla files first ?
    Attached Files Attached Files

  14. #654
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician Moderator Emeritus Administrator Emeritus

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,096
    Blog Entries
    35

    Default Re: How to add a new unit into game

    Your modelDB file does not have the required empty space at the end of each line - that is very likely the problem. Did you by any chance run Notepad++'s 'remove trailing spaces' option?

    I would suggest to get a copy of the original, working modeldb and then start again.










  15. #655

    Default Re: How to add a new unit into game

    Thanks for reply.
    1) I can't find 'remove trailing spaces' . Did you mean Edit>Blanc Operation>Trim trailing spaces ?
    2) If i start again what steps should i follow to avoid not having empty spaces? The way i do it now is - I take and copy unit entry, go to end of previous unit, press ENTER to create new line and then paste new entry. I will use BACKSPACE to remove empty lines. But i guess its all wrong ?
    Also is there a tool to check for errors in modeldb file ?

  16. #656

    Default Re: How to add a new unit into game

    Also - can unit share mesh file or do i have to create copy of mesh file for every new unit ?

  17. #657

    Default Re: How to add a new unit into game

    I reversed to backup files, succesfuly added 2 new units with the same method, and only mounted one crash my game.

  18. #658

    Default Re: How to add a new unit into game

    Maybe are the animations assigned in the BMDB. Can you paste the unit text?

  19. #659

    Default Re: How to add a new unit into game

    I gave up on that unit. I found better looking axes for them, and now they work. Kind of. They just missing texture. Never ending struggle.

  20. #660

    Default Re: How to add a new unit into game

    I finally added the Arabian Archers (from BC) to my stainless steal SSHIP files and game and it works thank to this post's help. But now when I try to add another unit (seljuk ghazi swordsmen, shirvani swordsmen) to my game or any unit i keep getting crashes before the battle loads up. I can't seem to find what I did wrong this time around.

Posting Permissions

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