Page 2 of 3 FirstFirst 123 LastLast
Results 21 to 40 of 51

Thread: Script Validator

  1. #21

    Default Re: Script Validator

    lol - what's the difference?
    But was the bug itself reported correctly?

    Fixed it for the next version though, thanks

  2. #22

    Default Re: Script Validator

    No it wasn't a bug in the script.
    The other thing I've noticed is that it's picking up (presumably different) ascii symbols for white space between words and reporting those.


    Under patronage of Spirit of Rob; Patron of Century X, Pacco, Cherryfunk, Leif Erikson.

  3. #23
    HouseOfHam's Avatar Primicerius
    Join Date
    Apr 2007
    Location
    Minnesota, USA
    Posts
    3,030

    Default Re: Script Validator

    Does it check for lines containing both "not" and a condition that uses a logical operator?
    RTR website/SVN admin

    - Settlement coordinate locator -for RTW/M2TW
    - EDB Validator v1.2.8 (Oct 16, 2012) - for RTW/M2TW
    - RTW scripting tutorials
    - n-turns per year script generator

  4. #24

    Default Re: Script Validator

    Can you give an example of what you mean?

    Like "if not I_CompareCounter CounterX = 3"?

    I think it does check that, but I would have to check it to be sure.

  5. #25

    Default Re: Script Validator

    Quote Originally Posted by PatricianS View Post
    I think it does check that, but I would have to check it to be sure.
    ^i like

  6. #26

    Default Re: Script Validator

    I added a function in v1.3 to check for region names in the I_SettlementExists and I_SettlementOwner conditions, by reading descr_regions.txt (based on HouseOfHam's Settlement Coordinate Locator)

    I haven't added it for "I_SettlementSelected" yet...


  7. #27
    chris10's Avatar Primicerius
    Join Date
    Sep 2009
    Location
    Spain
    Posts
    3,239

    Default Re: Script Validator

    Great tool
    Iam a sort of greeny on scripting issues so be nice if I get something wrong in my ignorance
    I used your Validator on various scripts and found that it does not recognize the shadowing or shadowed_by feature introduced with BI.
    Entry Example from the descr_sm_factions.txt: romans_brutii, shadowed by Thrace
    To make use of the shadow feature the faction name has to have a comma while in the actual script there is no comma...so the Validator comes up with loads of error messages "unrecognized faction".
    Maybe there is a way to bypass this in a future version as on a long scripts the list of error entrys will veeeery long just for this little issue

  8. #28

    Default Re: Script Validator

    Good point, hadn't thought of that... Though you can change the faction names manually after reading them

  9. #29
    chris10's Avatar Primicerius
    Join Date
    Sep 2009
    Location
    Spain
    Posts
    3,239

    Default Re: Script Validator

    Quote Originally Posted by PatricianS View Post
    Though you can change the faction names manually after reading them
    ...the faction names dont have to be changed...these are false positives......
    not a big problem with small scripts but when they get 9000 lines or longer....puuuuuhhh...if one has 500 false positives its easy to oversee a real error....
    nevermind...great tool anyway

    I post you an example of an error log full of false positives.
    You will see one real error within the others which can be easily overseen...

  10. #30

    Default Re: Script Validator

    Quote Originally Posted by chris10 View Post
    ...the faction names dont have to be changed...these are false positives......
    not a big problem with small scripts but when they get 9000 lines or longer....puuuuuhhh...if one has 500 false positives its easy to oversee a real error....
    nevermind...great tool anyway

    I post you an example of an error log full of false positives.
    You will see one real error within the others which can be easily overseen...
    What I meant, is that you can change the faction name the tool uses after you've read them from descr_sm_factions.txt, like this:





    So all you have to do is to ensure the faction names listed in the tool are the correct ones and you won't get any errors...
    (make sure to remove any comas and such as well...)

  11. #31

    Default Re: Script Validator

    Very useful tool! even more now it checks for faction and region names

    If you remember, some time ago we talked about the proper use of the condition GarrisonToPopulationRatio, because it appears GarrisonSettlementRatio in the sample use of the docudemon.
    Sorry if I waited so long time to check it...

    Let me confirm your validator is right, and this is the proper use:
    Code:
    GarrisonToPopulationRatio > 0.35
    While it seems the condition I was using "GarrisonSettlementRatio"does nothing.

  12. #32
    chris10's Avatar Primicerius
    Join Date
    Sep 2009
    Location
    Spain
    Posts
    3,239

    Default Re: Script Validator

    Quote Originally Posted by PatricianS View Post
    What I meant, is that you can change the faction name the tool uses after you've read them from descr_sm_factions.txt, like this:
    So all you have to do is to ensure the faction names listed in the tool are the correct ones and you won't get any errors...
    (make sure to remove any comas and such as well...)
    ...uhhhh....of course.....

  13. #33

    Default Re: Script Validator

    Quote Originally Posted by Bardo View Post
    Very useful tool! even more now it checks for faction and region names
    Great! Thanks

    Quote Originally Posted by Bardo View Post
    If you remember, some time ago we talked about the proper use of the condition GarrisonToPopulationRatio, because it appears GarrisonSettlementRatio in the sample use of the docudemon.
    Sorry if I waited so long time to check it...

    Let me confirm your validator is right, and this is the proper use:
    Code:
    GarrisonToPopulationRatio > 0.35
    While it seems the condition I was using "GarrisonSettlementRatio"does nothing.
    Thanks a lot for testing that! Very good to know! (especially since I was about to use it myself as well )

  14. #34

    Default Re: Script Validator

    In the export_descr_advice file, I found these things (marked in red - scroll down to see the others):

    Code:
    ;------------------------------------------
    AdviceThread Character_Suggested_Action_Attack_Enemy_Thread
        GameArea Campaign
    
        Item Character_Suggested_Action_Attack_Enemy_Text_01
            Suppressible y
            Uninhibitable
            Verbosity  3
            Threshold  1
            MaxRepeats  100
            RepeatInterval  3
            Attitude Normal
            Presentation Default
            Parameter TargetCharacterName
            Title Character_Suggested_Action_Attack_Enemy_Text_01_Title
            Text Character_Suggested_Action_Attack_Enemy_Text_01_Text1
            Text Character_Suggested_Action_Attack_Enemy_Text_01_Text2
            Text Character_Suggested_Action_Attack_Enemy_Text_01_Text3
            Text Character_Suggested_Action_Attack_Enemy_Text_01_Text4
    
    
    
    ;------------------------------------------
    
    AdviceThread Character_Suggested_Action_Attack_Settlement_Thread
        GameArea Campaign
    
        Item Character_Suggested_Action_Attack_Settlement_Text_01
            Suppressible y
            Uninhibitable
            Verbosity  3
            Threshold  2
            MaxRepeats  100
            RepeatInterval  4
            Attitude Normal
            Presentation Default
            Parameter TargetSettlementName
            Title Character_Suggested_Action_Attack_Settlement_Text_01_Title
            Text Character_Suggested_Action_Attack_Settlement_Text_01_Text1
            Text Character_Suggested_Action_Attack_Settlement_Text_01_Text2
            Text Character_Suggested_Action_Attack_Settlement_Text_01_Text3
            Text Character_Suggested_Action_Attack_Settlement_Text_01_Text4
    
    
    
    ;------------------------------------------
    AdviceThread Character_Suggested_Action_Patrol_Region_Thread
        GameArea Campaign
    
        Item Character_Suggested_Action_Patrol_Region_Text_01
            Suppressible y
            Uninhibitable
            Verbosity  3
            Threshold  2
            MaxRepeats  100
            RepeatInterval  4
            Attitude Normal
            Presentation Default
            Parameter RegionName
            Title Character_Suggested_Action_Patrol_Region_Text_01_Title
            Text Character_Suggested_Action_Patrol_Region_Text_01_Text1
            Text Character_Suggested_Action_Patrol_Region_Text_01_Text2
            Text Character_Suggested_Action_Patrol_Region_Text_01_Text3
            Text Character_Suggested_Action_Patrol_Region_Text_01_Text4
    
    
    
    ;------------------------------------------
    
    Etc etc...
    In short, the "parameters" I found in this file are:

    • SettlementName
    • TargetSettlementName
    • RegionName
    • TargetRegionName
    • CharacterName
    • TargetCharacterName

    Only the first one exists in the docudemons, the others don't.

    Does anyone have an idea if those can somehow be used as condition in a script? (and if I should add it to the validator). Of course I can test it myself, but if someone else already did, I would be duplicating work

  15. #35
    Squid's Avatar Opifex
    Patrician Artifex Technical Staff

    Join Date
    Feb 2007
    Location
    Frozen waste lands of the north
    Posts
    17,760
    Blog Entries
    3

    Default Re: Script Validator

    My theory on those, I ran into them when adding advice validation to ATVTW, is that they are values you can refer to in export_ancillaries to have really customized messages. None of the advice threads actually make use of them, and I haven't tried adding them to advice threads to test. There are few others that you don't mention listed in the exe but I can't remember what they are right now.
    Under the patronage of Roman_Man#3, Patron of Ishan
    Click for my tools and tutorials
    "Two things are infinite: the universe and human stupidity; and I'm not sure about the universe." -----Albert Einstein

  16. #36

    Default Re: Script Validator

    Well, they don't work in traits at least. They return true all the time, so they are probably treated as invalid conditions.

  17. #37
    Squid's Avatar Opifex
    Patrician Artifex Technical Staff

    Join Date
    Feb 2007
    Location
    Frozen waste lands of the north
    Posts
    17,760
    Blog Entries
    3

    Default Re: Script Validator

    They aren't conditions, I think they're parameters that can be used in the text description for the advice items.
    Under the patronage of Roman_Man#3, Patron of Ishan
    Click for my tools and tutorials
    "Two things are infinite: the universe and human stupidity; and I'm not sure about the universe." -----Albert Einstein

  18. #38

    Default Re: Script Validator

    Well yes, I know, I just tried to see if they could be used in any way in traits (and therefore scripts). And I couldn't imagine of any other way one could use them in scripts/traits other than as conditions.

  19. #39

    Default Re: Script Validator

    Ok, pity they don't work...
    Quote Originally Posted by Aradan View Post
    Well yes, I know, I just tried to see if they could be used in any way in traits (and therefore scripts). And I couldn't imagine of any other way one could use them in scripts/traits other than as conditions.
    Especially as one of them (SettlementName) is a condition as well.

  20. #40

    Default Re: Script Validator

    Does anyone know what the ! in some conditions does? Currently the validator notifies it as a bug, but it's also used in the RTW prologue script:
    Code:
    ;;;;**********************************************************************************************
    ;;;;    wait for end deployement
    ;;;;**********************************************************************************************
    
        while ! I_BattleStarted
        end_while

Page 2 of 3 FirstFirst 123 LastLast

Posting Permissions

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