02-03-2015, 02:26 AM
**Update**
ok so I changed the line in the curvylaser1 script from transform.parent.localEulerAngles = laserRotObject.localEulerAngles to laserStartPos; = transform.parent.localEulerAngles;
If I set the lasers speed to zero, (setorientation is true and dynamic is true) then it spawns right where it needs to be, in front of the ship at the ships rotation. Then when I change the speed to more then zero, the lasers rotation(the aligntospline component) wants to snap back to its default rotation. If I change the setOrientation to false, then it will shoot normally, infront of the ship at its rotation, but the laser will not keep its orientation along the spline, it will rotate a bit as it travels. If I uncheck dynamic, it will just spawn at its default position and rotation, position being zero and not that of the ship. It seems to want to "refresh" whenever dynamic is unchecked and setOrientation is checked. Im not sure if I should try and override the refresh command or what. I hope you can look at this and give me some anwsers cause im really struggling with this.
ok so I changed the line in the curvylaser1 script from transform.parent.localEulerAngles = laserRotObject.localEulerAngles to laserStartPos; = transform.parent.localEulerAngles;
If I set the lasers speed to zero, (setorientation is true and dynamic is true) then it spawns right where it needs to be, in front of the ship at the ships rotation. Then when I change the speed to more then zero, the lasers rotation(the aligntospline component) wants to snap back to its default rotation. If I change the setOrientation to false, then it will shoot normally, infront of the ship at its rotation, but the laser will not keep its orientation along the spline, it will rotate a bit as it travels. If I uncheck dynamic, it will just spawn at its default position and rotation, position being zero and not that of the ship. It seems to want to "refresh" whenever dynamic is unchecked and setOrientation is checked. Im not sure if I should try and override the refresh command or what. I hope you can look at this and give me some anwsers cause im really struggling with this.