Results 1 to 19 of 19

Thread: Export_descr_buildings File

Hybrid View

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

    Default Export_descr_buildings File

    Does anyone have the export_descr_buldings, that they have modified to make early era units recruitable later in the game. I understand the aim was to make the Al create better armies in the late era, but I really hate not being able to recruit the early era untis, but everytime I try to modify the file, and I try to start the game, I get a CTD. I always screw something up. Any help would be greatly appreciated! Thanks!

  2. #2
    Henry of Grosmont's Avatar Clockwork Angel
    Join Date
    Dec 2004
    Location
    Xanadu
    Posts
    5,078

    Default Re: Export_descr_buildings File

    If you want to tweak the game, try the Workshop.
    In the meantime, I'll just say that it's quite easy. The idea is to keep the early units in the list of the upgraded buildings.

  3. #3

    Default Re: Export_descr_buildings File

    I have tried, and every time I do it, I copy and paste the earlier units to the later buildings and right afterwards I try to load the game and I get a CTD. I have tried 3 different time with the same results.

  4. #4
    Henry of Grosmont's Avatar Clockwork Angel
    Join Date
    Dec 2004
    Location
    Xanadu
    Posts
    5,078

    Default Re: Export_descr_buildings File

    I will need to know what's the error causing CTD in your system.log.txt file.

  5. #5

    Default Re: Export_descr_buildings File

    Would it be possible for you to mod the file for me?

  6. #6

    Default Re: Export_descr_buildings File

    This is the message that shows up on the system log, and all I did was add the units back recruitable when you upgrade castles and cities just as it is in vanilla:

    19:50:28.252 [system.rpt] [always] CPU: SSE2
    19:50:28.252 [system.rpt] [always] ==== system log start, build date: Aug 3 2007 version bld-medieval2-kingdoms-104 (45562) ===
    19:50:28.314 [system.io] [always] mounted pack packs/data_0.pack
    19:50:28.376 [system.io] [always] mounted pack packs/data_1.pack
    19:50:28.439 [system.io] [always] mounted pack packs/data_2.pack
    19:50:28.564 [system.io] [always] mounted pack packs/data_3.pack
    19:50:28.642 [system.io] [always] mounted pack packs/data_4.pack
    19:50:28.688 [system.io] [always] mounted pack packs/localized.pack
    19:50:28.922 [system.io] [warning] open: mods/kingdoms_grand_campaign_mod/data/text/shortcut.txt.strings.bin is missing
    19:50:28.922 [system.io] [warning] open: mods/kingdoms_grand_campaign_mod/data/text/shortcut.txt is missing
    19:50:33.478 [data.missing] [warning] missing/invalid cursor for ANISELECT
    19:50:33.540 [data.missing] [warning] missing/invalid cursor for MODIFIER_SABOTAGE
    19:50:33.571 [data.missing] [warning] missing/invalid cursor for MODIFIER_TRADE
    19:50:33.852 [data.missing] [warning] missing/invalid cursor for DRAGGABLE
    19:50:33.852 [data.missing] [warning] missing/invalid cursor for DRAGGING
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_MULTIPLE_SELECT
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_ATTACK
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_CHARACTER
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_RESOURCE
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_FORT
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_MOVE_OBJECT
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_WATCHTOWER
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_DEPLOYMENT_AREA
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_TILE
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_SPECIAL_PIECE
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_PAINT
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_ADJUST_HEIGHTS
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_ADD_UNIT
    19:50:33.899 [data.missing] [warning] missing/invalid cursor for MODIFIER_PLACE_SETTLEMENT
    19:50:35.619 [system.io] [warning] open: mods/kingdoms_grand_campaign_mod/data/text/climates.txt.strings.bin is missing
    19:50:35.629 [system.io] [warning] open: mods/kingdoms_grand_campaign_mod/data/text/climates.txt is missing
    19:50:40.899 [system.io] [warning] open: mods/kingdoms_grand_campaign_mod/data/text/event_titles.txt.strings.bin is missing
    19:50:40.899 [system.io] [warning] open: mods/kingdoms_grand_campaign_mod/data/text/event_titles.txt is missing
    19:50:41.279 [system.io] [warning] open: mods/kingdoms_grand_campaign_mod/data/text/rebel_faction_descr.txt.strings.bin is missing
    19:50:41.309 [system.io] [warning] open: mods/kingdoms_grand_campaign_mod/data/text/rebel_faction_descr.txt is missing
    19:50:41.519 [script.err] [error] Script Error in mods/kingdoms_grand_campaign_mod/data/export_descr_buildings.txt, at line 85, column 140
    Expected faction or culture type, or 'all' - faction or culture type could be wrong; terminate list with comma; enclose list in {}

  7. #7

    Default Re: Export_descr_buildings File

    I see "Normans". Change that to "normans".

    Did you selectively paste parts of the EDB? Different buildings must have that "plugins" part between them.

    Also, the next time you post something like this, put [spoiler] tags around the text.

  8. #8

    Default Re: Export_descr_buildings File

    All I did was copy and paste the units from the vanilla version over to the mod file

  9. #9

    Default Re: Export_descr_buildings File

    What exactly are you trying to accomplish? Do you want ALL units to stay available throughout the entire game? If so then let me know and I can whip out the EDB for you real quick to make this easier for you...Also, are you using v4.3?

    I notice some capitalized faction names and all those should be lower case, which could very well be the issue so try fixing those first and if that doesn't work then I can mod one for ya pretty quickly....

  10. #10

    Default Re: Export_descr_buildings File

    I am trying to do exactly as you just said, trying to keep all the units recruitable the whole game. I would really appreciate it if you could mod it for me. Thanks for all the help

  11. #11

    Default Re: Export_descr_buildings File

    The way to stop units from being recruitable after a certain year is to either use "and not event_counter certainyear", or to make the available unit pool smaller than 1 after that year.

    I don't see any "and not event_counter"s, except the "not_pagan_lithuania" ones. See what happens if you delete that part.

    Make lines like this

    citadel castle requires factions { northern_european, middle_eastern, eastern_european, greek, southern_european, } and event_counter not_pagan_lithuania 1

    Into this

    citadel castle requires factions { northern_european, middle_eastern, eastern_european, greek, southern_european, }


    Also, change lines like this

    recruit_pool "EE Spear Militia" 0 0.000001 0.999 0 requires factions { poland, russia, hungary, }

    To

    recruit_pool "EE Spear Militia" 1 0.25 2 0 requires factions { poland, russia, hungary, }


    Do the second part first. If that doesn't work, do the first as well.
    Last edited by k/t; February 20, 2012 at 02:24 PM.

  12. #12
    Vipman's Avatar Protector Domesticus
    Join Date
    Jul 2010
    Location
    Romania
    Posts
    4,405

    Default Re: Export_descr_buildings File

    Quote Originally Posted by k/t View Post
    The way to stop units from being recruitable after a certain year is to either use "and not event_counter certainyear", or to make the available unit pool smaller than 1 after that year.

    I don't see any "and not event_counter"s, except the "not_pagan_lithuania" ones. See what happens if you delete that part.
    He wants all units to remain. You got it wrong, the units don't disappear at a certain year, they disappear when you build next level of barracks. for example town militia is in first 2 levels of barracks, but at level 3 it's no more.

    This is a simple thing to do, but it's a lot to copy/paste and it takes time. You have to find out which units disappear, copy the recruitment pool lines for those units and paste at the next levels of that building that don't have them.


    Also speaking about EDB and "not_pagan_lithuania" , i want to ask a question about it.

    I currently have KGCM with HS patch, but it seems it's the same as original.

    By playing in a HS (with HRE) i found out i can't upgrade to large city, nor citadel, and i can't build any church, and neither shipwright.

    So i found out that the "not_pagan_lithuania" requirement is added to these buildings, so this makes unavailable for ALL factions to build them unless Lithuania converts to catholic. In my game lithuania is pagan and has only 1 region. I hope the conversion script comes in and resolves it... BTW if lithuania is whiped out it wouldn't resolve the issue, right?

    It probably was meant only for lithuania to have advanced buildings when they convert, but i think it's done wrong.

    But if this is a problem of the mod, why no-one found out about this and point this out to the modders?????

  13. #13
    Stylix's Avatar MOS Team Member
    Join Date
    Apr 2008
    Location
    Alabama, U.S.A.
    Posts
    2,263

    Default Re: Export_descr_buildings File

    @vipman
    I have not checked v4.3 yet, but in v4.2 the event counter "not_pagan_lithuania" is set to 1 at the beginning of each turn for each faction except for Lithuania.
    Spoiler Alert, click show to read: 

    Code:
     
    ;------------------- TECHTREE -------------------;
     
     monitor_event PreFactionTurnStart not FactionType lithuania
      and not FactionType teutonic_order
     
      set_event_counter pagan_lithuania 0
      set_event_counter not_pagan_lithuania 1
      set_event_counter not_teutonic 1
     
     end_monitor
     
     monitor_event PreFactionTurnStart FactionType lithuania
     
      set_event_counter pagan_lithuania 1
      set_event_counter not_pagan_lithuania 0
      set_event_counter not_teutonic 1
     
      if I_EventCounter lithuania_conversion_accepted = 1
       set_event_counter pagan_lithuania 0
       set_event_counter not_pagan_lithuania 1
      end_if
     
     
     end_monitor
     
     monitor_event PreFactionTurnStart FactionType teutonic_order  
     
      set_event_counter not_teutonic 0
      set_event_counter pagan_lithuania 0
      set_event_counter not_pagan_lithuania 1
     
     end_monitor
     
     ;set counters on FactionTurnStart once only to ensure correct tech tree options are present at turn 0
     
     monitor_event FactionTurnStart not FactionType lithuania
      and not FactionType teutonic_order
     
      set_event_counter pagan_lithuania 0
      set_event_counter not_pagan_lithuania 1
      set_event_counter not_teutonic 1
     
      terminate_monitor
     
     end_monitor
     
     monitor_event FactionTurnStart FactionType lithuania
     
      set_event_counter pagan_lithuania 1
      set_event_counter not_pagan_lithuania 0
      set_event_counter not_teutonic 1
     
      if I_EventCounter lithuania_conversion_accepted = 1
       set_event_counter pagan_lithuania 0
       set_event_counter not_pagan_lithuania 1
      end_if
     
      terminate_monitor
     
     end_monitor
     
     monitor_event FactionTurnStart FactionType teutonic_order  
     
      set_event_counter not_teutonic 0
      set_event_counter pagan_lithuania 0
      set_event_counter not_pagan_lithuania 1
      
      terminate_monitor
     
     end_monitor

    I have not had any problems building churches as any faction in v4.2 or in any region.

    Edit: I installed v4.3 again and have not had any problems building churches. Did you make any changes to the campaign_script.txt file? If not could you provide a detailed description and screen shots of this occurance, including which faction(s) is/are involved?
    Last edited by Stylix; February 25, 2012 at 03:15 PM.
    MOS v1.6.2+ Bug fixer 30 Dec 2013

  14. #14
    Vipman's Avatar Protector Domesticus
    Join Date
    Jul 2010
    Location
    Romania
    Posts
    4,405

    Default Re: Export_descr_buildings File

    Quote Originally Posted by Stylix View Post
    @vipman
    I have not checked v4.3 yet, but in v4.2 the event counter "not_pagan_lithuania" is set to 1 at the beginning of each turn for each faction except for Lithuania.
    Spoiler Alert, click show to read: 

    Code:
     
    ;------------------- TECHTREE -------------------;
     
     monitor_event PreFactionTurnStart not FactionType lithuania
      and not FactionType teutonic_order
     
      set_event_counter pagan_lithuania 0
      set_event_counter not_pagan_lithuania 1
      set_event_counter not_teutonic 1
     
     end_monitor
     
     monitor_event PreFactionTurnStart FactionType lithuania
     
      set_event_counter pagan_lithuania 1
      set_event_counter not_pagan_lithuania 0
      set_event_counter not_teutonic 1
     
      if I_EventCounter lithuania_conversion_accepted = 1
       set_event_counter pagan_lithuania 0
       set_event_counter not_pagan_lithuania 1
      end_if
     
     
     end_monitor
     
     monitor_event PreFactionTurnStart FactionType teutonic_order  
     
      set_event_counter not_teutonic 0
      set_event_counter pagan_lithuania 0
      set_event_counter not_pagan_lithuania 1
     
     end_monitor
     
     ;set counters on FactionTurnStart once only to ensure correct tech tree options are present at turn 0
     
     monitor_event FactionTurnStart not FactionType lithuania
      and not FactionType teutonic_order
     
      set_event_counter pagan_lithuania 0
      set_event_counter not_pagan_lithuania 1
      set_event_counter not_teutonic 1
     
      terminate_monitor
     
     end_monitor
     
     monitor_event FactionTurnStart FactionType lithuania
     
      set_event_counter pagan_lithuania 1
      set_event_counter not_pagan_lithuania 0
      set_event_counter not_teutonic 1
     
      if I_EventCounter lithuania_conversion_accepted = 1
       set_event_counter pagan_lithuania 0
       set_event_counter not_pagan_lithuania 1
      end_if
     
      terminate_monitor
     
     end_monitor
     
     monitor_event FactionTurnStart FactionType teutonic_order  
     
      set_event_counter not_teutonic 0
      set_event_counter pagan_lithuania 0
      set_event_counter not_pagan_lithuania 1
      
      terminate_monitor
     
     end_monitor

    I have not had any problems building churches as any faction in v4.2 or in any region.

    Edit: I installed v4.3 again and have not had any problems building churches. Did you make any changes to the campaign_script.txt file? If not could you provide a detailed description and screen shots of this occurance, including which faction(s) is/are involved?
    Ah, i should have read better that, i didn't realize that part of script enables non-lithuania player factions to have it triggered...

    I said that i am playing in a HS with 4.2(?) and HS patch... Now i tested and started a new HS and a single-player campaign, both doesn't show this problem. Then it must be a problem of the HS... The HS started at turn 100 after all factions i think were controlled by AI... I don't think Hurin changed the files, my mod is original 4.2 plus HS patch without modifications, if Hurin modified some files then shouldn't my game crash when i load the save? It might be something about that the factions were ai controlled first, then switched to human... Lithuania is not a human faction, it's ai from the beggining, now has 1 region and is pagan...

    Here is the save from the start of the HS, there are no passwords yet. All factions can't build large walls, citadels, shipwrights, and the catholic factions can't build churches.

    No matter what is the source problem, i don't think it's repairable now.

    What i really want to know is if the AI controlled Lithuania will convert by itself and the problem will be solved. When the conversion script should kick in? the requirements are met (just 1 region), but i don't know what's with the conversion_timer? it needs 50, and the 75 for a chance of conversion to appear...
    Also, but less likely, will destroying lithuania launch the trigger??

    Thank you in advance for any help.
    Last edited by Vipman; November 17, 2012 at 01:28 PM.

  15. #15
    Stylix's Avatar MOS Team Member
    Join Date
    Apr 2008
    Location
    Alabama, U.S.A.
    Posts
    2,263

    Default Re: Export_descr_buildings File

    @vipman
    Sorry, but I really can't answer any questions about the HS version at this time because I do not have it installed. I have played in several HS games in the past and don't recall this being an issue. I suggest that you post this question in the HS forum and see if anyone else has encountered this problem.

    In KGCM v4.3 the AI can convert from its pagan status on or after turn 35 if it has less than 5 regions and on or after turn 65 regardless of the number of factions.
    If I read the code correctly it has a 66.6% (assuming that the generate_random_counter only produces whole numbers) chance per turn of converting.
    Spoiler Alert, click show to read: 
    Code:
    monitor_event FactionTurnStart FactionType lithuania
     
      if I_NumberOfSettlements lithuania < 5
       and I_EventCounter lithuania_conversion_timer >= 35
       and I_EventCounter lithuania_conversion_accepted = 0
     
       ;offer conversion to christianity
       historic_event lithuania_conversion true factions { lithuania, }
     
       ;if AI random chance to accept
       if I_IsFactionAIControlled lithuania
     
    generate_random_counter random_accept 0 2
    if I_EventCounter random_accept < 2
     set_event_counter lithuania_conversion_accepted 1
    end_if
     
    end_if
     
       terminate_monitor
     
      end_if
     
      if I_EventCounter lithuania_conversion_timer >= 65
       and I_EventCounter lithuania_conversion_accepted = 0
     
       ;offer conversion to christianity
       historic_event lithuania_conversion true factions { lithuania, }
     
       ;if AI random chance to accept
       if I_IsFactionAIControlled lithuania
     
    generate_random_counter random_accept 0 2
    if I_EventCounter random_accept < 2
     set_event_counter lithuania_conversion_accepted 1
    end_if
     
    end_if
     
       terminate_monitor
     
      end_if
     
     end_monitor


    The status of Lithuania should not prevent any other faction from producing units or buildings because the script sets the not_pagan_lithuania counter to 1 before each factions turn.
    Last edited by Stylix; February 26, 2012 at 09:19 AM.
    MOS v1.6.2+ Bug fixer 30 Dec 2013

  16. #16

    Default Re: Export_descr_buildings File

    Here is an EDB file where all units will remain recruit-able all the way up the building tree's...if you happen to notice any units that aren't doing this then let me know and I can fix it up real quick...

  17. #17

    Default Re: Export_descr_buildings File

    I see Town Militia has a pool of 2 all the way down, while Spear Militia never appears.

Posting Permissions

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