Page 2 of 4 FirstFirst 1234 LastLast
Results 21 to 40 of 82

Thread: How-to: make battle_models.MODELDB more readable

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Soulghast's Avatar RAWR!
    Join Date
    Oct 2006
    Location
    Athens, Greece
    Posts
    3,912

    Default Re: How-to: make battle_models.MODELDB more readable

    Quote Originally Posted by Ahiga View Post
    I found the issue I had. -0.090000004 0 0 -0.34999999 0.80000001 0.60000002 was not the end of the passage but rather the start. When I used it as an end I crashed, but when I started with it it works.
    What weapon are your knights carrying?
    Ex-Curator
    Under the Patronage of Perikles
    Patron of Desperado † and Astaroth


    R.I.P Calvin

  2. #2

    Default Re: How-to: make battle_models.MODELDB more readable

    I was trying to change faction ownership the noble pikemen from scotland to turks..I just edit the scotland line to the turks.. 18 turks ...It make my medieval got ctd..Please help how to i change the noble pike ownership to tukrs..Sorry for my bad english..Thanx

  3. #3
    kleemann's Avatar Libertus
    Join Date
    Jan 2006
    Location
    In EU (Estonia)
    Posts
    74

    Default Re: How-to: make battle_models.MODELDB more readable

    Quote Originally Posted by Ahiga View Post
    I found the issue I had. -0.090000004 0 0 -0.34999999 0.80000001 0.60000002 was not the end of the passage but rather the start. When I used it as an end I crashed, but when I started with it it works.
    Yes, you are right. It is in the beginning. My mistake.
    Trading tip: Load your mercants on your (crapy, cheap upkeep) unit and place that crapy unit on the valuable trade ressource. All will earn money on that single ressourec AND other merchants can't do anything! ha:ha

    BUT it has bad side efect, if the unit rebel you will lose your merchants :hmmm:

    How-to: edit battle_model.modeldb to add new animations and skins.

  4. #4
    Hans Kloss's Avatar J-23
    Join Date
    Oct 2004
    Location
    Richmond upon Thames
    Posts
    1,616

    Default Re: How-to: make battle_models.MODELDB more readable

    I got two questions in regards to battle_models file :

    1.How safe would it be to delete certain model entries? I'm currently working on adding units to newly created faction.I started off with adding new units/ replacing Norman's entries with new ones but I feel at one point I might go over some hardcoded limits.I have absolutly no need to variaty of units, specialy peasants so I would like get rid of them

    2.Teutonic Knights are using maces as secondary weapons but I rather have them with swords.Models of Templars and Hospitallers look almost identical so do you think it would be possible to switch models

  5. #5
    Hans Kloss's Avatar J-23
    Join Date
    Oct 2004
    Location
    Richmond upon Thames
    Posts
    1,616

    Default Re: How-to: make battle_models.MODELDB more readable

    I have tried to switch model of Teutonic with that of Templars - game will not even start.

    16:48:38.953 [system.rpt] [error] Medieval 2: Total War encountered an unspecified error and will now exit -right on the start up

  6. #6
    KnightErrant's Avatar Decanus
    Join Date
    Jan 2007
    Location
    Huntsville, Alabama USA
    Posts
    578

    Default Re: How-to: make battle_models.MODELDB more readable

    @Hans Kloss
    Regards hard-coded limits, don't know what this would
    be in the executable, but the number of units in the
    vanilla modeldb is 701. (Found by tornnight)
    If you add to the end it won't see them unless you
    change the entry. This is the first line

    22 serialization::archive 3 0 0 0 0 701 0 0

    As an experiment change 701 to 401 and run the game.
    It will get to the splash screen (meaning it read the modeldb
    file fine) but will CTD after that with a missing dictionary entry
    error meaning it didn't process all of your modeldb file.

    Just guessing but if there is a hard coded limit, maybe its a factor
    of 2 that's bigger than 701. Smallest one would be 1024 so
    MAYBE you are safe up to this limit? Just a guess.

  7. #7
    kleemann's Avatar Libertus
    Join Date
    Jan 2006
    Location
    In EU (Estonia)
    Posts
    74

    Default Re: How-to: make battle_models.MODELDB more readable

    Well as i have made experiments realised that weapon animations are hardcoded. The weapon section is the animation how the weapon is used. If i make Hospitallers to dismounted, then they have lances as swords and use these as swords..

    22 serialization::archive 3 0 0 0 0 701 0 0 i never changed this 701 number and i could add new units without any problems. I made new units like Templar crossbowmen, Dismounted Templars, Dismounted Hospitallers.
    Trading tip: Load your mercants on your (crapy, cheap upkeep) unit and place that crapy unit on the valuable trade ressource. All will earn money on that single ressourec AND other merchants can't do anything! ha:ha

    BUT it has bad side efect, if the unit rebel you will lose your merchants :hmmm:

    How-to: edit battle_model.modeldb to add new animations and skins.

  8. #8

    Default Re: How-to: make battle_models.MODELDB more readable

    Important Question:

    Which is to do thereby changes in the battle_models.modeldb becomes at all effective? In my test runs everything I changed was ignored. All was the same whether incorrect or correct entries. Finally I wrote "********" in the battle_models.modeldb to see whether the program accesses at all. Nothing happend - the game runs without any error.

    So what is to do, that the program use the battle_models.modeldb?

  9. #9
    Hans Kloss's Avatar J-23
    Join Date
    Oct 2004
    Location
    Richmond upon Thames
    Posts
    1,616

    Default Re: How-to: make battle_models.MODELDB more readable

    Apart from changes in battle_models, relevent entries in export_descr_unit need to be edited too.It is very easy to forget but formatted_battle_models needs to renamed battle_models that's speaking from my own personal experience

  10. #10
    Indefinitely Banned
    Join Date
    Jun 2006
    Location
    Calgary, Canada
    Posts
    13,967

    Default Re: How-to: make battle_models.MODELDB more readable

    Simple question:

    We over at Broken Crescent are making a new mod. Can we create our own "battlemodels.db" file from the ground up, of course following the same format as the original file? Is this ridiculously hard or impossible? Or is it just difficult but feasible?

    Another question is can this file and texture files be placed in the mod folder and accessed from there by the game?

    I ask cuz I would prefer to not have to edit existing factions and sift through the hundreds of things in this file.

    Thanks

    MIRAGE
    Last edited by Miraj; March 20, 2007 at 08:22 PM.

  11. #11
    Ordensritter's Avatar Civis
    Join Date
    Mar 2007
    Location
    Berlin, Germany
    Posts
    130

    Default Re: How-to: make battle_models.MODELDB more readable

    Quote Originally Posted by kleemann View Post
    Well as i have made experiments realised that weapon animations are hardcoded. The weapon section is the animation how the weapon is used. If i make Hospitallers to dismounted, then they have lances as swords and use these as swords..

    22 serialization::archive 3 0 0 0 0 701 0 0 i never changed this 701 number and i could add new units without any problems. I made new units like Templar crossbowmen, Dismounted Templars, Dismounted Hospitallers.
    It is very important to chance the number 701!
    This number displays the number of units at the game (including the numbers of new models for armour upgrade, like spearmen, spearmen_ug1, ...).
    If one add a new unit or armour upgrade you have to increase the number by the amount of new units/upgrades.
    E.g. you add the 2. armour upgrade for the templars and you don't increase the number by 1, you'll lost the textures of the last unit written at the modeldb. You get no CTD but these unit type is invisible.

  12. #12
    Condottiere SOG's Avatar Domesticus
    Join Date
    Dec 2006
    Location
    Oregon, USA
    Posts
    2,274

    Default Re: How-to: make battle_models.MODELDB more readable

    Will someone make this understandable to someone who speaks English with good spelling, please?

  13. #13

    Icon5 Re: How-to: make battle_models.MODELDB more readable

    Quote Originally Posted by Ordensritter View Post
    It is very important to chance the number 701!
    This number displays the number of units at the game (including the numbers of new models for armour upgrade, like spearmen, spearmen_ug1, ...).
    If one add a new unit or armour upgrade you have to increase the number by the amount of new units/upgrades.
    E.g. you add the 2. armour upgrade for the templars and you don't increase the number by 1, you'll lost the textures of the last unit written at the modeldb. You get no CTD but these unit type is invisible.
    Ok, so if I add Scottish Axmen for example, and an ug1 of that. I need to change that number to 703? 1 for each new unit + 1 for each armor upgrade?

  14. #14

    Default Re: How-to: make battle_models.MODELDB more readable

    kleemann i have added 1 unit from BC mod

    but when I add unit to recruit pool the game goes CTD and also when i Add unit to export_descr_unit also have a ctd

    the other things like battle_model and units info there was not a problem only when i add to recruit pool and
    export_descr_unit

    can you help me please


    this is how it looks like

    BC UNIT
    type ayyubid askari infantry
    dictionary ayyubid_askari_infantry ; ayyubid askari infantry
    category infantry
    class heavy
    voice_type Heavy
    accent Arabic
    banner faction main_infantry
    banner holy crusade
    soldier ayyubid_askari_infantry, 48, 0, 1.2
    attributes sea_faring, hide_forest, can_withdraw
    formation 1.2, 1.2, 2.4, 2.4, 4, square
    stat_health 1, 0
    stat_pri 6, 2, no, 0, 0, melee, melee_blade, piercing, sword, 20, 1
    stat_pri_attr no
    stat_sec 0, 0, no, 0, 0, no, melee_simple, blunt, none, 25, 1
    stat_sec_attr no
    stat_pri_armour 5, 6, 6, metal
    stat_sec_armour 0, 0, flesh
    stat_heat 4
    stat_ground 1, -2, 3, 2
    stat_mental 10, normal, highly_trained
    stat_charge_dist 20
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 1, 570, 250, 85, 65, 570, 4, 130
    armour_ug_levels 4
    armour_ug_models ayyubid_askari_infantry
    ownership egypt

    LANDS TO CONQEUR unit
    type Dismounted Tuareg
    dictionary Dismounted_Tuareg ; Dismounted Tuareg
    category infantry
    class spearmen
    voice_type Light
    banner faction main_spear
    banner holy crusade
    soldier Dismounted_Tuareg, 48, 0, 0.5
    attributes sea_faring, hide_forest, very_hardy, can_withdraw
    formation 1.2, 1.2, 2.4, 2.4, 3, square
    stat_health 1, 0
    stat_pri 11, 5, 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 0, 6, 8, flesh
    ;stat_armour_ex 0, 2, 0, 0, 6, 8, 6, flesh
    stat_sec_armour 0, 0, flesh
    stat_heat 0
    stat_ground 1, 2, 0, -4
    stat_mental 9, normal, trained
    stat_charge_dist 15
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 1, 460, 150, 60, 140, 460, 4, 130
    armour_ug_levels 0, 1
    armour_ug_models Dismounted_Tuareg, Dismounted_Tuareg_ug1
    ownership moors
    era 0 moors
    era 1 moors
    ;unit_info 11, 0, 14
    recruit_priority_offset 10





  15. #15
    tornnight's Avatar Forum Bot
    Join Date
    Dec 2006
    Location
    Virginia, U.S.A.
    Posts
    1,755

    Default Re: How-to: make battle_models.MODELDB more readable

    Take a look at the TLR forums for a new Mod_Tool. It can beautify this file while syntax checking it at the same time.
    "The first casualty when war comes, is truth." - Hiram Johnson
    Developer of The Long Road Modification

  16. #16
    Condottiere SOG's Avatar Domesticus
    Join Date
    Dec 2006
    Location
    Oregon, USA
    Posts
    2,274

    Default Re: How-to: make battle_models.MODELDB more readable

    Ok, thanks. Got it!

  17. #17

    Default Re: How-to: make battle_models.MODELDB more readable

    1 thing is ure. People at CA have been so stupid to complicate things. RTW was easier to mod!!!

  18. #18

    Default Re: How-to: make battle_models.MODELDB more readable

    Hey man in the first post there is this line

    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002 (<- positsion or something, pony has all 0-s entry )

    what does it mean? If I add another unit should I change it or not?
    And what about horses? I haven't understood this quite well...

  19. #19

    Default Re: How-to: make battle_models.MODELDB more readable

    I have read over at .org and probably start understanding this complicated mechanism..
    Where to find the latest model_units.modeldb formatted from MTWII updated to 1.3?
    Is there one for Kingdoms 1.5 too?

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

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    52,679
    Blog Entries
    35

    Default Re: How-to: make battle_models.MODELDB more readable

    Quote Originally Posted by Hospitalier Grand Master View Post
    I have read over at .org and probably start understanding this complicated mechanism..
    Where to find the latest model_units.modeldb formatted from MTWII updated to 1.3?
    Is there one for Kingdoms 1.5 too?
    Check the thread next door: it is for Kingdoms 1.3, all campaigns.










Page 2 of 4 FirstFirst 1234 LastLast

Posting Permissions

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