Hello,
I could not write this script for touch button. Can you convert to input.touch?
#pragmastrict
var speed = 45.0;
var rt : Quaternion;
function Start() {
rt = Quaternion.identity;
}
function Update() {
if (Input.GetKeyDown(KeyCode.E))
rt = Quaternion.Euler(0.0, 0.0, 10.0);
else if (Input.GetKeyUp(KeyCode.E))
rt = Quaternion.identity;
transform.rotation = Quaternion.RotateTowards(transform.rotation, rt, speed * Time.deltaTime);
}