Results 1 to 7 of 7

Thread: Detecting a Character's Age

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    UndyingNephalim's Avatar Primicerius
    Patrician Artifex

    Join Date
    Jan 2011
    Posts
    3,967

    Default Detecting a Character's Age

    Is there a condition for a campaign script to test a specific character's age? For example:

    CharacterAge MynameisBob >= 50

    Adding names to CharacterAge seems to cause the campaign script to not function. Is there another condition or workaround to recognize a specific character's age?

  2. #2
    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,682
    Blog Entries
    35

    Default Re: Detecting a Character's Age

    You will first have to define the character before you can test for his age. It will still be difficult to test the age of a certain character unless he exists from the beginning and can be given a unique trait.
    In that case you could simply test the character for that trait and the age.

    monitor_event CharacterTurnStart
    trait [trait_name] = 1
    CharacterAge [logic token] [value]
    [command of your choice]
    end_monitor










  3. #3
    UndyingNephalim's Avatar Primicerius
    Patrician Artifex

    Join Date
    Jan 2011
    Posts
    3,967

    Default Re: Detecting a Character's Age

    I tried that out and the campaign script seemed to not function. The error log in this case says "don't recognize this token: trait"

    I tried this method too:
    Code:
    monitor_event CharacterTurnStart
        and trait newtrait = 1
        and CharacterAge == 24
             kill_character charactername
     terminate_monitor
    end_monitor
    The error log in this case says "don't recognize this token: and"

  4. #4
    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,682
    Blog Entries
    35

    Default Re: Detecting a Character's Age

    My bad - you need a 'definition' of the event, add something like FactionIsLocal to the first line (or remove the first 'and'):

    monitor_event CharacterTurnStart FactionIsLocal

    or

    monitor_event CharacterTurnStart trait newtrait = 1










  5. #5
    Kiliç Alì's Avatar Domesticus
    Artifex

    Join Date
    Feb 2011
    Location
    Italy
    Posts
    2,114

    Default Re: Detecting a Character's Age

    Also "Trait" with capital letter...

    Member of the Imperial House of Hader, proud client of The only and sole Ferrit

  6. #6
    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,682
    Blog Entries
    35

    Default Re: Detecting a Character's Age

    - getting old.










  7. #7
    UndyingNephalim's Avatar Primicerius
    Patrician Artifex

    Join Date
    Jan 2011
    Posts
    3,967

    Default Re: Detecting a Character's Age

    It works now. Much thanks.

Posting Permissions

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