Hint for dealing with sayFollowing (a3lite)

after realising that sayFollowing (and actorSayFollowing) don’t recognise the (removed) travel barriers, I lost four hours in figuring an acceptable solution, which of course I pass to fellow coders:
(actual NPC, but no spoilers)

sayFollowing(oldLoc, conn)
  {
//    seems that conn don't recognise barriers... lost near 4hrs !!
  local follower = getActor, pc = gPlayerChar;
        gMessageParams(follower, pc);
  iffy: {
    if(oldLoc == living && gRoom == mezzanine)
     {
"Azuj follow you, with a wingbeat ! She smiles happily. \"I, Lefty and Righty 
have done well ?";
      break iffy;
      }
DMsg(follow, '<.p>{The follower} follow{s/ed} behind {the pc}. ');
    } // iffy
  } //sayFollowing

hope this can be of help… because figuring this (basically, replacing conn with gRoom) required four hour of failed testing and “back to square one”…) I gift my solution to the problem in the IF collective knowledge archive.

Best regards from Italy,
dott. Piergiorgio.

1 Like