Results 1 to 22 of 22

Thread: Character Age, Detecting Settlement Captures

  1. #1
    Bibliophilic Member Atilius's Avatar
    Join Date
    Oct 2005
    Location
    America Medioccidentalis Superior
    Posts
    3,837

    Question Character Age, Detecting Settlement Captures

    I've been experimenting with a couple of things lately but haven't had much success getting them to work. I wonder if anyone has any ideas:

    Character Age
    ===========
    I'd like to be able to assign a trait to a character when he reaches a certain age. The problem is that I don't see any way of determining how old he is. I can imagine keeping track of age with an age trait, but this will only work for characters who enter the game at age 16. Adoptees and sons-in-law can enter the game at just about any age from 16 on up.

    Settlement Capture
    ===============
    I'd like to have a background script do something to any settlement that changes ownership. The problem here is determining when a settlement changes hands. There are events which are sometimes triggered when this happens: sacking, enslavement, extermination. But (I think) some of these require a character to be present and not all of them export the settlement name. In addition none of those events apply to a simple capture and occupation. Anyone have an idea as to how this might be done?
    The truth is the most valuable thing we have. Let us economize it. - Mark Twain



  2. #2

    Default Re: Character Age, Detecting Settlement Captures

    I tried to get an age myself once for a roman career thing but could never see how to do it. Character records are passed to a lot of triggers and age must be one of the attributes a general has but i never managed to get the syntax for it (if it is possible at all).

    I don't know much about scripting but i'd suggest d/ling some mods with scripts and seeing what they've done.
    It's not a map.

  3. #3
    EB Traiter Member Malrubius's Avatar
    Join Date
    Jan 2005
    Location
    On a tree-covered mountain in Anniston, Alabama, USA
    Posts
    2,633

    Default Re: Character Age, Detecting Settlement Captures

    I had no luck trying to figure out the age of generals, myself, unless they passed through the CharacterComesOfAge event. If anybody's had any luck, let me know.

    Ah! the Generals! they are numerous, but not good for much (especially if they're Languorous)!
    -- Aristophanes, if he played EB

  4. #4

    Default Re: Character Age, Detecting Settlement Captures

    Someone on a thread somewhere mentioned they saw a CharacterName being referenced in a CA thing. I can't recall if it was a script or a trait/advice/ancillary trigger. It made me think CharacterAge might be the attribute to check for but i think i tried this way back before i gave up. I didn't really know what i was doing though. So many of the triggers seem to get passed a character record you'd think it would be in there somewhere as an attribute or something.
    It's not a map.

  5. #5
    Bibliophilic Member Atilius's Avatar
    Join Date
    Oct 2005
    Location
    America Medioccidentalis Superior
    Posts
    3,837

    Post Re: Character Age, Detecting Settlement Captures

    I appreciate your responses guys, and thought I ought to get back to you.

    Quote Originally Posted by nikolai1962
    I tried to get an age myself once for a roman career thing but could never see how to do it.
    Yes, exactly what I had in mind. Did you find another way to go about it?

    Quote Originally Posted by nikolai1962
    It made me think CharacterAge might be the attribute to check
    I fiddled around with this suggestion of yours but had no luck; thanks though.

    Quote Originally Posted by malrubius
    I had no luck trying to figure out the age of generals, myself, unless they passed through the CharacterComesOfAge event. If anybody's had any luck, let me know.
    I'll do that if I figure something out, but that's not looking very likely right now. I second your .

    I did make some progress on the settlement capture issue, though I don't know if it's of interest to you. It turns out that the GeneralCaptureSettlement event fires even if the stack that captures the settlement is commanded by a captain. So it appears that every time a settlement changes hands there should be a GeneralCaptureSettlement or CityRebels event.
    The truth is the most valuable thing we have. Let us economize it. - Mark Twain



  6. #6

    Default

    If it existed then it should be documented in the docudemon files - but I've been through them pretty thoroughly and there's no mention of it.
    Last edited by Epistolary Richard; 05-16-2006 at 20:12.

  7. #7
    Bibliophilic Member Atilius's Avatar
    Join Date
    Oct 2005
    Location
    America Medioccidentalis Superior
    Posts
    3,837

    Post Re: Character Age, Detecting Settlement Captures

    Quote Originally Posted by RTW Modding Forum
    If it existed then it should be documented in the docudemon files - but I've been through them pretty thoroughly and there's no mention of it.
    You are correct RTWMF. I have been through the docudemon files many times also and haven't found what I'm looking for. But, having perpetrated a few of them myself (intentionally and otherwise), I know that there are always backdoors, hacks, and undocumented features.
    The truth is the most valuable thing we have. Let us economize it. - Mark Twain



  8. #8

    Default Re: Character Age, Detecting Settlement Captures

    Originally Posted by nikolai1962
    I tried to get an age myself once for a roman career thing but could never see how to do it.
    Yes, exactly what I had in mind. Did you find another way to go about it?
    No i gave up as it was too annoying having 60 year old adoptees with "this man has just started out on the cursus honorarum" trait :)

    Other people have done more. I think the TFT mod has a very detailed system and i think EB does too. Have a look through their code maybe?
    It's not a map.

  9. #9
    Member Member Stuie's Avatar
    Join Date
    Aug 2001
    Location
    Upper Gwynedd, PA
    Posts
    406

    Default Re: Character Age, Detecting Settlement Captures

    Quote Originally Posted by nikolai1962
    No i gave up as it was too annoying having 60 year old adoptees with "this man has just started out on the cursus honorarum" trait :)

    Other people have done more. I think the TFT mod has a very detailed system...
    Our (TFT that is) system does not capture age for adoptees - rank is determined for adoptees based on the traits of the adoptive father. So your 60 year old adoptee would gain a social class equivalent to his father.

  10. #10
    Member Member Avicenna's Avatar
    Join Date
    Feb 2006
    Location
    Terra, Solar System, Orion Arm, Milky Way, Local Group, Virgo Supercluster, somewhere in this universe.
    Posts
    2,746

    Default Re: Character Age, Detecting Settlement Captures

    There should be a way of determining the age though, since the portraits can tell the age: they automatically get older when the character turns 50. If you could that trigger it might be able to do what you want.
    Student by day, bacon-eating narwhal by night (specifically midnight)

  11. #11

    Default Re: Character Age, Detecting Settlement Captures

    Quote Originally Posted by Stuie
    Our (TFT that is) system does not capture age for adoptees - rank is determined for adoptees based on the traits of the adoptive father. So your 60 year old adoptee would gain a social class equivalent to his father.
    Clever.

    There should be a way of determining the age though
    Yes, there should :)
    It's not a map.

  12. #12
    Harbinger of... saliva Member alpaca's Avatar
    Join Date
    Aug 2003
    Location
    Germany
    Posts
    2,767

    Default Re: Character Age, Detecting Settlement Captures

    No doubt there's an age variable for each character. Only it's not exported to the scripting system but stays internal.
    Just as the portraits btw, which we can't influence either.

  13. #13

    Angry Re: Character Age, Detecting Settlement Captures

    To determine character age, use CharacterAge in export_descr_character_traits.txt but not as a trait...

    ;------------------------------------------
    Trigger general_ages1
    WhenToTest CharacterTurnStart

    Condition AgentType = family
    and CharacterAge > 15
    and CharacterAge < 40
    and Trait AgeingGeneral < 1

    Affects AgeingGeneral 1 Chance 100

    I've got this working in my bug-fixer 3.36/GAPH Modded RTW :)

  14. #14
    Bug Hunter Senior Member player1's Avatar
    Join Date
    Feb 2005
    Location
    Belgrade, Serbia
    Posts
    1,405

    Default Re: Character Age, Detecting Settlement Captures

    You mean there is actually condition CharacterAge in the game?

    Great find...
    BUG-FIXER, an unofficial patch for both Rome: Total War and its expansion pack

  15. #15

    Default Re: Character Age, Detecting Settlement Captures

    Quote Originally Posted by maste1n
    To determine character age, use CharacterAge in export_descr_character_traits.txt but not as a trait...

    ;------------------------------------------
    Trigger general_ages1
    WhenToTest CharacterTurnStart

    Condition AgentType = family
    and CharacterAge > 15
    and CharacterAge < 40
    and Trait AgeingGeneral < 1

    Affects AgeingGeneral 1 Chance 100

    I've got this working in my bug-fixer 3.36/GAPH Modded RTW :)

    Argh! When i was trying i tried

    "Trait CharacterAge" and "Attribute CharacterAge" but not plain CharacterAge

    I bet you can get CharacterName too.

    Definitely a great find. Kudos
    It's not a map.

  16. #16
    Member Member Marcus Camillus's Avatar
    Join Date
    Dec 2005
    Location
    a villa SE of Roma
    Posts
    15

    Default Re: Character Age, Detecting Settlement Captures

    Quote Originally Posted by maste1n
    To determine character age, use CharacterAge in export_descr_character_traits.txt but not as a trait...

    ;------------------------------------------
    Trigger general_ages1
    WhenToTest CharacterTurnStart

    Condition AgentType = family
    and CharacterAge > 15
    and CharacterAge < 40
    and Trait AgeingGeneral < 1

    Affects AgeingGeneral 1 Chance 100

    I've got this working in my bug-fixer 3.36/GAPH Modded RTW :)
    This is great news indeed. Its just what I have been looking for to use in my current mod so that newly acquired Roman characters can have the experience and ranks appropriate for their age. Now its back to my "Mod Testing Lab" for some new experimenting. Thank you for sharing this!
    Marcus Camillus

    "A ship in harbor is safe, but that is not what ships are built for."
    -- William Shedd

  17. #17
    Harbinger of... saliva Member alpaca's Avatar
    Join Date
    Aug 2003
    Location
    Germany
    Posts
    2,767

    Default Re: Character Age, Detecting Settlement Captures

    Before you guys get overexcited let me state that this condition doesn't work for me.
    When I try to use it, it actually works as if there was no condition at all.

    What I tried was a vanilla game with triggers:
    Code:
    Condition CharacterAge > 40 - where it was awarded to all characters
    Condition CharacterAge < 15 - where it was again awarded to all characters
    Condition not CharacterAge >= 15 - where it, too, was awarded to all characters
    Concluding this condition seems to work like TrueCondition (or is not included at all) ;)
    Last edited by alpaca; 05-07-2006 at 10:50.

  18. #18
    Bibliophilic Member Atilius's Avatar
    Join Date
    Oct 2005
    Location
    America Medioccidentalis Superior
    Posts
    3,837

    Exclamation Re: Character Age, Detecting Settlement Captures

    Quote Originally Posted by maste1n
    To determine character age, use CharacterAge in export_descr_character_traits.txt but not as a trait...

    ;------------------------------------------
    Trigger general_ages1
    WhenToTest CharacterTurnStart

    Condition AgentType = family
    and CharacterAge > 15
    and CharacterAge < 40
    and Trait AgeingGeneral < 1

    Affects AgeingGeneral 1 Chance 100

    I've got this working in my bug-fixer 3.36/GAPH Modded RTW :)

    I was unable to get this CharacterAge thing to work. It's been my experience that if you add a condition that makes no sense, a trigger will always treat the condition as being true. I thought this might be what happened here, so I tried the following experiment.

    I created a trait named ImpossibleTrait:

    Code:
    ;------------------------------------------
    Trait ImpossibleTrait
        Characters family
    
        Level Impossible_Trait
            Description Impossible_Trait_desc
            EffectsDescription Impossible_Trait_effects_desc
            Threshold  1
    which is enabled only by the trigger ShouldntSucceed:

    Code:
    ;------------------------------------------
    Trigger ShouldntSucceed
        WhenToTest CharacterTurnStart
    
        Condition CharacterAge > 25
               and CharacterAge < 25
    
    
        Affects ImpossibleTrait  1  Chance  100
    Clearly this trigger should never succeed, so no character should ever acquire the trait ImpossibleTrait. However, when I ran the game, all my characters immediately acquired the it.

    So, if I haven't screwed up here (and please experiment for yourselves - I'd very much like to be wrong), CharacterAge is meaningless and any condition using it simply evaluates to true by default.

    maste1n,
    If your trigger works correctly, a character 40 years old or more who doesn't already have the AgeingGeneral trait will never get it. Have you verified this?
    Last edited by Atilius; 05-07-2006 at 11:07.
    The truth is the most valuable thing we have. Let us economize it. - Mark Twain



  19. #19

    Angry Re: Character Age, Detecting Settlement Captures

    Just rechecked this and it looks like Atilius is right.

    I've been playing with various age style checks and only CharacterAge seemed to work.

    Just changed it back to Age and it does exactly the same.

    Really sorry guys, I thought I'd cracked it and wanted to pass it on.

    I'll keep looking.

  20. #20
    Bibliophilic Member Atilius's Avatar
    Join Date
    Oct 2005
    Location
    America Medioccidentalis Superior
    Posts
    3,837

    Post Re: Character Age, Detecting Settlement Captures

    No problem maste1n, the trigger parser should really generate a show_err when it doesn't understand a condition. The fact that it doesn't is an ongoing source of grief.
    The truth is the most valuable thing we have. Let us economize it. - Mark Twain



  21. #21

    Default Re: Character Age, Detecting Settlement Captures

    It's not a map.

  22. #22
    Member Member Marcus Camillus's Avatar
    Join Date
    Dec 2005
    Location
    a villa SE of Roma
    Posts
    15

    Default Re: Character Age, Detecting Settlement Captures

    Darn, I was really hoping this would work. There aught to be some syntax for the age attribute. Well, guess I am stuck for now with my interum workaround. Thanks for trying though.
    Marcus Camillus

    "A ship in harbor is safe, but that is not what ships are built for."
    -- William Shedd

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