Loading joysticks.go +3 −5 Original line number Diff line number Diff line Loading @@ -302,12 +302,10 @@ func PositionFromVelocity(c chan Event) chan Event{ go func(){ var nx,ny float32 for t:=range ticker.C{ if vx!=0 || vy!=0{ nx,ny=x,y dt:=float32(t.Sub(lt).Seconds()) extra <-CoordsEvent{when{startMoment+t.Sub(startTime)},nx+dt*vx,ny+dt*vy} } } }() return extra Loading Loading
joysticks.go +3 −5 Original line number Diff line number Diff line Loading @@ -302,12 +302,10 @@ func PositionFromVelocity(c chan Event) chan Event{ go func(){ var nx,ny float32 for t:=range ticker.C{ if vx!=0 || vy!=0{ nx,ny=x,y dt:=float32(t.Sub(lt).Seconds()) extra <-CoordsEvent{when{startMoment+t.Sub(startTime)},nx+dt*vx,ny+dt*vy} } } }() return extra Loading