TTLG|Thief|Bioshock|System Shock|Deus Ex|Mobile
Results 1 to 15 of 15

Thread: AI Patrol issue after reload

  1. #1
    Member
    Registered: Dec 2003
    Location: ...nothing but flames...

    AI Patrol issue after reload

    OK, I am throwing up my hands, and asking the Dromed Brain Trust for help.

    In my most recent mission (yeah, that one) there were a few minor bugs (all now fixed , BTW), but some annoying patrol quirks that I could never pin down. Playtesters reported it, sometimes. I never saw it. deadline was approaching. Yada yada.

    Anyway, I was finally able to reproduce the quirky patrol problems (and after I had fixed everything else - really).

    Normal mission
    Start the mission, Easy difficulty (i.e., Garrett mission, if you're keeping track).
    No problems.

    Everything goes to hell mission
    Start the mission, Easy difficulty. ...
    Quicksave. Reload.
    No problems.
    Quicksave. Reload.
    Now, AI are reteleporting, ignoring their patrol paths and wandering about, dogs and cats living together... You get the idea.

    So, I am not expecting that this kind of bug is covered in the Dromed 101 tutorial (although, if it is, I'll just go back to Scrabble, even though my wife cheats). What I am interested in, is how to debug this and prevent it from happening again.

  2. #2
    Member
    Registered: Dec 2003
    Location: ...nothing but flames...
    A bit more information:
    - There seems to be no difference between a Quicksave and a normal Save. Both can produce the problem.
    - Any Save can potentially produce the problem. The second, the third, the eighth - it seems random.
    - It can happen if no conversations are active.
    - It can happen if only one AI is patrolling.
    - The AI can sometimes recover after a subsequent save and load.

  3. #3
    Master Builder 2018
    Registered: Jul 2008
    Are the AI teleported from air or solid? AI teleported from air often don't find patrol routes, but that may not be the issue, or the only issue, in your case. See this post though.

  4. #4
    Member
    Registered: Dec 2003
    Location: ...nothing but flames...
    The AI are teleported from air, then the M-DoesPatrol metaprop is added, so that should be good. (but you never know)

    The curious thing is that when the problem occurs and you reload the save
    1. the AI reappears at the teleport point, and begins a normal patrol
    or
    2. the AI reappears at the teleport point, and begins a brain dead patrol
    or
    3. other AI swap patrol paths, and stop when they get to a door that they don't have a key for.

    I believe I've ruled out having too many AI patrolling, or having too many never-efficient AI. Going to experiment with no teleporting next

  5. #5
    Member
    Registered: Dec 2003
    Location: ...nothing but flames...
    Hmm... teleporting from solid is no better than from air. Still buggy.

    But, NOT teleporting seems to have done the trick on a small scale (or at least I'm back to not-reproducible). Now to figure out how to retrofit.

  6. #6
    Member
    Registered: Apr 2011
    This sounds to me like your AI is sometimes just picking the wrong patrol point after the teleport. If this is indeed the case, you can explicitly create an AICurrentPatrol link after the teleport, but before adding the metaprop. (Note that TrapTeleporter will break AICurrentPatrol links when it does its thing, although Object.Teleport in scripts will not.)

  7. #7
    Member
    Registered: Dec 2003
    Location: ...nothing but flames...
    True, but that doesn't explain why a reload would cause an AI to re-teleport. The conversation that frobs the button that does the teleports deletes its starting link as a first step, so it should not be triggered a second time, right?

  8. #8
    Member
    Registered: Jan 2006
    Location: On the tip of your tongue.
    I've no idea what's gone wrong, but have you tried loading the offending save in Dromed and checking the state of all relevant triggers, traps etc. Also worth generating a report from the save and running a compare to the base mission report. NVSpy is also pretty handy for debug.

  9. #9
    Member
    Registered: Dec 2003
    Location: ...nothing but flames...
    I love NVSpy, but it doesn't help me here, since I, er, haven't figured out how to load a save into Dromed.

  10. #10
    Member
    Registered: May 2002
    Location: Texas
    It might also help to delete the conversation marker at the kast step.

    I have noticed that sometimes AI will just stand around if they were in a conversation and the conversation got interrupted. The archer in First City Bank in the convo with the other guard about working overnight will sometimes get stuck and won't do anything unless he sees the player attack him or he is informed by another AI.

  11. #11
    Member
    Registered: Jan 2001
    Location: Pushing my luck with Dromed
    Deleting the CD link to the conv rules out the idea that the trigger is firing again, and suggests the player is saving while the conv is still active (assuming the Save Conversation property is True).

    If this is a long conversation (AI speaking, going to places etc) then it's to be expected that the player might save and reload while it's still going. If it should be very quick (e.g. a set of steps such as Frob object, Add Metaprop, Add Link etc), it'll be almost impossible for a player to save before it finishes, which suggests some bug is preventing it from ending properly (e.g if some other conv takes over one of the actors).

    Best solution for the first scenario: Add a RelayTrap with the prop 'Trap Control Flags: Once' between the button and each TeleportTrap. You could also add that prop to each TeleportTrap but that could be tedious.
    That solution will also work for the second scenario, but it'll only be masking a bug if something is indeed stopping the conv fron ending properly.

  12. #12
    Master Builder 2018
    Registered: Jul 2008
    Quote Originally Posted by Balboa View Post
    I love NVSpy, but it doesn't help me here, since I, er, haven't figured out how to load a save into Dromed.
    The command to load a saved game is: edit_load_game followed by a space and then the file location/name. For example, to load a quicksave use:

    edit_load_game saves/quick.sav

    I imagine it will work with other saved game names such as game0001.sav etc.

    If you want to save it afterwards, use:

    edit_save_game saves/quick.sav

  13. #13
    Member
    Registered: Dec 2003
    Location: ...nothing but flames...
    Excellent observation, R Soul.

    Adding the RelayTraps with Once enabled did seem to resolve the issue, but you were right (no surprise) that the conversation might be being stopped from ending. I had three chained conversations using the same Actor. The last thing each did was start the next, then an MPrint. It looked fine in Dromed, but apparently never fully completed in game.

    Combining all three conversations into one also seems to have fixed things. That makes me feel better. Apparently, you can fix stupid, after all.

  14. #14
    Member
    Registered: Dec 2003
    Location: ...nothing but flames...
    I tried that, Tannar. I get this error in the Monolog: ERROR: failed to load savegame, mission file 20 not found

    I am assuming that it refers to miss20.mis, but I put it everywhere and it still doesn't find it.

  15. #15
    Master Builder 2018
    Registered: Jul 2008
    I would guess that the save file needs to be in the SAVES subfolder in the same root that the .mis file is in.

Posting Permissions

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