Results 1 to 20 of 20

Thread: Rebels and mercs

Hybrid View

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

    Default Rebels and mercs

    I want to delete mercs and rebels from vanilla and add those from my mod. What files except for EDU and EDB should i check?

  2. #2

    Default Re: Rebels and mercs

    In the imperial_campaign folder, campaign_script, descr_strat, descr_mercenaries, and descr_rebel_factions in the main folder.

  3. #3

    Default Re: Rebels and mercs

    Quote Originally Posted by meliritos View Post
    I want to delete mercs and rebels from vanilla and add those from my mod. What files except for EDU and EDB should i check?
    Rebels and mercs don't have entries in EDB, rebels have in descr_rebel_factions.txt and mercs in descr_mercenaries.txt, don't forget the export_units.txt file as well.

  4. #4

    Default Re: Rebels and mercs

    Ok i must be doing sth wrong here because with mercs i have a problem

    I have this in EDU

    Spoiler Alert, click show to read: 
    type Batroc
    dictionary Batroc ; Batroc
    category infantry
    class light
    voice_type Light
    banner faction main_infantry
    banner holy crusade
    soldier Batroc, 60, 0, 0.8
    attributes sea_faring, hide_forest, can_withdraw, mercenary_unit
    formation 1.2, 1.2, 2.4, 2.4, 6, square
    stat_health 1, 0
    stat_pri 2, 1, no, 0, 0, melee, melee_simple, piercing, knife, 25, 1.8
    ;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, 1, 0, flesh
    ;stat_armour_ex 0, 4, 0, 0, 1, 0, 0, flesh
    stat_sec_armour 0, 0, flesh
    stat_heat 2
    stat_ground 1, -2, 3, 2
    stat_mental 3, impetuous, untrained
    stat_charge_dist 30
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 1, 120, 90, 75, 60, 120, 4, 30
    armour_ug_levels 0
    armour_ug_models Batroc
    ownership slave
    era 0 slave
    era 1 slave
    era 2 slave
    ;unit_info 2, 0, 1


    and i have this in modeldb

    Spoiler Alert, click show to read: 
    6 Batroc
    1 4
    41 unit_models/_Units/mercs/Batroc_lod0.mesh 121
    41 unit_models/_Units/mercs/Batroc_lod1.mesh 900
    41 unit_models/_Units/mercs/Batroc_lod2.mesh 2500
    41 unit_models/_Units/mercs/Batroc_lod3.mesh 6400
    1
    4 merc
    52 unit_models/_Units/mercs/textures/Batroc.texture
    59 unit_models/_Units/mercs/textures/Batroc_normal.texture
    48 unit_sprites/scotland_Highland_Rabble_sprite.spr
    1
    4 merc
    49 unit_models/AttachmentSets/Daredevil_diff.texture
    49 unit_models/AttachmentSets/Daredevil_norm.texture 0
    1
    4 None
    18 MTW2_Fast_Knifeman 0
    1
    18 MTW2_Knife_Primary 0
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002


    I have the unit in a unit models folder under mercs file and the texture.

    For now i thought i would put him in Scotland region just to run the test
    Spoiler Alert, click show to read: 

    pool Scotland_Ireland
    regions Inverness_Province Edinburgh_Province Dublin_Province
    unit merc cog, exp 0 cost 200 replenish 0.36 - 1.0 max 1 initial 1 religions { catholic } crusading
    unit merc cog, exp 0 cost 1000 replenish 0.02 - 0.10 max 1 initial 1
    unit Mercenary Crossbowmen exp 0 cost 860 replenish 0.04 - 0.13 max 2 initial 1
    unit Batroc exp 0 cost 380 replenish 0.06 - 0.18 max 3 initial 1
    unit Irish Kerns Mercs exp 0 cost 380 replenish 0.06 - 0.18 max 3 initial 1
    unit Galloglaich Mercs exp 0 cost 830 replenish 0.04 - 0.13 max 2 initial 0
    unit Mercenary Ribault exp 0 cost 600 replenish 0.02 - 0.04 max 1 initial 0 events { gunpowder_discovered }
    unit Pilgrims exp 0 cost 35 replenish 0.18 - 0.5 max 4 initial 1 religions { catholic } crusading
    unit Crusader Sergeants exp 0 cost 110 replenish 0.15 - 0.35 max 2 initial 1 end_year 1300 religions { catholic } crusading


    and i get this error message that says it cannot get attributes for model Batroc in EDU, although as you can see attributes are there. My only guess is that i should have registered this unit elsewhere as well and i didnt so i get the error message. What am i doing wrong?

  5. #5

    Default Re: Rebels and mercs

    No those are the only files that you need and i can't see any problem in the code unfortunately.

    Eothese do you see anything peculiar in the code bro?

  6. #6
    Moon's Avatar Centenarius
    Join Date
    Oct 2008
    Location
    The dark side
    Posts
    878

    Default Re: Rebels and mercs

    Recreated this slightly different to the OP and it works
    EDU
    Spoiler Alert, click show to read: 
    type Batroc
    dictionary Batroc ; Highland Rabble
    category infantry
    class light
    voice_type Light
    banner faction main_infantry
    banner holy crusade
    soldier Batroc, 60, 0, 0.8
    attributes sea_faring, hide_forest, can_withdraw, mercenary_unit
    formation 1.2, 1.2, 2.4, 2.4, 4, square
    stat_health 1, 0
    stat_pri 3, 1, no, 0, 0, melee, melee_simple, piercing, knife, 25, 1.8
    ;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, 2, 0, flesh
    ;stat_armour_ex 0, 2, 0, 0, 2, 0, 0, flesh
    stat_sec_armour 0, 0, flesh
    stat_heat 4
    stat_ground 1, -2, 3, 4
    stat_mental 3, impetuous, untrained
    stat_charge_dist 30
    stat_fire_delay 0
    stat_food 60, 300
    stat_cost 1, 120, 90, 55, 135, 120, 4, 30
    armour_ug_levels 0, 1
    armour_ug_models Batroc
    ownership slave
    ;unit_info 3, 0, 2
    recruit_priority_offset 0


    BMDB
    Spoiler Alert, click show to read: 
    6 batroc
    1 4
    49 unit_models/_Units/EN_Highlander/batroc_lod0.mesh 121
    49 unit_models/_Units/EN_Highlander/batroc_lod1.mesh 900
    49 unit_models/_Units/EN_Highlander/batroc_lod2.mesh 2500
    49 unit_models/_Units/EN_Highlander/batroc_lod3.mesh 6400
    2
    5 slave
    69 unit_models/_Units/EN_Highlander/textures/en_highlander_mercs.texture
    76 unit_models/_Units/EN_Highlander/textures/en_highlander_mercs_normal.texture
    41 unit_sprites/slave_Irish_Kerns_sprite.spr
    4 merc
    69 unit_models/_Units/EN_Highlander/textures/en_highlander_mercs.texture
    76 unit_models/_Units/EN_Highlander/textures/en_highlander_mercs_normal.texture
    40 unit_sprites/merc_Irish_Kerns_sprite.spr
    2
    5 slave
    66 unit_models/AttachmentSets/Final European Light_slave_diff.texture
    66 unit_models/AttachmentSets/Final European Light_slave_norm.texture 0
    4 merc
    65 unit_models/AttachmentSets/Final European Light_merc_diff.texture
    65 unit_models/AttachmentSets/Final European Light_merc_norm.texture 0
    1
    4 None
    18 MTW2_Fast_Knifeman 0
    1
    18 MTW2_Knife_Primary 0
    16 -0.090000004 0 0 -0.34999999 0.80000001 0.60000002

  7. #7

    Default Re: Rebels and mercs

    Hm i had that suspicion as well and was going to say it but then i saw example without slave BMDB entry so i thought that wasn't it.
    Code:
    24 mercenary_german_knights 
    1 3 
    69 unit_models/_Units/EN_Pplate_Plate/mercenary_german_knights_lod0.mesh 121 
    69 unit_models/_Units/EN_Pplate_Plate/mercenary_german_knights_lod1.mesh 1225 
    69 unit_models/_Units/EN_Pplate_Plate/mercenary_german_knights_lod2.mesh 6400 
    1 
    4 merc 
    72 unit_models/_Units/EN_Pplate_Plate/textures/mtw2_EN_Pplate_mercs.texture 
    73 unit_models/_Units/EN_Pplate_Plate/textures/mtw2_EN_Pplate_normal.texture 
    55 unit_sprites/merc_Dummy_EN_Plate_Knights_ug1_sprite.spr 
    1 
    4 merc 
    64 unit_models/AttachmentSets/Final Special Heads_merc_diff.texture 
    64 unit_models/AttachmentSets/Final Special Heads_merc_norm.texture 0  
    1 
    5 Horse 
    13 MTW2_HR_Lance 
    12 MTW2_HR_Mace 2 
    21 MTW2_HR_Lance_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
    Vanilla entry that i saw.
    Last edited by Ishan; April 05, 2011 at 01:31 PM.

  8. #8

    Default Re: Rebels and mercs

    I concur, an EDU entry with the mercenary_unit attribute only needs the one texture ref in the .db for merc.
    The string counts are wrong, but the error log sounds as if it may be failing before that point...
    48 unit_models/_Units/mercs/textures/Batroc.texture
    55 unit_models/_Units/mercs/textures/Batroc_normal.texture
    Post the log entry if that does not fix it.

  9. #9

    Default Re: Rebels and mercs

    Thanks Eothese for confirming it.
    @meliritos
    Damnit bro use modeldb checker for eliminating string count errors.

  10. #10
    Moon's Avatar Centenarius
    Join Date
    Oct 2008
    Location
    The dark side
    Posts
    878

    Default Re: Rebels and mercs

    I concur too, it was a quick copy\paste of the Irish Kerns BMDB texture entries.

  11. #11

    Default Re: Rebels and mercs

    If the string error was the only one then that doesnt do it since i had detected the mistake and corrected it before you had seen it. I dont know if it needs entries for slaves as well as mercs for the textures to work, i will try it when i get home tonight and i will try Eothese entries as well.

    Gigantus had mentioned that my EDU may have formatting problems but he is not here to explain further...

    By the way what is an OP Eothese?
    Last edited by meliritos; April 05, 2011 at 08:42 PM.

  12. #12

    Default Re: Rebels and mercs

    OP=Opening Post\Poster
    Any error in EDU will be logged.
    Any crucial error in BMDB will not start your game and CTD firsthand.

  13. #13

    Default Re: Rebels and mercs

    23:35:38.250 [system.rpt] [always] CPU: SSE2
    23:35:38.250 [system.rpt] [always] ==== system log start, build date: Feb 25 2008 version development ===
    23:35:38.250 [system.io] [always] mounted pack packs/data_0.pack
    23:35:38.250 [system.io] [always] mounted pack packs/data_1.pack
    23:35:38.265 [system.io] [always] mounted pack packs/data_2.pack
    23:35:38.265 [system.io] [always] mounted pack packs/data_3.pack
    23:35:38.265 [system.io] [always] mounted pack packs/data_4.pack
    23:35:38.265 [system.io] [always] mounted pack packs/localized.pack
    23:38:17.296 [data.invalid] [error] DATABASE_TABLE error found : unrecognised record id Bosnian Archers requested.

    23:38:17.296 [data.invalid] [error] DATABASE_TABLE error found : unrecognised record id Bosnian Archers requested.

    23:38:28.406 [data.invalid] [error] World creation error: couldn't find unit description for unit type 'Norse Archers'.
    23:38:28.406 [script.err] [error] Script Error in mods/Bare_Geomod/data/world/maps/campaign/imperial_campaign/descr_strat.txt, at line 2296, column 1
    Could not create(Norse Archers) from the unit database.
    23:38:28.406 [script.err] [error] Script Error in mods/Bare_Geomod/data/world/maps/campaign/imperial_campaign/descr_strat.txt, at line 2296, column 1
    Unable to create new army

  14. #14

    Default Re: Rebels and mercs

    but it worked better than before, i will try to track down the errors ... Eothese you either tell me what you changed or i give you to code the rest of the mercs in, what do you say?

  15. #15

    Default Re: Rebels and mercs

    Sure thing, I changed the values of the string counts to match the length of the string...
    Simple as that.

  16. #16

    Default Re: Rebels and mercs

    Then i guess IT IS some formatting error as Gigantus said, because i had done that myself before you told me and it didnt work. Apart from the campaign script for the second error any idea where i should be looking for for the first one?

  17. #17

    Default Re: Rebels and mercs

    Just so you know there has to be a space after every line check my code above for German knights.^
    Without spaces sometimes it can cause problems.

  18. #18

    Default Re: Rebels and mercs

    I'd look at EDU and the Bosnian Archers unit, then check the Norse Archers, just follow on from one file to the next...

  19. #19

    Default Re: Rebels and mercs

    Yeah, i am beginning to get the essentials of coding. I checked some mistakes and when i start the campaign now it loads without errors. Even added one more unit, i will continue with the rest, although i dont know if i run into some problems in the future with all these units i am deleting

  20. #20

    Default Re: Rebels and mercs

    Quote Originally Posted by meliritos View Post
    Yeah, i am beginning to get the essentials of coding. I checked some mistakes and when i start the campaign now it loads without errors. Even added one more unit, i will continue with the rest, although i dont know if i run into some problems in the future with all these units i am deleting
    Removing units is no big deal read this post i posted a while back to a guy who had no idea on modding. Once the unit is gone and your game loads up fine it can never give you headaches later on reset assured bro.

Posting Permissions

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