air friction for vertical velocity
This commit is contained in:
		
							parent
							
								
									a21246e016
								
							
						
					
					
						commit
						fb375e352b
					
				| @ -163,6 +163,9 @@ function Player:DoPhysics() | ||||
|     else | ||||
|       self.vel.x = self.vel.x * (1-self.airFriction) | ||||
|     end | ||||
| 
 | ||||
|     self.vel.y = self.vel.y * (1-self.airFriction) | ||||
| 
 | ||||
|     if math.abs(self.vel.x) < self.zeroSpeed then self.vel.x = 0 end | ||||
|   end | ||||
| 
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user