[Opensim-users] creating bots at negative elevation

Justin Clark-Casey jjustincc at googlemail.com
Wed Feb 1 00:59:02 UTC 2012


To me, zero level is the co-ordinate z = 0, where it's totally illegal to try and place anything in a negative 
co-ordinate.  Under the water is different, at which point ground, to me, is the sea/riverbed.

On 01/02/12 00:52, Gudule Lapointe wrote:
> (JCC: Having seen the project, I know this is not "under the ground", but deep in the water, which goes far below zero level, due to project needs…)
>
> I wouldn't be surprised if NPC was just coded without thinking somebody would try to do this ;-)
>
> Paul, I would suggest using the NPC sit functions on an object at the desired position (http://opensimulator.org/wiki/OsNpcSit) to force the NPC go that deep, and after that you are free to make it stand or stay sitting…
>
>
>
> Le 1 févr. 2012 à 01:36, Justin Clark-Casey a écrit :
>
>> By negative elevation, I presume that you mean below some arbitrary plane, rather than below ground? ScenePresence.CompleteMovement(), which is how the NPC (and any avatar) enters a scene does have code to prevent attempted rezzing below ground.  This is just using a 1.5f constant.  It's possible that if you're very near the ground then you would have a problem.
>>
>> On 31/01/12 20:56, paul emery wrote:
>>> I need to create some bots in our model of titanic which is underwater AND in
>>> fact is at negative elevation. My trigger object has a notecard with the bot
>>> information in it and a script with a touch_start event handler.
>>> In the touch event are these lines of code.
>>>
>>> vector npcPos = llGetPos()+<.5,0,0>;
>>> pc = osNpcCreate("Mr.", "Bot", npcPos, "mycard");
>>>
>>> What i find is that if the object is at zero elevation or above the bot is
>>> created half a meter from the object's position. However, if the object is
>>> at a negative elevation the bot is created at zero elevation and falls down
>>> to the elevation of the trigger object. This is interesting. Note that if
>>> the trigger object is up at any positive elevation the bot is created at
>>> that elevation.
>>>
>>> The problem is that if i try to create a bot at a negative elevation in a
>>> room below deck i.e. that has a non-phantom roof the bot never can fall all
>>> the way down because they are not able to fall through the roof.
>>>
>>> Any body got any ideas on how do deal with this. It does seem like expected
>>> behavior would be to allow npcPos() to include negative elevation.
>>>
>>>
>>> --
>>> View this message in context: http://opensim-users.2152040.n2.nabble.com/creating-bots-at-negative-elevation-tp7241166p7241166.html
>>> Sent from the opensim-users mailing list archive at Nabble.com.
>>> _______________________________________________
>>> Opensim-users mailing list
>>> Opensim-users at lists.berlios.de
>>> https://lists.berlios.de/mailman/listinfo/opensim-users
>>>
>>
>>
>> --
>> Justin Clark-Casey (justincc)
>> http://justincc.org/blog
>> http://twitter.com/justincc
>> _______________________________________________
>> Opensim-users mailing list
>> Opensim-users at lists.berlios.de
>> https://lists.berlios.de/mailman/listinfo/opensim-users
>
> _______________________________________________
> Opensim-users mailing list
> Opensim-users at lists.berlios.de
> https://lists.berlios.de/mailman/listinfo/opensim-users
>


-- 
Justin Clark-Casey (justincc)
http://justincc.org/blog
http://twitter.com/justincc



More information about the Opensim-users mailing list