fix problem in returning to home

This commit is contained in:
2018-11-15 16:37:54 +01:00
parent bf92632485
commit f2b7d27911
6 changed files with 47 additions and 49 deletions
+2 -5
View File
@@ -92,11 +92,8 @@ public class Walk : MonoBehaviour
}
else
{
Vector3 t2 = s[t].pos;
t2.x *= walkspeed;
// rotate x,y around rotation.
step2[index] = (Quaternion.Euler(0, rotation, 0) * t2) / speed2;
Vector3 t2 = (legsInitial[index] + s[t].pos) - legs[index].GetComponent<Leg>().point;
step2[index] = t2 / speed2;
}
}