change phase offset of running animation to +pi/2

This commit is contained in:
Haowei Wen 2020-09-06 17:25:49 +08:00
parent a41f7f3a96
commit e7a9267b9c
No known key found for this signature in database
GPG Key ID: 5BC167F73EA558E4
1 changed files with 1 additions and 1 deletions

View File

@ -162,7 +162,7 @@ export const WalkingAnimation: Animation = (player, time) => {
export const RunningAnimation: Animation = (player, time) => {
const skin = player.skin;
time *= 15;
time = time * 15 + Math.PI * 0.5;
// Leg swing with larger amplitude
skin.leftLeg.rotation.x = Math.cos(time + Math.PI) * 1.3;