Page 9 of 9 FirstFirst ... 56789
Results 241 to 268 of 268

Thread: Tutorial - Adding a unit to the game

  1. #241
    Member Member Mr Frost's Avatar
    Join Date
    Dec 2002
    Location
    In a chair
    Posts
    520

    Default Re: Tutorial - Adding a unit to the game

    Figured it out .

    Seems it was simply a matter of putting --io.file_first in the mymod.bat as well as the command line of the shortcut pointing at it .


    Sodding GAH !






    Curse Bill Gates , and all Halflings !





    At least I seem to have solved the mystery of the invisible no Milkshape units !


    I'll say it again incase someone missed it ...

    I have solved the mystery of invisible units that have never seen nor heard of this thing you
    call Milkshape !!!!!!11!1ooohheisbig1!1111!!!!!one




    You may now send me gifts and pretty virgins .
    Last edited by Mr Frost; 08-21-2007 at 11:52.
    7 out of 10 people like me ,
    I'm not going to change for the other three .

  2. #242

    Exclamation HELP!?!

    Ok i was i could put up Scrshot 4 but i dont kno how to (leave me alone! my computer is retarded) neways ok guys i tried to create a unit for venice that has dismounted broken lances' armour with obushaer halberd as far as i kno i did everything right in export_descr_units...

    and model db


    but my problem is that my guys appear as mostly just a floating breastplate (some have lik the limbs with no helmet) and a floating halberdier just to say the limbs r not green they r invisible & they are standing in the cross position if u kno wat i mean wit thier arms out and feet straight down PLEASE HELP ME!!!!

  3. #243

    Default Re: Tutorial - Adding a unit to the game

    ok aparently im stupid so here is my export_descr_unit

    type Imperial Halberdiers
    dictionary Imperial_Halberdiers ; Imperial Halberdiers
    category infantry
    class heavy
    voice_type Heavy
    banner faction main_infantry
    banner holy crusade
    soldier Imperial_Halberdiers, 48, 0, 1.2
    attributes sea_faring, hide_forest, hardy, can_withdraw
    formation 1.2, 1.2, 2.4, 2.4, 3, phalanx, square
    stat_health 1, 0
    stat_pri 10, 5, no, 0, 0, melee, melee_blade, piercing, axe, 25, 1
    ;stat_pri_ex 0, 0, 0
    stat_pri_attr ap, long_pike, spear_bonus_4
    stat_sec 10, 5, no, 0, 0, melee, melee_blade, piercing, axe, 25, 1
    ;stat_sec_ex 0, 0, 0
    stat_sec_attr ap, spear_bonus_4
    stat_pri_armour 9, 5, 0, metal
    ;stat_armour_ex 19, 10, 0, 0, 4, 0, 0, metal
    stat_sec_armour 0, 0, flesh
    stat_heat 6
    stat_ground 1, -2, 3, 2
    stat_mental 11, disciplined, highly_trained
    stat_charge_dist 30
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 1, 1000, 180, 90, 70, 720, 4, 180
    armour_ug_levels 6
    armour_ug_models Imperial_halberdiers
    ownership venice
    era 2 venice
    ;unit_info 12, 0, 14


    and here is my model db

    20 imperial_halberdiers
    1
    4
    68 unit_models/_Units/LN_Gothic_RN_Plate/imperial_halberdiers_lod0.mesh 121
    68 unit_models/_Units/LN_Gothic_RN_Plate/imperial_halberdiers_lod1.mesh 900
    68 unit_models/_Units/LN_Gothic_RN_Plate/imperial_halberdiers_lod2.mesh 2500
    68 unit_models/_Units/LN_Gothic_RN_Plate/imperial_halberdiers_lod3.mesh 6400
    1
    6 venice
    80 unit_models/_Units/LN_Gothic_RN_Plate/textures/LN_gothic_RN_plate_venice.texture
    80 unit_models/_Units/LN_Gothic_RN_Plate/textures/LN_gothic_RN_plate_normal.texture
    57 unit_sprites/venice_Dismounted_Italian_MAA_ug2_sprite.spr
    1
    6 venice
    60 unit_models/AttachmentSets/Final Italian_venice_diff.texture
    60 unit_models/AttachmentSets/Final Italian_venice_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

  4. #244

    Default Re: Tutorial - Adding a unit to the game

    umm plz help!

  5. #245

    Default Re: Tutorial - Adding a unit to the game

    Hey, I noticed that in your picture, the units are still using pistols, instead of the gun that the camel gunners use. Is there an easy way to change from pistol to musket?

  6. #246

    Default Re: Tutorial - Adding a unit to the game

    hi i new,i have a problem i download cloud across europe and i want add a unit called "dismounted mailed knights" but is invisible in battle map, i added the same unit to mtw2 vanilla game and its works but in cae not, can somebody help me?

    sorry for the bad english

  7. #247

    Default Re: Tutorial - Adding a unit to the game

    Quote Originally Posted by Lord_XXX
    my mounted janissary musketeers as you say "so easy to do" im newbie and excites me mod the units xD, follow the love for guns xD

    Another little unit modification, my "Granaderos" or in english grenadier, this spanish soldier using a modified handgun shooting exploding shoots



    Here some apachean flying around


    Englishmen receiving a spanish gift



    some flying englishmen, enjoy! love for gunpowder weapons

  8. #248

    Default Re: Tutorial - Adding a unit to the game

    Argh, somebody help! I've followed this tutorial through some 6-7 times and have no idea what I'm doing wrong. I've even tried using another mod as a base for my attempts, but although the editing is easier, something's still broken. It's definitely something I'm doing wrong because everything works perfectly until I (apparently) edit the battle_models.modeldb file.

    Basically, the game crashes on startup. I'm modding the Kingdoms Crusaders expansion. Here's the sysem.log:
    Code:
    03:05:20.000 [system.rpt] [always] CPU: SSE2
    03:05:20.000 [system.rpt] [always] ==== system log start, build date: Aug  3 2007 version bld-medieval2-kingdoms-104 (45562) ===
    03:05:20.015 [system.io] [always] mounted pack packs/data_0.pack
    03:05:20.015 [system.io] [always] mounted pack packs/data_1.pack
    03:05:20.015 [system.io] [always] mounted pack packs/data_2.pack
    03:05:20.015 [system.io] [always] mounted pack packs/data_3.pack
    03:05:20.015 [system.io] [always] mounted pack packs/data_4.pack
    03:05:20.015 [system.io] [always] mounted pack packs/localized.pack
    03:05:20.031 [system.io] [always] mounted pack mods/crusades/packs/data.pack
    03:05:20.031 [system.io] [always] mounted pack mods/crusades/packs/localized.pack
    03:05:20.046 [system.io] [warning] open: mods/crusades/data/text/diplomacy_speech.txt.strings.bin is missing
    03:05:20.046 [system.io] [warning] open: mods/crusades/data/text/diplomacy_speech.txt is missing
    03:05:20.062 [system.io] [warning] open: mods/crusades/data/text/shortcut.txt.strings.bin is missing
    03:05:20.062 [system.io] [warning] open: mods/crusades/data/text/shortcut.txt is missing
    03:05:21.937 [data.missing] [warning] missing/invalid cursor for ANISELECT
    03:05:21.953 [data.missing] [warning] missing/invalid cursor for MODIFIER_SABOTAGE
    03:05:21.953 [data.missing] [warning] missing/invalid cursor for MODIFIER_TRADE
    03:05:21.984 [data.missing] [warning] missing/invalid cursor for DRAGGABLE
    03:05:21.984 [data.missing] [warning] missing/invalid cursor for DRAGGING
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_MULTIPLE_SELECT
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_ATTACK
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_CHARACTER
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_RESOURCE
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_FORT
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_MOVE_OBJECT
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_WATCHTOWER
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_DEPLOYMENT_AREA
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_TILE
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_SPECIAL_PIECE
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_PAINT
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_ADJUST_HEIGHTS
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_ADD_UNIT
    03:05:22.000 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_SETTLEMENT
    03:05:22.296 [system.io] [warning] open: mods/crusades/data/text/religions.txt.strings.bin is missing
    03:05:22.312 [system.io] [warning] open: mods/crusades/data/text/religions.txt is missing
    03:05:22.312 [system.io] [warning] open: mods/crusades/data/text/climates.txt.strings.bin is missing
    03:05:22.312 [system.io] [warning] open: mods/crusades/data/text/climates.txt is missing
    03:05:23.187 [script.err] [error] Script Error in mods/crusades/data/export_descr_unit.txt, at line 17115, column 30
    Could not find soldier battle model for unit type 'Dismounted_Knights_of_Edessa'.
    
    03:05:23.187 [data.invalid] [error] DATABASE_TABLE error found : error reading record from file mods/crusades/data/export_descr_unit.txt.
    Here's the battle_models entry:
    Code:
    21 hospitaller_voulgiers 
    1 
    4 
    52 unit_models/_Units/EN_Lmail_Hmail/voulgier_lod0.mesh 121 
    52 unit_models/_Units/EN_Lmail_Hmail/voulgier_lod1.mesh 900 
    52 unit_models/_Units/EN_Lmail_Hmail/voulgier_lod2.mesh 2500 
    52 unit_models/_Units/EN_Lmail_Hmail/voulgier_lod3.mesh 6400 
    1 
    7 antioch 
    78 unit_models/_Units/EN_Lmail_Hmail/textures/EN_Lmail_Hmail_hospitallerD.texture 
    82 unit_models/_Units/EN_Lmail_Hmail/textures/EN_Lmail_Hmail_crusaderD_normal.texture 
    56 unit_sprites/antioch_Hospitaller_Sergeant_ug1_sprite.spr 
    1 
    7 antioch 
    68 unit_models/AttachmentSets/Final Heater Special_antioch_diff.texture 
    68 unit_models/AttachmentSets/Final Heater Special_antioch_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
    Here's the export_descr_unit entry:
    Code:
    type             Hospitaller Voulgiers
    dictionary       Hospitaller_Voulgiers      ; Hospitaller Voulgiers
    category         infantry
    class            heavy
    voice_type       Heavy
    banner faction   main_infantry
    banner holy      crusade
    soldier          Hospitaller_Voulgiers, 48, 0, 1.2
    attributes       sea_faring, hide_forest, can_withdraw
    formation        1.2, 1.2, 2.4, 2.4, 4, phalanx, square
    stat_health      1, 0
    stat_pri         8, 5, no, 0, 0, melee, melee_blade, piercing, axe, 25, 1
    ;stat_pri_ex      0, 0, 0
    stat_pri_attr    ap, long_pike, spear_bonus_4
    stat_sec         9, 4, no, 0, 0, melee, melee_blade, piercing, axe, 25, 1
    ;stat_sec_ex      0, 0, 0
    stat_sec_attr    ap, spear_bonus_4
    stat_pri_armour  3, 7, 0, metal
    ;stat_armour_ex   3, 5, 6, 0, 7, 0, 0, metal
    stat_sec_armour  0, 0, flesh
    stat_heat        6
    stat_ground      1, -2, 3, 4
    stat_mental      5, normal, trained
    stat_charge_dist 30
    stat_fire_delay  0
    stat_food        60, 300
    stat_cost        1, 580, 150, 50, 115, 580, 4, 170
    armour_ug_levels 3
    armour_ug_models Voulgier
    ownership        antioch
    ;unit_info        8, 0, 10
    recruit_priority_offset    0
    I'm quite new to modding M2TW so I'm not sure if this is enough information. Please tell me if you need anything else to figure out what's wrong. I'm really frustrated because this has defied me over and over again and I can't understand why

    Thanks for anything you guys can offer.

  9. #249

    Default Re: Tutorial - Adding a unit to the game

    Um okay, firstly where is the edit button so I can edit my posts?

    Aaand secondly... I resolved the above situation and the game works fine, but now I have several more questions and problems...

    The textures on the unit and the unit card are broken:

    How can I fix this? I'm not too hot with textures. Will I have to edit the model for this?

    And finally, how do I enable the new units in custom battle?

    Thanks in advance.

  10. #250

    Default Re : Tutorial - Adding a unit to the game

    I need to add an officer to a new unit :
    So I have created US Dragoon (Us Cavalry) + one officer that look "US" , I am trying to add this Unit into The Spanish faction (because I still wan't to be able to play the original also) so they should have each a different looking officer .
    The Dragoon spanish should remain with it's own officer, How do I add my new officer to my new unit

    thanks
    Last edited by kungfuserge; 11-02-2007 at 11:04.

  11. #251

    Default Re: Tutorial - Adding a unit to the game

    i hate to seem like a noob but i follow the directions to the letter and i cant get anything
    im trying to make an unit thats basically a insanely good armored swordsmen for england
    its supposed to have the same look but have a bow for a secondary weapon and be unstoppable so i can fight off endless hordes of turmirds and mongols and the like on another mod im working on

    here is what i have in the

    type Marines
    dictionary Marines ; Marines
    category infantry
    class heavy
    voice_type Heavy
    banner faction main_infantry
    banner holy crusade
    soldier Armored_Swordsmen, 48, 0, 2.4
    attributes sea_faring, can_swim, hide_anywhere, can_sap, command, hardy, can_withdraw, free_upkeep_unit
    formation 1.2, 1.2, 2.4, 2.4, 4, square
    stat_health 8, 0
    stat_pri 60, 16, no, 0, 0, melee, melee_blade, piercing, sword, 10, 1
    ;stat_pri_ex 10, 10, 10
    stat_pri_attr ap
    stat_sec 48, 10, bodkin_arrow, 800, 3000, missile, missile_mechanical, piercing, none, 18, 1
    ;stat_sec_ex 10, 10, 10
    stat_sec_attr bp
    stat_pri_armour 36, 32, 36, metal
    ;stat_armour_ex 8, 9, 0, 0, 8, 6, 6, metal
    stat_sec_armour 0, 0, flesh
    stat_heat 0
    stat_ground 8, 8, 8, 8
    stat_mental 60, disciplined, lock_moral
    stat_charge_dist 30
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 1, 610, 150, 90, 70, 610, 4, 150
    armour_ug_levels 4, 5
    armour_ug_models Marines, Marines_ug1
    ownership england
    era 1 england
    era 2 england
    ;unit_info 60, 48, 104

    i did everything but the DB and make a new texture thing cause im not making any new skins or textures just a really good unit for the same faction
    And Fry, you've got that brain thing.

    I already did.

  12. #252

    Default Re: Tutorial - Adding a unit to the game

    I read the second thing listed that is needed to be done but I can't find anything for naval units? Could someone tell me how to do so?

  13. #253

    Default Re: Tutorial - Adding a unit to the game

    Naval units are a lot simpler.

    Example--a merc longboat.

    Copy and paste the listing for longboat in the export_descr_units file and change the things in red.

    Code:
    type             merc longboat
    dictionary       longboat      ; Longboat
    category         ship
    class            light
    voice_type       Light
    soldier          Peasants, 20, 0, 1
    ship             light warship
    attributes       sea_faring, can_withdraw, mercenary_unit
    formation        50, 50, 75, 75, 1, square
    stat_health      1, 0
    stat_pri         8, 0, no, 0, 0, melee, melee_simple, slashing, none, 25, 1
    ;stat_pri_ex      0, 0, 0
    stat_pri_attr    no
    stat_sec         0, 0, no, 0, 0, no, melee_simple, blunt, none, 25, 1
    ;stat_sec_ex      0, 0, 0
    stat_sec_attr    no
    stat_pri_armour  0, 3, 0, flesh
    ;stat_armour_ex   0, 0, 0, 0, 5, 0, 0, flesh
    stat_sec_armour  0, 0, flesh
    stat_heat        0
    stat_ground      0, 0, 0, 0
    stat_mental      8, normal, trained
    stat_charge_dist 30
    stat_fire_delay  0
    stat_food        60, 300
    stat_cost        1, 400, 200, 100, 100, 500, 4, 120
    armour_ug_levels 0
    armour_ug_models Peasants
    ownership        slave
    ;unit_info        8, 0, 5
    Then in the descr_mercenaries.txt, in the section for Scandinavia change the line:

    Code:
    unit merc cog,			exp 0 cost 400 replenish 0.03 - 0.15 max 1 initial 1
    to

    Code:
    unit merc longboat,		exp 0 cost 400 replenish 0.03 - 0.15 max 1 initial 1
    That's the minimum you need to do. You can start up a game as denmark and a general can recruit a merc longboat on the coast.


    The "dictionary" line in blue points the game at the text, title and ship picture the game uses so with that line unchanged the ships will have the same title and text as the original longboat.

    If you want to change the text/title then you change the dictionary line to say "merc_longboat". You'd then need to:

    1. Add an entry for "merc_longboat" in the units.text file in the text folder
    2. Copy the longboat pictures from the UI folder for denmark, rename them to merc_longboat, then put them in the "slave" UI folder.
    Last edited by nikolai1962; 11-25-2007 at 01:46.
    It's not a map.

  14. #254
    The drunken Duke Member Suraknar's Avatar
    Join Date
    Dec 2002
    Location
    Navigating the realm of Ideas
    Posts
    684

    Default Re: Tutorial - Adding a unit to the game

    Thank you Musashi for this Tutorial.

    The Model DB way was a turn off for modding in this TW game, however, after a couple of hours of just looking at the file I build up enough courage to start modding it, and thus far I was successful without crashes.

    A few Things I would like to share which may solve many people's issues with this file.

    1st - I use Notepad, with Word Wrap on to do my modding. Without Word Wrap it is very difficult to navigate in the Data (but its your call).

    2nd - It is very important to remember that there are places between some blocks that use 2 spaces. These have to be reproduced, specially if you want to make a unit from Faction A also available to Faction B (read bellow for more).

    3rd - Never ever use "Enter/Return" key when you do operations in this file. Use the left and right arrows to navigate around, use Spacebar, and only use Copy and Paste operations, and always verify for 1 or 2 spaces at the end or the beginning of where you are copy pasting the new data. And of course use the Find function to find units fast, by always placing your cursor to the beginning of the file, since you want to find the first entry of a given unit, like CTRL-F, "dismounted_e_chivalric_knights".

    4th - use the "-0.090000004 0 0 -0.34999999 0.80000001 0.60000002" strings to your visual advantage, they repeat only between different models so they do make good boxing indicators when you are looking at the file full of text.

    5th - Start slowly. I started by simply making changes to some factions, taking a unit from one faction and making it available to the another. For instance I gave a couple key advanced units to Byzantium. This helps to become familiar with the file before moving to adding full new units. learn how it works first before making to many changes at once.

    1 space or 2 Spaces?

    Each unit block follows the same format.

    Unit name/Model Info, Texture/sprite Info, Attachments texture Info, Weapons/Skeleton Info

    This is repeated for the same unit, upgrade models if there are any.

    What is important to know is that there is TWO spaces in some areas.

    Unit name/Model InfoOne SpaceTexture/sprite InfoOne SpaceAttachments InfoTwo SpacesWeapons/Animation Info
    Thus far, this is pretty straight forward when the unit is used by 1 faction.

    But when the model is used by more than one Faction there are a couple more things to watch for. Lets say the following unit is shared by 4 factions.

    Unit name/Model InfoOne Space4Texture/sprite InfoOne SpaceTexture/sprite InfoOne SpaceTexture/sprite InfoOne SpaceTexture/sprite InfoOne Space4Attachments InfoTwo SpacesAttachments InfoTwo SpacesAttachments InfoTwo SpacesAttachments InfoTwo SpacesWeapons/Animation Info
    Notice the 4, this is the number of Factions that use that Unit at the same time as the Number of textures or attachments to follow. In short its the Faction count.

    So, if you wanted to give reiters to a second faction, the count would be 2.

    And that is about it, I haven't yet used KnightErrant's formated DB, because I just discovered it. Still, this maybe helpful to some, and I thought to share it.

    Happy Modding.
    Last edited by Suraknar; 12-03-2007 at 10:13.
    Duke Surak'nar
    "Η ΤΑΝ Η ΕΠΙ ΤΑΣ"
    From: Residing:
    Traveled to: Over 70 Countries, most recent: and

    ~ Ask not what modding can do for you, rather ask what you can do for modding ~
    ~ Everyone dies, not everyone really fights ~

  15. #255
    Member Member Wontonman's Avatar
    Join Date
    Mar 2007
    Location
    Melbourne, Australia
    Posts
    7

    Unhappy Re: Tutorial - Adding a unit to the game

    Hello, im trying to add a unit into the game, and it crashes as soon as the battle loads, and just b4 crashing it shows everything white and black.


    my modeldb

    15 Hlaalu_Spearmen 1 4 48 unit_models/_Units/EN_Lmail_Hmail/DEHSPMlod0.mesh 121 48 unit_models/_Units/EN_Lmail_Hmail/DEHSPMlod1.mesh 900 48 unit_models/_Units/EN_Lmail_Hmail/DEHSPMlod2.mesh 2500 48 unit_models/_Units/EN_Lmail_Hmail/DEHSPMlod3.mesh 6400 1 7 england 78 unit_models/_Units/EN_Lmail_Hmail/textures/TX_A_bonemold_armun_an_helm.texture 72 unit_models/_Units/EN_Lmail_Hmail/textures/TX_A_bonemold_boots00.texture 72 unit_models/_Units/EN_Lmail_Hmail/textures/TX_A_bonemold_boots01.texture 82 unit_models/_Units/EN_Lmail_Hmail/textures/TX_A_bonemold_gah_julan_cuirass.texture 71 unit_models/_Units/EN_Lmail_Hmail/textures/TX_A_bonemold_ncloth.texture 76 unit_models/_Units/EN_Lmail_Hmail/textures/TX_A_bonemold_towershield.texture 71 unit_models/_Units/EN_Lmail_Hmail/textures/TX_B_N_Dark Elf_M_H03.texture 73 unit_models/_Units/EN_Lmail_Hmail/textures/TX_B_N_Dark Elf_M_Hpalm.texture 69 unit_models/_Units/EN_Lmail_Hmail/textures/Tx_C_Robe_comm3_01.texture 70 unit_models/_Units/EN_Lmail_Hmail/textures/TX_W_silver_spear02.texture 67 unit_models/_Units/EN_Lmail_Hmail/textures/TX_W_Spear_blade.texture 73 unit_models/_Units/EN_Lmail_Hmail/textures/TX_W_SPEAR_IRON_MIDDLE.texture 50 unit_sprites/merc_Dummy_EN_Spearmen_ug2_sprite.spr 1 4 merc 55 unit_models/AttachmentSets/Final Kite_merc_diff.texture 55 unit_models/AttachmentSets/Final Kite_merc_norm.texture 0 1 4 None 10 MTW2_Spear 0 2 18 MTW2_Spear_primary 14 fs_test_shield 0 16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002
    my edu

    type Hlaalu Spearmen
    dictionary Hlaalu_Spearmen ; Hlaalu Spearmen
    category infantry
    class spearmen
    voice_type Light
    accent Mediterranean
    banner faction main_spear
    banner holy crusade
    soldier Mercenary_Spearmen, 60, 0, 1
    attributes sea_faring, hide_forest, can_withdraw
    formation 1.2, 1.2, 2.4, 2.4, 4, square, schiltrom
    stat_health 1, 0
    stat_pri 7, 3, no, 0, 0, melee, melee_blade, piercing, spear, 25, 0.6
    ;stat_pri_ex 0, 0, 0
    stat_pri_attr spear, spear_bonus_8
    stat_sec 0, 0, no, 0, 0, no, melee_simple, blunt, none, 25, 1
    ;stat_sec_ex 0, 0, 0
    stat_sec_attr no
    stat_pri_armour 5, 3, 6, metal
    ;stat_armour_ex 5, 0, 0, 0, 3, 6, 6, metal
    stat_sec_armour 0, 0, flesh
    stat_heat 4
    stat_ground 1, -2, 3, 2
    stat_mental 5, normal, trained
    stat_charge_dist 20
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 1, 540, 185, 85, 65, 540, 4, 130
    armour_ug_levels 2
    armour_ug_models Hlaalu_Spearmen
    ownership england
    ;unit_info 7, 0, 14

    i dont have a clue about whats wrong please help


  16. #256
    Member Member Nevada's Avatar
    Join Date
    Oct 2007
    Location
    Bavaria
    Posts
    94

    Default AW: Tutorial - Adding a unit to the game

    hi there,
    I just went through it and had no problems, I created a new texture (recoloring a russian one) and then I started the game and I see only the model, it's like some kind of ghostguard



    the unit is based on the Dvor unit of the vanilla russia, do I need to add a mount to georgia (the new faction i added the unit) or is the mistake somewhere else?

    here's my export_descr_unit:
    Code:
    type             G Bodyguard
    dictionary       G_Bodyguard      ; Georgian Bodyguard
    category         cavalry
    class            missile
    voice_type       General
    banner faction   main_cavalry
    banner holy      crusade_cavalry
    soldier          Dvor_Cavalry, 16, 0, 1
    mount            eastern armoured horse
    mount_effect     elephant -4, camel -4
    attributes       sea_faring, hide_forest, can_withdraw, can_formed_charge, general_unit
    formation        2, 4.4, 3, 6, 3, square
    stat_health      1, 0
    stat_pri         10, 3, cav_composite_arrow, 120, 20, missile, missile_mechanical, piercing, none, 25, 1
    ;stat_pri_ex      0, 0, 0
    stat_pri_attr    no
    stat_sec         12, 3, no, 0, 0, melee, melee_blade, piercing, sword, 25, 1
    ;stat_sec_ex      0, 0, 0
    stat_sec_attr    ap
    stat_pri_armour  6, 6, 6, metal
    ;stat_armour_ex   3, 4, 6, 0, 5, 6, 6, metal
    stat_sec_armour  0, 0, flesh
    stat_heat        6
    stat_ground      0, 0, 0, 2
    stat_mental      11, disciplined, trained
    stat_charge_dist 45
    stat_fire_delay  0
    stat_food        60, 300
    stat_cost        1, 960, 250, 95, 225, 960, 1, 280
    armour_ug_levels 2, 3, 4
    armour_ug_models Dvor_Cavalry, Dvor_Cavalry_ug1, Dvor_Cavalry_ug2
    ownership        georgia
    era 0 		georgia
    era 1 		georgia
    era 2 		georgia 
    ;unit_info        9, 10, 14
    recruit_priority_offset    25
    and here's the model.db (or what i added):
    Code:
    5 Horse 
    15 MTW2_HR_Javelin 
    12 MTW2_HR_Mace 2 
    23 MTW2_HR_Javelin_Primary 
    14 fs_test_shield 2 
    17 MTW2_Mace_Primary 
    14 fs_test_shield 
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002 
    11 g_bodyguard
    1 4 
    68 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_lod0.mesh 121 
    68 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_lod1.mesh 900 
    68 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_lod2.mesh 2500 
    68 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_lod3.mesh 6400 
    1 
    7 georgia
    97 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/textures/EE_Bekhtera_Heavy_Lamellar_georgia.texture 
    96 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/textures/EE_Bekhtera_Heavy_Lamellar_normal.texture 
    43 unit_sprites/georgia_G_Bodyguard_sprite.spr 
    1 
    7 georgia 
    61 unit_models/AttachmentSets/Final Teardrop_russia_diff.texture 
    61 unit_models/AttachmentSets/Final Teardrop_russia_norm.texture 0  
    1 
    5 Horse 
    11 MTW2_HR_Bow 
    12 MTW2_HR_Mace 2 
    19 MTW2_HR_Bow_Primary 
    14 fs_test_shield 2 
    17 MTW2_Mace_Primary 
    14 fs_test_shield 
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002 
    15 g_bodyguard_ug1 
    1 4 
    72 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_ug1_lod0.mesh 121 
    72 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_ug1_lod1.mesh 900 
    72 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_ug1_lod2.mesh 2500 
    72 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_ug1_lod3.mesh 6400 
    1 
    7 georgia 
    97 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/textures/EE_Bekhtera_Heavy_Lamellar_georgia.texture 
    96 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/textures/EE_Bekhtera_Heavy_Lamellar_normal.texture 
    47 unit_sprites/georgia_G_Bodyguard_ug1_sprite.spr 
    1 
    7 georgia
    61 unit_models/AttachmentSets/Final Teardrop_russia_diff.texture 
    61 unit_models/AttachmentSets/Final Teardrop_russia_norm.texture 0  
    1 
    5 Horse 
    11 MTW2_HR_Bow 
    12 MTW2_HR_Mace 2 
    19 MTW2_HR_Bow_Primary 
    14 fs_test_shield 2 
    17 MTW2_Mace_Primary 
    14 fs_test_shield 
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002 
    15 g_bodyguard_ug2 
    1 4 
    72 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_ug2_lod0.mesh 121 
    72 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_ug2_lod1.mesh 900 
    72 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_ug2_lod2.mesh 2500 
    72 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/dvor_cavalry_ug2_lod3.mesh 6400 
    1 
    7 georgia 
    97 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/textures/EE_Bekhtera_Heavy_Lamellar_georgia.texture 
    96 unit_models/_Units/EE_Bekhtera_Heavy_Lamellar/textures/EE_Bekhtera_Heavy_Lamellar_normal.texture 
    47 unit_sprites/georgia_G_Bodyguard_ug2_sprite.spr 
    1 
    7 georgia 
    61 unit_models/AttachmentSets/Final Teardrop_russia_diff.texture 
    61 unit_models/AttachmentSets/Final Teardrop_russia_norm.texture 0

  17. #257
    One easily trifled with Member Target Champion Motep's Avatar
    Join Date
    Oct 2006
    Location
    In flux
    Posts
    4,268

    Default Re: Tutorial - Adding a unit to the game

    ah! I dont have the textures thanks to faulty unpacking programs. Or maybe faulty packs....


    And to the dude above me, that actually looks rather cool
    Last edited by Motep; 03-24-2008 at 04:24.
    TosaInu shall never be forgotten.

  18. #258

    Default Re: Tutorial - Adding a unit to the game

    What files do we have to mod to change weapon? You didn't seem to talk about how you gave your unit a gun, as it seems they do in the screenshot. Also, how do we change the horse? I don't seem to find how horses are given to cavalry units so that I can change their textures.
    I am having this problem with the varangian guard. I modded the texture but the axes and the shields don't have the proper color.

    the code:
    Code:
    7 england 
    78 unit_models/_Units/ES_Greek_Greek_Heavy/textures/mtw2_es_greek_england.texture 
    78 unit_models/_Units/EN_Peasant_Padded/textures/EN_Peasant_Padded_normal.texture 
    49 unit_sprites/england_Varangian_Guard_sprite.spr
    Last edited by lonck; 04-09-2008 at 11:12.
    How to unpack specific files to they respective folders:
    make a new .cmd in Medieval II Total War\tools\unpacker and put this inside after you right-click edit.
    Code:
    unpacker --source="..\..\packs\*.pack" --destination=..\..\--filter=[name of file goes here w/o brackets]

  19. #259

    Question Re: Tutorial - Adding a unit to the game

    Hello i am new to the modding world and I really appreciate these tutorials, but I have a little problem, I did a new unit for scotland, I used the look of a noble swordsmen and I changed his sword and shield for a 2h sword (the same one the highland nobles use) I did everything you say in the tutorial but when I start the game and do a custom battle I cant find my unit
    Ye pose your eyes on king Arthurs magical sword, Caledfwlch

  20. #260
    Death and Glory TW modder Member Flying Pig's Avatar
    Join Date
    Dec 2007
    Location
    Looking for a place to land...
    Posts
    313

    Default Re: Tutorial - Adding a unit to the game

    I copied the dismounted_GOTHIC_knights entry, changed the name tto heavy_alamanoi, and all the 1 3 hre entries into 1 9 byzantuim. But when I run it I get white knights. HELP, what's the problem?
    Death And Glory TW Needs You - Sign Up Now! All it takes is one PM!

    Ὦ ξεῖν', ἀγγέλλειν Λακεδαιμονίοις ὅτι τῇδε
    κείμεθα, τοῖς κείνων ῥήμασι πειθόμενοι.

    Ō zein', angellein Lakedaimoniois hoti tēide
    keimetha tois keinōn rhēmasi peithomenoi.

    Go, thou that passeth, to the Spartans tell
    That as per their orders, here we fell.

  21. #261
    Been there, conquered that.... Member Darkvicer98's Avatar
    Join Date
    Apr 2008
    Location
    UK
    Posts
    238

    Default Re: Tutorial - Adding a unit to the game

    I can't find the files to mod. I go to my M2TW directory and all i find is some data files, however there is 5 data pack files in the packs folder. I would like to try out these Dragoon's but i can't seem to find the files.
    Last edited by Darkvicer98; 08-18-2008 at 20:29.


    Cry HAVOC and let slip the dogs of War!

    A brave man may fall,but he cannot yield-Latin Proverb

    Arms keep peace-Latin Proverb

  22. #262

    Default Re: Tutorial - Adding a unit to the game

    Please help, I've been messing around with the battle_models thing for this group I'm making, I think I've got everything right on my other stuff. But, it still isn't working and I think something on this is the problem. Can anyone give me their advice?














    11 Aindrea_ug1 1 3 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug1_lod0.mesh 121 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug1_lod1.mesh 1225 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug1_lod2.mesh 6400 1 7

    Denmark 78 unit_models/_Units/ES_Greek_Greek_Heavy/textures/Aindrea.texture 65

    unit_models/_Units/ES_Greek_Greek_Heavy/textures/mtw2_es_greek_normal.texture 82

    unit_sprites/byzantium_Byzantine_Infantry_ug1_sprite.spr 1 7 Denmark 58

    unit_models/AttachmentSets/Final Kite_byzantium_diff.texture 60 unit_models/AttachmentSets/Final

    Kite_byzantium_norm.texture 0 1 4 None 14 MTW2_Swordsman 0 2 18 MTW2_Sword_Primary 14

    fs_test_shield 0 16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002
    11 Aindrea_ug2 1 3 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug2_lod0.mesh 121 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug2_lod1.mesh 1225 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug2_lod2.mesh 6400 1 7

    Denmark 78 unit_models/_Units/ES_Greek_Greek_Heavy/textures/Aindrea.texture 65

    unit_models/_Units/ES_Greek_Greek_Heavy/textures/mtw2_es_greek_normal.texture 82

    unit_sprites/byzantium_Dismounted_Byzantine_Lancers_ug2_sprite.spr 1 7 Denmark 58

    unit_models/AttachmentSets/Final Kite_byzantium_diff.texture 60 unit_models/AttachmentSets/Final

    Kite_byzantium_norm.texture 0 1 4 None 14 MTW2_Swordsman 0 2 18 MTW2_Sword_Primary 14

    fs_test_shield 0 16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002 11 Aindrea_ug3 1 3 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug3_lod0.mesh 121 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug3_lod1.mesh 1225 82

    unit_models/_Units/ES_Greek_Greek_Heavy/dismounted_byzantine_lancers_ug3_lod2.mesh 6400 1 7

    Denmark 78 unit_models/_Units/ES_Greek_Greek_Heavy/textures/Aindrea.texture 65

    unit_models/_Units/ES_Greek_Greek_Heavy/textures/mtw2_es_greek_normal.texture 82

    unit_sprites/byzantium_Dismounted_Byzantine_Lancers_ug3_sprite.spr 1 7 Denmark 58

    unit_models/AttachmentSets/Final Kite_byzantium_diff.texture 60 unit_models/AttachmentSets/Final

    Kite_byzantium_norm.texture 0 1 4 None 14 MTW2_Swordsman 0 2 18 MTW2_Sword_Primary 14

    fs_test_shield 0 16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002

  23. #263

    Default Re: Tutorial - Adding a unit to the game

    this is awesome
    just on thing though how can I get a missle unit (such as genoa crossbowmen) to have a super beastly arrow attack. like what should I change in Export_descr_unit?

  24. #264
    Finder of Little Oddities Senior Member Makanyane's Avatar
    Join Date
    Jan 2006
    Posts
    2,220

    Default Re: Tutorial - Adding a unit to the game

    you'd change the damage inflicted on other units by changing the units stats in Export_descr_unit

    did you mean that or the projectile animation?
    Not used mods before? Looking for something small and fun?!
    Download the:

  25. #265

    Default Re: Tutorial - Adding a unit to the game

    Hi everyone I have a problem with this ad the problem is that units are invisible! my files are as follows:

    Code:
    23 bosnian_peasant_archers 
    1 4 
    64 unit_models/_Units/ES_Peasant_Padded/s_peasant_archers_lod0.mesh 121 
    64 unit_models/_Units/ES_Peasant_Padded/s_peasant_archers_lod1.mesh 900 
    64 unit_models/_Units/ES_Peasant_Padded/s_peasant_archers_lod2.mesh 2500 
    64 unit_models/_Units/ES_Peasant_Padded/s_peasant_archers_lod3.mesh 6400 
    1 
    6 bosnia 
    71 unit_models/_Units/ES_Peasant_Padded/textures/ES_Peasant_bosnia.texture 
    71 unit_models/_Units/ES_Peasant_Padded/textures/ES_Peasant_normal.texture 
    47 unit_sprites/Bosnian_Peasant_Archers_sprite.spr
    1 
    6 bosnia 
    68 unit_models/AttachmentSets/Final European Archer_bosnia_diff.texture 
    68 unit_models/AttachmentSets/Final European Archer_bosnia_norm.texture 0  
    1 
    4 None 
    16 MTW2_Fast_Bowman 
    18 MTW2_Fast_Knifeman 1 
    19 MTW2_Bowman_Primary 1 
    18 MTW2_Knife_Primary 
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002
    Code:
    type             Bosnian Peasant Archers
    dictionary       Bosnian_Peasant_Archers      ; Bosnian Archers
    category         infantry
    class            missile
    voice_type       Light
    banner faction   main_missile
    banner holy      crusade
    soldier          S_Peasant_Archers, 48, 0, 0.8
    attributes       sea_faring, hide_forest, can_withdraw
    formation        1.2, 1.2, 2.4, 2.4, 4, square
    stat_health      1, 0
    stat_pri         5, 1, arrow, 120, 30, missile, missile_mechanical, piercing, none, 25, 1
    ;stat_pri_ex      0, 0, 0
    stat_pri_attr    no
    stat_sec         2, 1, no, 0, 0, melee, melee_simple, piercing, knife, 25, 1.8
    ;stat_sec_ex      0, 0, 0
    stat_sec_attr    no
    stat_pri_armour  0, 1, 0, flesh
    ;stat_armour_ex   0, 4, 0, 0, 1, 0, 0, flesh
    stat_sec_armour  0, 0, flesh
    stat_heat        0
    stat_ground      1, 0, 2, 0
    stat_mental      3, normal, untrained
    stat_charge_dist 30
    stat_fire_delay  0
    stat_food        60, 300
    stat_cost        1, 220, 100, 65, 50, 220, 4, 50
    armour_ug_levels 0, 1
    armour_ug_models Bosnian_Peasant_Archers
    ownership        bosnia
    era 0            bosnia
    era 1            bosnia
    era 2            bosnia
    ;unit_info        2, 5, 1

    Also where ever S Peasant Archers appeared in the 2export_descr_buildings.txt" I had dupicated it like this:
    From this:
    Code:
    recruit_pool "S Peasant Archers"  0   0.000001   0.999  0  requires factions { sicily, hungary, byzantium, }
    to this:
    Code:
    recruit_pool "Bosnian Peasant Archers"  0   0.000001   0.999  0  requires factions { bosnia, }
    Game doesn't crash but as I have already stated units are invisible for some reason, I have based this unit on a "S Peasant Archers" and cloned everything including scins etc... Any help would be greatly appreciated.

  26. #266

    Default Re: Tutorial - Adding a unit to the game

    I also I have tried this:

    A7b) If you're using a mymod and that's where your modded export_descr_units.txt file is and load the game through a shortcut to a .bat rather than the man launcher then --io.file_first must not only be in the shortcut command line , but also in the .bat .
    Find the mymod.bat {located in Program Files\SEGA\Medieval II Total War} , right click it , select edit from the menu and add --io.file_first to the end of the text therein {which is medieval2.exe @mymod.cfg } with a single space between them so it will then read medieval2.exe @mymod.cfg --io.file_first. save the file and close it and Bob's your Uncle .

    ...but no luck, any suggestions?

  27. #267
    Member Member Soul Reaver's Avatar
    Join Date
    Nov 2007
    Location
    England
    Posts
    24

    Default Re: Tutorial - Adding a unit to the game

    As you have added a unit you have to change the number at the top of the BMDB by one, this is the normal vanilla one yours might be different.
    22 serialization::archive 3 0 0 0 0 701 0 0
    Should read like this.
    22 serialization::archive 3 0 0 0 0 702 0 0

    There is really no need to edit the battlemodels file if you are using an existing unit, clone the said unit in the EDU and rename it like you have already done. As long as your faction has the correct textures there shouldn't be a problem.

  28. #268

    Default Re: Tutorial - Adding a unit to the game

    Hi, i have open norway faction in teuctonic campaign to playable, but i can't create units in norway cities, does anyone know how i can fix this??

Page 9 of 9 FirstFirst ... 56789

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Single Sign On provided by vBSSO