Jump to content

Ye Olde Disappearing Hendak Bugge


Wisp

Recommended Posts

I see this issue is listed under "Dismissed 'bugs'", however, I think this is an actual, reproducible issue that can be solved (that, is, worked around).

 

Naturally, the first point is reproducibility. I have found that I can make Hendak "disappear" or move under the right circumstances by using CTRL+T or resting in a different area. Outside the Copper Coronet or in the sewers under the CC* should work and making a day go by should be sufficient.

 

*sewers do not work

 

Next issue is obviously which circumstances are the right ones. As I quickly found, Hendak only moves if he used a JumpToPoint action to get to Lehtinan's location. If he walked up to the location by himself, he will stay there.

 

Now then, why does he move? Going by the actor bytes of the are files in save games, it would appear as if he moves because when he uses a JumpToPoint, he still retains the destination coordinates of his last MoveToPointNoInterrupt. True enough, when he moves, he ends up at his destination coordinates.

 

This can mean he relocates to a point along the path he walked before his JumpToPoint (e.g. here or here) or seemingly disappear altogether (e.g. here [he is supposed to be at the cursor location according to the information in the save, which is roughly inside the wall]). Presumably this disappearing altogether is the result of some wonky path finding. Indeed, among the 20 or so cases I have observed so far, the by far most common result is that he relocates to a valid point along the path he is supposed to walk.

 

As for how to fix this, I would suggest something along these lines:

 

COPY_EXISTING "hendak.bcs" "override"
 DECOMPILE_BCS_TO_BAF
REPLACE_TEXTUALLY EXACT_MATCH "JumpToPoint([526.1193])" "JumpToPoint([525.1192]) MoveToPointNoInterrupt([526.1193])"
 COMPILE_BAF_TO_BCS
IF // Will return false unless JumpToPoint is the last action in its script block. Will also return false if the point is one other than [526.1193]
~AC
48OB
0 0 0 0 0 0 0 0 0 0 0 0 ""OB
OB
0 0 0 0 0 0 0 0 0 0 0 0 ""OB
OB
0 0 0 0 0 0 0 0 0 0 0 0 ""OB
0 526 1193 0 0"" "" AC
RE~

 

He should then reproducibly get the destination coordinates [525.1192] (for whatever reason), which will be the same as his (at the time) current location.

Obviously it is not a very elegant solution and even if no better method of fixing his destination coordinates can be achieved, the above code may benefit from being refined.

 

Edited for comment

Link to comment

If so, it does not appear to work. At least not in this case. (I did test that before devicing the work-around.)

If you set it to [526.1193] or another "valid" value, Hendak still eventually ends up at the point he was going to before doing his JumpToPoint.

 

As far as I can tell, the others actors that use SetHomeLocation are stationary. Raissa and Hendak are the only exceptions. Raissa performs one MoveToPoint, so she never has Hendak's problem of having a series of destinations assigned to her. She also does not generally stick around like Hendak does.

By the looks of it, Hendak is fairly unique in this respect.

Link to comment

SetHomeLocation() merely updates the location coordinates for the character (the Move* actions automatically do this, but JumpToPoint() doesn't). With an incorrect home location, the character will eventually move when the area gets reset (all actors are restored to their home locations after a certain period of time, just as ground piles and other rot in the .AREs occasionally gets cleaned up).

 

Since he sticks around forever, it should always be performed before he Jump()s so that those coordinates get updated. It should work correctly as far as I can remember.

Link to comment

Aha. The problem is that he performs MoveToPointNoInterrupts after he does his SetHomeLocation.

If he does a SHL just before Jumping, it works correctly and he stays put.

 

The proper fix would then be something along the lines of

 

COPY_EXISTING "hendak.bcs" "override"
 DECOMPILE_BCS_TO_BAF
REPLACE_TEXTUALLY EXACT_MATCH "SetHomeLocation([32.120])" "SetHomeLocation([526.1193])"
REPLACE_TEXTUALLY EXACT_MATCH "JumpToPoint([526.1193])" "SetHomeLocation([526.1193]) JumpToPoint([526.1193])"
 COMPILE_BAF_TO_BCS
UNLESS // True unless there already is a SetHomeLocation before JumpToPoint.
~AC
261OB
0 0 0 0 0 0 0 0 0 0 0 0 ""OB
OB
0 0 0 0 0 0 0 0 0 0 0 0 ""OB
OB
0 0 0 0 0 0 0 0 0 0 0 0 ""OB
0 526 1193 0 0"" "" AC
AC
48OB~

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...