Hi,
I've been at this great program for a few days now, and I can't quite figure out how to make viewing things in another room possible - although I can, but I'm not yet satisfied with the result - maybe there is a better solution to the one I've tried:
Situation is the player is on the bridge of a spaceship. There is a "view port" object, and an exit "out" which is look only. When the player types "look at view port" or "look out", I get a little text description and then it runs a function I have defined, DescribeOutsideObjects, which currently takes an object as parameter. That parameter is the room that has been defined for the deck on the outside of the bridge (in space). I set it up like this because there will be lots of viewports, and I can for each view port just pass in the room (and maybe later rooms) that can be seen from a particular view port. The code looks like this:
<function name="DescribeOutsideObjects" parameters="Room">
if (ListCount(ScopeVisibleNotHeldNotSceneryForRoom(Room)) = 0) {
msg ("Nothing much going on outside, stars dont twickle in space.")
}
else {
msg (FormatObjectList("You can see", Room, "and", " on the hull of the ship", false))
}
</function>
So what my problem? Well I'm using the FormatObjectList function to display the contents of the room outside the ship, but the objects it displays have hyerlinks to verbs/commands which I don't want displayed. I couldn't find a suitable call to do this, and I didn't want to rewrite a whole function that deals with the syntax of a variable number of objects to describe them as text. The upshot is of course, the hyperlink appear, and are clicked upon, the automatic response of the system is "I can't see that", because of course the object isn't in the room.
That's not all of course, because I want to figure out how to intercept the "look at" for objects that are visible through viewports to give a different message than is given when the object is in the same room.
I'm probably digging myself into a hole, so any guidance would be appreciated. I kind of assumed when I saw the "make look direction only" toggle that there might already be a mechanism to sort this out, but haven't found that on the forum or wiki yet. Thanks.