ui: playerteleporter: reduce the rotation error from a misfire that is just plain mean on long jumps
This commit is contained in:
parent
eaa8313cd1
commit
ac14a78d7f
@ -41,7 +41,7 @@ public class PlayerTeleporter {
|
|||||||
Random rand = new Random();
|
Random rand = new Random();
|
||||||
|
|
||||||
Vector travelVec = m_dest.toVector().subtract(m_src.toVector()).normalize();
|
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);
|
travelVec.rotateAroundY(angleDelta);
|
||||||
|
|
||||||
double distanceToDest = m_src.distance(m_dest);
|
double distanceToDest = m_src.distance(m_dest);
|
||||||
|
Loading…
Reference in New Issue
Block a user