Results 1 to 3 of 3

Thread: Script - Load problem

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1

    Default Script - Load problem

    I have completed my script at last, only to discover that it does not work when I load a game from another campaign game, something which I thought was possible with the code below...

    ; Handle saved game reloads
    monitor_event GameReloaded TrueCondition
    terminate_script
    end_monitor

    I have since stripped out all of my scripted work to test what is causing the problem. I have reduced my code to a simple 6tpy script but the problem remains.

    Possibly unrelated but if I run the script directly from the desc_strat file then the load and save buttons are greyed out. If i call it as part of an advice thread then these buttons work but I have this problem with the loading. I also have the code to stop the script when I press the '?' button and this seems to work fine.

    What is going wrong?

    Also on a side issue I scripted the movement of the camera but once the camera stops moving commands which follow it do not happen, is there a way to fix this or is this yet anoher bugged command?

    Oh yeah and ANOTHER thing...

    what is wrong with this code?

    spawn_character macedon Zethos, spy, command 0, influence 0, management 0, subterfuge 0, age 29, , x 193, y 138
    console_command give_trait Zethos GoodSpy 4

    because I get two spies!!!
    Last edited by Zhuge_Liang; July 17, 2009 at 08:28 AM.

  2. #2
    makanyane's Avatar Praeses
    Content Emeritus

    Join Date
    Feb 2006
    Posts
    9,093
    Blog Entries
    1

    Default Re: Script - Load problem

    I've never actually found that a script works properly if you re-load without quitting and re-starting Rome. Have tried the bit you quoted and with the press help when quitting thingy too.... Hopefully someone who has got it working can explain in words of one syllable!

    if I run the script directly from the desc_strat file then the load and save buttons are greyed out
    that would mean you're running it as a campaign script and not a background script - I think that is one of the known side effects - http://forums.totalwar.org/vb/showthread.php?t=46738

    you can use a campaign script activated from desc_strat to launch the background script but you won't be able to save until campaign script has terminated.

    Also on a side issue I scripted the movement of the camera but once the camera stops moving commands which follow it do not happen, is there a way to fix this or is this yet anoher bugged command?
    I found that and anything time related like the wait commands wouldn't work from inside a monitor_event (or if they did half work they spread the event commands over multiple turns!)

    it does work for me though if used in a non-monitor if statement eg
    if I_TurnNumber = 0
    .....
    or if in monitor_conditions
    not event

  3. #3

    Default Re: Script - Load problem

    Quote Originally Posted by makanyane View Post
    I've never actually found that a script works properly if you re-load without quitting and re-starting Rome. Have tried the bit you quoted and with the press help when quitting thingy too.... Hopefully someone who has got it working can explain in words of one syllable!

    that would mean you're running it as a campaign script and not a background script - I think that is one of the known side effects - http://forums.totalwar.org/vb/showthread.php?t=46738

    you can use a campaign script activated from desc_strat to launch the background script but you won't be able to save until campaign script has terminated.

    I found that and anything time related like the wait commands wouldn't work from inside a monitor_event (or if they did half work they spread the event commands over multiple turns!)

    it does work for me though if used in a non-monitor if statement eg
    if I_TurnNumber = 0
    .....
    or if in monitor_conditions
    not event

    Yeah, I had been running it as a background scipt, I just thought I was doing something wrong when trying to run it as a campaign script. If we run it as a campaign script we can have our choice on turn 0 whereas if it must be run as a background script then the choice dialog won't appear on turn 0 only turns 1+. This creates a small chance of a CTD because the choice envolves troop movements.

    As for the main issue of "the reloading", I was convinced I had that working earlier, but perhaps I was mistaken. I hate the idea of people having to make a whole lot of exceptions when they eventually play this mod just because of the script limitations.

    Also I discovered that I got 2 spies because I was spawning within a monitor
    Last edited by Zhuge_Liang; July 17, 2009 at 09:27 AM.

Posting Permissions

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