Movement: Difference between revisions

Line 4: Line 4:


* Pressing nothing:
* Pressing nothing:
** Ground: Every tick <syntaxhighlight lang="c++" inline>velocy.x = velocy.x * 0.5</syntaxhighlight>
** Air: Every tick <syntaxhighlight lang="c++" inline>velocy.x = velocy.x * 0.95</syntaxhighlight>
** Air: Every tick <syntaxhighlight lang="c++" inline>velocy.x = velocy.x * 0.95</syntaxhighlight>
** Ground: Every tick <syntaxhighlight lang="c++" inline>velocy.x = velocy.x * 0.5</syntaxhighlight>
* Pressing key in opposite direction:
* Pressing key in opposite direction:
** Ground: Every Tick horizontal velocity decreases by 2 until 10 in the opposite direction is reached
** Ground: Every tick the horizontal velocity decreases by 2 until 10 in the opposite direction is reached
** Air: Every Tick horizontal velocity decreases by 1.5 until -5 in the opposite direction is reached
** Air: Every tick the horizontal velocity decreases by 1.5 until 5 in the opposite direction is reached
* Horizontal speed up by pressing {{Kbd|a}} or {{Kbd|d}}:
* Horizontal speed up by pressing {{Kbd|a}} or {{Kbd|d}}:
** Ground: Every Tick horizontal velocity increases by 2 until 10 is reached
** Ground: Every tick the horizontal velocity increases by 2 until 10 is reached
** Air: Every Tick horizontal velocity increases by 1.5 until -5 is reached
** Air: Every tick the horizontal velocity increases by 1.5 until 5 is reached


== Max speed ==
== Max speed ==