Gryff Richard
Registered User
Join date: 10 Nov 2005
Posts: 51
|
08-23-2009 23:40
Not sure if this is the right place to post my question ... but will give it a try  I'm trying to stop an avatar ending up with a strange viewpoint ( eg next door) when he/she sits on a piece of furniture. To do this I used a little script like this that sets two of a prim's hidden properties: default { state_entry() { llSetCameraEyeOffset(<-2, 0, 1>  ; llSetCameraAtOffset(<2, 0, 1>  ; } } Now, if I have walked up to the chair using the movement controls and chose to sit, it triggers the animation and I get the view I want. However, if I have used any kind camera movement before sitting, then it does not behave the way I want and I get all kinds of different views. Is there a way around this ? TY in advance for any help. Gryff 
|
Vance Adder
Registered User
Join date: 29 Jan 2009
Posts: 402
|
08-24-2009 07:07
I would suggest you look at llSetCameraParams. See these two links:   You basically want to check when the user sits on the furniture and set their camera view accordingly. I also know of a few cheap (free?) scripts on SLX that will let you set the sitting camera view.
|
EF Klaar
Registered User
Join date: 11 Jun 2007
Posts: 330
|
08-24-2009 08:49
I think the same constraint applies to llSetCameraParams; unless your cam is in the default view (via the esc key), it does not work.
|
Domchi Underwood
Registered User
Join date: 4 Aug 2007
Posts: 44
|
08-24-2009 09:02
You're correct EF, the same goes for llSetCameraParams. There's no way to override non-default camera angle through LSL. However, is it really a problem? If a user has set his camera viewpoint to what suits him, than he'll probably want it to stay that way even when he sits.
|
Argent Stonecutter
Emergency Mustelid
Join date: 20 Sep 2005
Posts: 20,263
|
08-24-2009 09:21
To return camera view to default while sitting hit shift-left or shift-right.
|
Gryff Richard
Registered User
Join date: 10 Nov 2005
Posts: 51
|
08-24-2009 12:26
Well TY for the replies. I had a feeling there was likely no solution. I did think about creating a camera ... but that did not seem natural as I believe it requires getting permissions. And if it also has the same problem ... glad I was warned  I have found that once sitting with the hidden parameters set ...that just trying to move backwards/fowards with the little movement hud/controls results in the default camera view being restored. The reason I was investigating was to get around the avatar ending up viewing the wallpaper from the room next door - which seems to happen  Gryff 
|
Jesse Barnett
500,000 scoville units
Join date: 21 May 2006
Posts: 4,160
|
08-24-2009 12:37
Jopsy has a pretty decent overview on camera controls in his new Vehicle Laboratory. http://slurl.com/secondlife/Slate/182/45/262
_____________________
I (who is a she not a he) reserve the right to exercise selective comprehension of the OP's question at anytime. From: someone I am still around, just no longer here. See you across the aisle. Hope LL burns in hell for archiving this forum
|
Rolig Loon
Not as dumb as I look
Join date: 22 Mar 2007
Posts: 2,482
|
08-24-2009 12:49
I had to deal with exactly the same question last week as I was building tutorial displays for a newbie orientation area. As you've discovered, there's really no foolpoof way to be sure that all people will have the same camera view angle when they sit on the same object. If they have moved the camera at all, you can't override the non-default camera angle they have produced. My solution was to post a large sign that says,"Camera tip: When you are seated, you can control your viewing perspective with the arrow keys," accompanied by a small graphic illustration.
_____________________
It's hard to tell gender from names around here but if you care, Rolig = she. And I exist only in SL, so don't ask....  Look for my work in XStreetSL at 
|