Results 1 to 14 of 14

Thread: game load inexistant camppaign_script.txt

  1. #1

    Default game load inexistant camppaign_script.txt

    Hello everyone, I have a strange situation and I hope someone will have more info or ideas on it.

    EDIT: it was a noob mistake, I didn't know the changes in CS will show only in a knew game. For other beginner modder seeing this, look at the bottom post for full explanation by gigantus and withmar.

    Short version: the game loads a campaign_script.txt file that does not exists, because I have deleted it to test something. I know it loads this file because it generates errors in the log:
    Code:
    21:32:40.974 [game.script] [error] Condition parsing error in mods/SS6.3/data/world/maps/campaign/imperial_campaign/campaign_script.txt, at line 49276, column 25
    counter value not declared
    but there is no said file in this particular folder.

    Long version: I came to this because I wanted to add more log output in the campaign_script for some tests I was making, but after testing a few version in was not showing. I also modified some log entries already existing, like changing
    Code:
    log always Turn Start venice
    to this
    Code:
    log always ---- Turn Start venice
    but it was still showing the first version in the log file.

    Help would be much appreciated!
    Last edited by Belovèse; December 24, 2020 at 02:01 AM.
    Belovèse's Toolbox: export text files to spreadsheet, detailed unit stats
    Stainless Steel Historical Improvement Project (SSHIP) team member.
    Mini-mods: diplomacy and relation/reputation - detailled unit stats

  2. #2
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: game load inexistant camppaign_script.txt

    Are you sure that is the most recent log? The log for my repack version of SS is for instance the default log. Whereas the one for the original version is a custom one if memory recalls. Open the mod's cfg file and have a look what the entry in the log section says. Here the entry for the default name and path: to = system.log.txt
    Here a setting for a log in a sub folder of the main game (m2tw\logs): to = logs/M2TW.system.log.txt

    Note: simply commenting the last line in the descr_strat file would have stopped the game from loading the script. A tad easier for test purposes like yours
    Last edited by Gigantus; December 23, 2020 at 05:32 AM.










  3. #3

    Default Re: game load inexistant camppaign_script.txt

    I'm sûre about the log file because I use my own config file, and also I did delete the previous log and the game recreated it, also because of the time stamp of the log entries.

    I'll test disabling it via descr_stratand post the results.
    Belovèse's Toolbox: export text files to spreadsheet, detailed unit stats
    Stainless Steel Historical Improvement Project (SSHIP) team member.
    Mini-mods: diplomacy and relation/reputation - detailled unit stats

  4. #4
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: game load inexistant camppaign_script.txt

    I just ran this monitor:
    Code:
    monitor_event FactionTurnStart FactionType england
         log always this is a log 
         log info this is also a log
        terminate_monitor
    end_monitor
    And got this log section:
    Code:
    18:03:34.806 [game.script.exec] [trace] exec <log> at line 10 in mods/Bare_Geomod/data/world/maps/campaign/imperial_campaign/campaign_script.txt
    18:03:34.806 [game.script] [always] this is a log 
    18:03:34.806 [game.script.exec] [trace] exec <log> at line 11 in mods/Bare_Geomod/data/world/maps/campaign/imperial_campaign/campaign_script.txt
    18:03:34.806 [game.script] [always] info this is also a log
    18:03:34.806 [game.script.exec] [trace] exec <terminate_monitor> at line 12 in mods/Bare_Geomod/data/world/maps/campaign/imperial_campaign/campaign_script.txt
    Definitely something wrong with your set up.










  5. #5

    Default Re: game load inexistant camppaign_script.txt

    Well it turns out that my changes in campaign_script show in the log only if I create a new game, so these changes are not savegame compatible. It was my first time tampering with this file, but maybe this is already known? Or it is just a weird thing my computer does, but I went through a full SSHIP reinstall before finding about the new game stuff.
    Belovèse's Toolbox: export text files to spreadsheet, detailed unit stats
    Stainless Steel Historical Improvement Project (SSHIP) team member.
    Mini-mods: diplomacy and relation/reputation - detailled unit stats

  6. #6
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: game load inexistant camppaign_script.txt

    Providing that little snippet of info would have resolved your issue immediately. The script only gets read at game start and after that doesn't get accessed again. Hence any changes or even it's removal will not impact on a save game.










  7. #7

    Default Re: game load inexistant camppaign_script.txt

    Yep sorry, it was a noob question! I'll take the habit of testing things with new games to avoid this mistake again. Thanks for your time!
    Belovèse's Toolbox: export text files to spreadsheet, detailed unit stats
    Stainless Steel Historical Improvement Project (SSHIP) team member.
    Mini-mods: diplomacy and relation/reputation - detailled unit stats

  8. #8
    Withwnar's Avatar Script To The Waist
    Join Date
    Oct 2008
    Location
    Earth
    Posts
    6,329

    Default Re: game load inexistant camppaign_script.txt

    ...and the script location (and script itself) get saved in the game save files. Hence why your loaded game knows where the script used to be and reports that in the log.

    Script and descr_strat changes (and some other things) are not save game compatible.

  9. #9

    Default Re: game load inexistant camppaign_script.txt

    Thanks!
    Belovèse's Toolbox: export text files to spreadsheet, detailed unit stats
    Stainless Steel Historical Improvement Project (SSHIP) team member.
    Mini-mods: diplomacy and relation/reputation - detailled unit stats

  10. #10
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: game load inexistant camppaign_script.txt

    Quote Originally Posted by Belovèse View Post
    Yep sorry, it was a noob question! I'll take the habit of testing things with new games to avoid this mistake again. Thanks for your time!
    It wasn't a noob question, you however did not mention that you were testing on a save game - which is highly unusual and thus should always be mentioned. Else it will always be assumed that you are testing on a fresh game start.










  11. #11

    Default Re: game load inexistant camppaign_script.txt

    Quote Originally Posted by Withwnar View Post
    ...and the script location (and script itself) get saved in the game save files. Hence why your loaded game knows where the script used to be and reports that in the log.

    Script and descr_strat changes (and some other things) are not save game compatible.
    Quote Originally Posted by Gigantus View Post
    It wasn't a noob question, you however did not mention that you were testing on a save game - which is highly unusual and thus should always be mentioned. Else it will always be assumed that you are testing on a fresh game start.
    Noted, I'll do that in the future. Another quick question: do heavy use of the log command in campaign_script slow down processing time or make the game unstable?
    I would like do make a more detailled log for SSHIP, like this:
    Code:
        set_event_counter E_Patriarch 1
        log --- Script Ecumenical Patriarch --- set event counter E_Patriarch 1 (no monitor)
    
    
        monitor_event SettlementTurnEnd SettlementName Constantinople
            set_event_counter E_Patriarch 1
            log --- Script Ecumenical Patriarch --- set event counter E_Patriarch 1 (Constantinople turn end)
        end_monitor
    
        monitor_event SettlementTurnStart SettlementName Constantinople
            set_event_counter E_Patriarch 0
            log --- Script Ecumenical Patriarch --- set event counter E_Patriarch 0 (Constantinople turn start)
        end_monitor
    
        monitor_event CharacterTurnStart AgentType = priest
            and FactionwideAncillaryExists ecumenical_patriarch
            set_event_counter Is_E_Patriarch 1
            log --- Script Ecumenical Patriarch --- set event counter Is_E_Patriarch 1
        end_monitor
    
        monitor_event FactionTurnEnd not FactionType slave
            set_event_counter Is_E_Patriarch 0
            log --- Script Ecumenical Patriarch --- set event counter Is_E_Patriarch 0
        end_monitor
    I didi that for a few parts of the script and tested it (on new games!!) and for now I see now problems, but you have way more experience with this!
    Belovèse's Toolbox: export text files to spreadsheet, detailed unit stats
    Stainless Steel Historical Improvement Project (SSHIP) team member.
    Mini-mods: diplomacy and relation/reputation - detailled unit stats

  12. #12
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: game load inexistant camppaign_script.txt

    A regular faction counter set up has two log entries per faction - that can be up to 62 log entries per turn. Haven't heard of any issue other then that it will bloat the log itself










  13. #13

    Default Re: game load inexistant camppaign_script.txt

    Quote Originally Posted by Gigantus View Post
    A regular faction counter set up has two log entries per faction - that can be up to 62 log entries per turn. Haven't heard of any issue other then that it will bloat the log itself
    Thanks! I think what I will do is way bellow the number of lines you get with the log set to trace, anyway.
    Belovèse's Toolbox: export text files to spreadsheet, detailed unit stats
    Stainless Steel Historical Improvement Project (SSHIP) team member.
    Mini-mods: diplomacy and relation/reputation - detailled unit stats

  14. #14
    Gigantus's Avatar I am not special - I am a limited edition.
    Patrician took an arrow to the knee spy of the council

    Join Date
    Aug 2006
    Location
    Goa - India
    Posts
    53,125
    Blog Entries
    35

    Default Re: game load inexistant camppaign_script.txt

    Well, considering the length of a trace log (simple start is over 50K lines) it's not really heavy, in a simple log however it's nearly all of it.










Posting Permissions

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