ui: playerteleporter: reduce the rotation error from a misfire that is just plain mean on long jumps

This commit is contained in:
Torrie Fischer 2021-06-15 13:06:59 -07:00
parent eaa8313cd1
commit ac14a78d7f

View File

@ -41,7 +41,7 @@ public class PlayerTeleporter {
Random rand = new Random();
Vector travelVec = m_dest.toVector().subtract(m_src.toVector()).normalize();
double angleDelta = (Math.PI / 3) * (rand.nextGaussian() - 0.5) * (1-accuracy);
double angleDelta = (Math.PI / 5) * (rand.nextGaussian() - 0.5) * (1-accuracy);
travelVec.rotateAroundY(angleDelta);
double distanceToDest = m_src.distance(m_dest);