|
Milcoi Delcon
Registered User
Join date: 24 May 2007
Posts: 30
|
09-16-2007 22:32
Hi, I have this child script inside a prim and I'm rotating the entire linked object (by the root script) but want to let 2 prims stay on their place (start position) I added this but doesn't work: llGetLocalPos(llSetRot( llEuler2Rot( <45.0,0.0,0.0>*DEG_TO_RAD ))); vector pos; vector scale; integer procent;
default { state_entry(){ //get the position and scale pos = llGetLocalPos(); scale= llGetScale(); } link_message(integer sender,integer num,string str,key id){ if (str=="chosen"){ //stretch it procent = num; llSetPos(pos*procent/100); llSetScale(scale*procent/100); if (procent == 100); llGetLocalPos(llSetRot( llEuler2Rot( <45.0,0.0,0.0>*DEG_TO_RAD ))); } } }
any 1 a solution?
|
|
Gordon Wendt
404 - User not found
Join date: 10 May 2006
Posts: 1,024
|
09-16-2007 22:39
try llRotTarget, I haven't gotten a chance to figure that really out not to mention test it but that may help, it allows you to set a target stop for rotations though I'm not sure if that just applies locally or to the linkset.
_____________________
Twitter: http://www.twitter.com/GWendt Plurk: http://www.plurk.com/GordonWendt GW Designs: XStreetSL
|
|
Milcoi Delcon
Registered User
Join date: 24 May 2007
Posts: 30
|
09-17-2007 03:35
The entire object is scaling, that's fine. When they rotate thru the root script only 2 objects should not rotate but has to scale.
That's the problem.
So That's why I like to rotate them back into the starting postion.
|
|
Milcoi Delcon
Registered User
Join date: 24 May 2007
Posts: 30
|
09-18-2007 22:40
Still having problems..
The rotation of the child prims is working ok now. llSetLocalRot(llEuler2Rot(<........ did the trick
The entire linked"set" has to rotate also, even when attached. The problem now is that if i attache the linked set the rotation is not correct, it alway faces to 1 direction after starting the rotation.
I can reposition it but when start it happends again.
help me out please...ty
Milcoi
|