Page 1 of 33 123456789101126 ... LastLast
Results 1 to 20 of 654

Thread: 12 turns per year with proper aging

  1. #1
    GrnEyedDvl's Avatar Liberalism is a Socially Transmitted Disease
    Artifex Technical Staff

    Join Date
    Jan 2007
    Location
    Denver CO
    Posts
    23,844
    Blog Entries
    10

    Default 12 turns per year with proper aging

    I have reworked my original 12 Turns per Year script into several variations for both M2TW and for Kingdoms. Included are 24 variations of the original script, broken into 4, 6, and 12 turns per year.

    Base script:
    This is the basic script, just drop it into any working M2 or Kingdoms mod folder and set the start_date and timescale in descr_strat.txt properly and it will run fine. Obviously use the Kingdoms version for Kingdoms and the M2 version for regular M2TW.

    12 Turns per Year:
    start_date has to be winter
    timescale has to be 0.0835

    The 12 Turns per Year version is broken into 12 months. Characters age in December.
    January - winter
    February - winter
    March - summer
    April - summer
    May - summer
    June - summer
    July - summer
    August - summer
    September - summer
    October - winter
    November - winter
    December - winter


    6 Turns per Year
    start_date has to be winter
    timescale has to be 0.167

    The 6 Turns per Year script is broken into 6 periods. Characters age in Jan-Feb
    Jan-Feb - winter
    March-April - summer
    May-June - summer
    July-August - summer
    Sept-Oct - summer
    Nov-Dec - winter


    4 Turns per Year
    start_date has to be winter
    timescale has to be 0.25

    The 4 Turns per Year script is broken into quarters. Characters age in the first quarter, Jan-Feb-March
    Quarter 1 - Jan-Feb-March - winter
    Quarter 2 - Apr-May-June - summer
    Quarter 3 - July-Aug-Sept - summer
    Quarter 4 - Oct-Nov-Dec - winter


    Base script with traits:
    This includes traits and triggers to give a movement penalty to all characters in winter. Currently the penalty is 30% but you can change it to whatever you want. Unlike other scripts out there that assign movement penalties in winter, this one only assigns the traits if the character is actually in a region that has winter. A character in a region that never has winter will never have a movement penalty. I believe I got all the regions listed properly in export_descr_character_traits but if you find a mistake be sure to let me know. This is built for the vanilla M2TW map, so if you are using this on a new map you will have to enter your own region ID numbers in the trigger.

    To use the traits version, copy the contents of the campaign_script into the campaign script of any working M2TW or Kingdoms mod folder and make the required changes to descr_strat as listed above. Then copy the contents of my export_descr_character_traits.txt into your export_descr_character_traits.txt, and do the same with export_vnvs.txt. Note that you might have to convert this file using Alpacas convertor first. Delete the export_vnvs.txt.strings.bin file and the game will rebuild it.

    Currently the traits show up in game for testing purposes. The hidden tag is included in the trait I built, but it is commented out.If you do not want the traits to show up as visible traits then remove the ; in front of the word hidden.


    Randomized Winter:
    I have included versions that have randomly severe and mild winters. There is an 80% chance of a normal winter, 10% chance of severe winter, and 10% chance of a mild winter. There are also historic_event popups for the severe and mild winters that you can add your own text to or remove entirely if you wish. To use this version install as outlined above then add the text from my historic_events.txt file to the vanilla historic_events.txt file. Note that you might have to convert this file using Alpacas convertor first. Delete the historic_events.txt.strings.bin file and the game will rebuild it.

    12 Turns per Year
    Mild Winter - Winter in Dec only
    Severe Winter - Winter from Sept through April

    6 Turns per Year
    Mild Winter - Winter in Jan-Feb only
    Severe Winter - Winter from Sept through Feb

    4 Turns per Year
    Since the normal winter is already 1/2 of the year, I didnt include a severe winter, only a mild one. When the mild winter occurs, it will only be winter for the first quarter.


    Randomized Winter with Traits:
    A combination of all of the above scripts. Copy the text from the files I provided into your files.



    All of these scripts will work with any M2 or Kingdoms mod that has the slave faction. The only other requirement is that you have a working mod folder. If you do not have a working mod folder, do not try to run this script as it will not work.
    Attached Files Attached Files
    Last edited by Gigantus; July 27, 2014 at 01:06 PM. Reason: Added prefix

  2. #2

    Default Re: 12 turns per year with proper aging

    Brilliant!
    ...longbows, in skilled hands, could reach further than trebuchets...

  3. #3
    Opifex
    Join Date
    Feb 2005
    Location
    New York, USA
    Posts
    15,154

    Default Re: 12 turns per year with proper aging

    Neat It's an extension of the old 4 turns per year script for RTW.


    "If ye love wealth greater than liberty,
    the tranquility of servitude greater than
    the animating contest for freedom, go
    home from us in peace. We seek not
    your counsel, nor your arms. Crouch
    down and lick the hand that feeds you,
    and may posterity forget that ye were
    our countrymen."
    -Samuel Adams

  4. #4
    D.B. Cooper's Avatar Tribunus
    Join Date
    Jul 2007
    Location
    Ottawa, Canada
    Posts
    7,119

    Default Re: 12 turns per year with proper aging

    Nice one.


  5. #5

    Default Re: 12 turns per year with proper aging

    When I try this script I get the following error.

    Code:
     Script execution error for <set_counter>, at line 6, in eras/data/world/maps/campaign/imperial_campaign/campaign_script.txt: 
    Counter month doesn't exist
    I don't understand why I'm getting this error since I haven't forgotten to add the 'declare_counter month'. Any ideas what could be causing this?
    Morning Sun (adds Korea and China to the Shogun 2 map)
    http://www.twcenter.net/forums/forum...28-Morning-Sun

    Expanded Japan mod (97 new regions and 101 new factions)
    http://www.twcenter.net/forums/showt...ew-factions%29

    How to split a region in TWS2
    http://www.twcenter.net/forums/showt...split-a-region

    Eras Total Conquest 2.3 (12 campaigns from 970-1547)

  6. #6
    GrnEyedDvl's Avatar Liberalism is a Socially Transmitted Disease
    Artifex Technical Staff

    Join Date
    Jan 2007
    Location
    Denver CO
    Posts
    23,844
    Blog Entries
    10

    Default Re: 12 turns per year with proper aging

    Quote Originally Posted by SigniferOne View Post
    Neat It's an extension of the old 4 turns per year script for RTW.
    Kind of. Myrdraals script was set to run as a background script and it had a set of monitors for every year in the campaign. I took the same idea and used a different approach.



    Quote Originally Posted by uanime5 View Post
    When I try this script I get the following error.

    Code:
     Script execution error for <set_counter>, at line 6, in eras/data/world/maps/campaign/imperial_campaign/campaign_script.txt: 
    Counter month doesn't exist
    I don't understand why I'm getting this error since I haven't forgotten to add the 'declare_counter month'. Any ideas what could be causing this?
    Not unless you have a typo someplace.

  7. #7

    Default Re: 12 turns per year with proper aging

    Your characters age normally but what about build times, population growth etc.

  8. #8
    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,095
    Blog Entries
    35

    Default Re: 12 turns per year with proper aging

    Quote Originally Posted by Maverick View Post
    Your characters age normally but what about build times, population growth etc.
    Build times: adjust in EDB
    pop growth and others: adjust in descr_campaign_db.xml










  9. #9
    GrnEyedDvl's Avatar Liberalism is a Socially Transmitted Disease
    Artifex Technical Staff

    Join Date
    Jan 2007
    Location
    Denver CO
    Posts
    23,844
    Blog Entries
    10

    Default Re: 12 turns per year with proper aging

    settlement_mechanics.xml for some of that.

    Those are all tied to the TurnEnd event, so if you have a building time of 2 turns, it will take 2 turns to build no matter how many turns per year you ahve.

  10. #10

    Default Re: 12 turns per year with proper aging

    This is really amazing!

    Under the benevolent guidance of jimkatalanos

  11. #11
    GrnEyedDvl's Avatar Liberalism is a Socially Transmitted Disease
    Artifex Technical Staff

    Join Date
    Jan 2007
    Location
    Denver CO
    Posts
    23,844
    Blog Entries
    10

    Default Re: 12 turns per year with proper aging

    There are a lot of possibilties with it. I already made another version of this for the Westeros guys that makes it the same season (winter or summer) for between 10-25 years randomly, then switches for another 10-25 years.

  12. #12

    Default Re: 12 turns per year with proper aging

    I've tested it but somehow I think I messed up. You see, the year stays the same for 12 turns but the season changes every second turn nevertheless, and the characters age normally. I don't have any errors in the logfile so I am wondering what's wrong.

    Edit: Hmm maybe the character ages double whenever a winter month hits a winter month? Shouldn't it be summer 11 month's and then only one month of winter? Even though unrealistic it would have the effect on ageing you describe in the first post...
    Last edited by Furin; July 07, 2008 at 04:31 PM.

    Under the benevolent guidance of jimkatalanos

  13. #13
    GrnEyedDvl's Avatar Liberalism is a Socially Transmitted Disease
    Artifex Technical Staff

    Join Date
    Jan 2007
    Location
    Denver CO
    Posts
    23,844
    Blog Entries
    10

    Default Re: 12 turns per year with proper aging

    You tested my version and it did that?

  14. #14

    Default Re: 12 turns per year with proper aging

    Yep, I even tried turning every month but december into summer and the season still changed every second turn. I copied your code at the end of my campaign script (before the end_script part). I presume you've tested this and it works for you so I am kinda confused where my error is...

    Under the benevolent guidance of jimkatalanos

  15. #15
    GrnEyedDvl's Avatar Liberalism is a Socially Transmitted Disease
    Artifex Technical Staff

    Join Date
    Jan 2007
    Location
    Denver CO
    Posts
    23,844
    Blog Entries
    10

    Default Re: 12 turns per year with proper aging

    I have run this in two different mods and it ran fine.

    Well I should have specified in the main thread but this is for Kingdoms only, so that might be an issue. Other than that are you sure your mod folder is working?

  16. #16

    Default Re: 12 turns per year with proper aging

    I used it for the DLV mod which is kingdom based/latest patch (and has a slave faction, ...obviously). I'll try again tomorrow, maybe a different location within the campaign script will do the trick. Thank's for the help.

    Under the benevolent guidance of jimkatalanos

  17. #17
    GrnEyedDvl's Avatar Liberalism is a Socially Transmitted Disease
    Artifex Technical Staff

    Join Date
    Jan 2007
    Location
    Denver CO
    Posts
    23,844
    Blog Entries
    10

    Default Re: 12 turns per year with proper aging

    If you didnt change the start season to winter instead of summer it will probably screw it up. In descr_strat there is a section that will say something like:

    Code:
    start_date	1066 winter
    end_date	1096 winter
    timescale	0.0835
    I have highlighted the parts you have to match exactly.

  18. #18

    Default Re: 12 turns per year with proper aging

    I love this script, just added it to my game.

    Is their any way at all to change it so the start is summer and not winter?
    The Watchwords Of Midnight
    "The brave and the free fear no foe, go forth, mighty hosts of Midnight! Unto death or victory we go!"

    The Midnight Chronicles

  19. #19
    aNarion.'s Avatar Centenarius
    Join Date
    Jul 2006
    Location
    Sweden, närke
    Posts
    846

    Default Re: 12 turns per year with proper aging

    Awesome!!

    Thought this was hardcorded?

    Anyway, if i would like this to work for SS, do i just copy the script text, and put it in campaign_script, and change the timescale, start_date in descr_strat?

    edit: where should i put it exacly in the campaign_script, in the bottom or?
    Last edited by aNarion.; July 08, 2008 at 08:27 AM.

  20. #20

    Default Re: 12 turns per year with proper aging

    Quote Originally Posted by GrnEyedDvl View Post
    If you didnt change the start season to winter instead of summer it will probably screw it up. In descr_strat there is a section that will say something like:

    Code:
    start_date    1066 winter
    end_date    1096 winter
    timescale    0.0835
    I have highlighted the parts you have to match exactly.
    Geez do I feel stupid now, I guess that was my mistake, I overread the winter part. Sorry .

    Under the benevolent guidance of jimkatalanos

Page 1 of 33 123456789101126 ... LastLast

Tags for this Thread

Posting Permissions

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