I am passing 3 float values from another script to a script attached to the game object I want to move. The values are X position, Y position, and Z rotation. The rotation is constrained from -45 to 45. This script below seems to be working but I was wondering if there was a better way to accomplish this?
function Update () {
transform.position = new Vector3(gui.hLightSliderValue, gui.vFLightVert, 0);
transform.eulerAngles = Vector3(0,0,gui.hFLightAngle-90);
}