Moves the body along a vector. If the body collides with another, it will slide along the other body rather than stop immediately. If the other body is a KinematicBody or RigidBody, it will also be affected by the motion of the other body. You can use this to make moving or rotating platforms, or to make nodes push other nodes.
linear_velocity is a value in pixels per second. Unlike in for example moveAndCollide, you should not multiply it with delta — this is done by the method.
floor_normal is the up direction, used to determine what is a wall and what is a floor or a ceiling. If set to the default value of Vector3(0, 0, 0), everything is considered a wall. This is useful for topdown games.
TODO: Update for new stop_on_slode argument. If the body is standing on a slope and the horizontal speed (relative to the floor's speed) goes below slope_stop_min_velocity, the body will stop completely. This prevents the body from sliding down slopes when you include gravity in linear_velocity. When set to lower values, the body will not be able to stand still on steep slopes.
If the body collides, it will change direction a maximum of max_slides times before it stops.
floor_max_angle is the maximum angle (in radians) where a slope is still considered a floor (or a ceiling), rather than a wall. The default value equals 45 degrees.
Returns the movement that remained when the body stopped. To get more detailed information about collisions that occurred, use getSlideCollision.
Moves the body along a vector. If the body collides with another, it will slide along the other body rather than stop immediately. If the other body is a KinematicBody or RigidBody, it will also be affected by the motion of the other body. You can use this to make moving or rotating platforms, or to make nodes push other nodes. linear_velocity is a value in pixels per second. Unlike in for example moveAndCollide, you should not multiply it with delta — this is done by the method. floor_normal is the up direction, used to determine what is a wall and what is a floor or a ceiling. If set to the default value of Vector3(0, 0, 0), everything is considered a wall. This is useful for topdown games. TODO: Update for new stop_on_slode argument. If the body is standing on a slope and the horizontal speed (relative to the floor's speed) goes below slope_stop_min_velocity, the body will stop completely. This prevents the body from sliding down slopes when you include gravity in linear_velocity. When set to lower values, the body will not be able to stand still on steep slopes. If the body collides, it will change direction a maximum of max_slides times before it stops. floor_max_angle is the maximum angle (in radians) where a slope is still considered a floor (or a ceiling), rather than a wall. The default value equals 45 degrees. Returns the movement that remained when the body stopped. To get more detailed information about collisions that occurred, use getSlideCollision.