A slight issue has arisen with the Caledon Directory, in that, ahem, it doesn’t work. Well, to be fair to myself it does work in Caledon I, and it does produce a map with all of the landmarks placed appropriately - it is just that when one touches a landmark outside of Caledon I and opts to Teleport, one does not actually go there.
The reason for this is simple. The Directory holds a number of landmarks, which as I am sure you are aware are a specific and special type of object in Second Life. A script may only read the contents of a landmark via the llRequestInventoryData function (as it happens, this function can only read the contents of a landmark) and the datum returned is the position of that landmark.
Here is the issue: that position is a local position in the sim that the call was made. Thus, if my Directory makes the call from Caledon I relating to the Takashi Estate, say, the returned position is <413, 393, 39> even though the position within the Caledon Highlands is <156, 136, 39>. Now, there is currently no way to retrieve the name of a sim from its global co-ordinates (found by adding the value of llGetRegionCorner) thus the poor Directory is forced to tell the map that the location is, indeed, Caledon (413, 393, 39).
It is fortunate that the map is able to interpret this into a proper position for the little lightbulb icon, but when it comes to travelling back to the Grid, alas, it fails. A secondlife://SimName/X/Y/ link is used and this is not able to interpret a co-ordinate actually outside the sim in question. Try it for yourself - you will simply be pointed to Caledon (256,256) which is not a useful position in the slightest.
From delving into the Javascript behind the Map API (an activity which requires heavy rubber clothing and vaccination beforehand) I was able to ascertain that there is a function therein which translates global positions to the name of their sims, but there are good reasons why one not should not use functions which are not actually part of the API itself; they may change at a moment’s notice. In any case it would be an inelegant hack to use such.
So, well, I had hopes for the simplicity of the approach that I was using, simply holding landmarks, but it seems that it is not perfect. I have a few other ideas involving such things as an additional central list of locations, but they are not quite as elegant.
During conversation, the idea of a device attached to one which repeats notes pertaining to the current location came up, and I have a prototype of such which allows one to records such notes. It might be an idea to create one which is controlled purely by a notecard, a tour guide if you will, which gives the wearer enlightening information when they are within a certain distance of a notable landmark, in a manner similar to the automatic tour guide devices provided by certain Museums, yet less annoying, as it would not require one to follow a certain path and also to listen to irrelevant dronings on the luncheon habits of some long-dead artistic gadabout.
Edit: and now, thanks to the expertise of my readers, it is working. Lawks!




Recent Comments