Help! I’m lost in a twisty little maze with exits in all directions! Don’t know where to go next!
I admit, it’s a problem of my own making. I am nearing the final scenes of the game, so it’s a bit complex to isolate in a test-bed environment and a bit long to be posting code, but here’s the problem as best as I can describe it…
Harry rescues Grace, who is bound and gagged in an upstairs room. The act of releasing her bonds triggers a grace.fDaemon, and Grace starts following Harry down the stairs, through the house, into the basement and into a hidden room. They meet up with Aaron, and Harry starts following Aaron, with Grace still following Harry. Max has also joined the party, following Harry as he follows Aaron.
So far, so good.
Thanks to help received yesterday on the FollowAgendaItem, everything was working great. Everybody was following as designed.
Then I did something and the whole house of cards came crashing down. What? Don’t know. That’s the twisty little maze I’m stuck in.
The code where grace followed Harry through the house has been in place for some time, and I did not edit it yesterday.
The crash occurred after I tried to bring in two more characters into the hidden room in the basement.
There is a commotion somewhere in the house, triggered by a Daemon that runs a StopEventList, and when it’s done, Lolita and Felipe join the crowd in the basement.
But suddenly, I discover that Grace no longer follows Harry out of the upstairs room, way back in the house, several moves prior. I haven’t touched any of that code for quite some time, but Grace no longer follows Harry down into the basement.
I see in the debugger that grace.fDaemon is not nil—she should be following.
But she doesn’t.
The initial sequence is, in the upstairs room when her bonds are cut, the fDaemon is triggered—which does happen, I can see it in the debugger—but when Harry leaves the room, she stays put.
This all worked yesterday afternoon (before I tried to bring Lolita and Felipe into the picture), now it doesn’t. I can see nothing in the lolita or felipe actor code that should have anything to do with grace suddenly not following several moves back, when she has been following reliably for some time prior to my mistake (whatever that may have been; I’m guessing I fat-fingered some existing code, but it does still compile correctly).
I know this is a long shot, but any tips on what I should look for would be appreciated.
Are there any values that I can examine in the fDaemon in the debugger that might shed some light on the problem? (I’ve looked, but nothing jumps out. It’s a complex structure, though, so maybe there’s something I should look for?)
Jerry