game_qu.base.quadratic_equations API documentation

# Module `game_qu.base.quadratic_equations`

Expand source code

    import math

    from game_qu.base.important_variables import SCREEN_HEIGHT
    from game_qu.base.utility_functions import get_kwarg_item, solve_quadratic
    from game_qu.base.velocity_calculator import VelocityCalculator
    from game_qu.math.function import Function
    from game_qu.math.physics_function import PhysicsFunction
    from game_qu.math.quadratic_function import QuadraticFunction
    from game_qu.paths.physics_followable_path import PhysicsFollowablePath

    class QuadraticEquation(QuadraticFunction):
        """The same class as QuadraticFunction, but this is kept to keep the API the same between library versions"""

        pass

    class PhysicsEquation(PhysicsFunction):
        """The same class as PhysicsFunction, but this is kept to keep the API the same between library versions"""

        pass

    class PhysicsPath(PhysicsFollowablePath):
        """The same class as PhysicsFollowablePath, but this is kept to keep the API the same between library versions"""

        pass

## Classes

`class PhysicsEquation`

  The same class as PhysicsFunction, but this is kept to keep the API the same between library versions

  Expand source code

      class PhysicsEquation(PhysicsFunction):
          """The same class as PhysicsFunction, but this is kept to keep the API the same between library versions"""

          pass

  ### Ancestors

  - PhysicsFunction

  ### Inherited members

  - `PhysicsFunction`:
    - `get_a_b_and_c`
    - `get_displacement`
    - `get_displacement_due_to_acceleration`
    - `get_displacement_due_to_velocity`
    - `get_distance`
    - `get_full_cycle_time`
    - `get_indefinite_integral_of_acceleration_equation`
    - `get_indefinite_integral_of_position_equation`
    - `get_indefinite_integral_of_velocity_equation`
    - `get_time_to_vertex`
    - `get_times_to_point`
    - `get_velocity_using_displacement`
    - `get_velocity_using_time`
    - `get_vertex`
    - `set_acceleration_with_displacement`
    - `set_acceleration_with_velocity`
    - `set_all_variables`
    - `set_variables`
    - `set_velocity_with_displacement`
`class PhysicsPath (**kwargs)`

  The same class as PhysicsFollowablePath, but this is kept to keep the API the same between library versions

  Initializes the object

  ## Args

  `game_object` :`GameObject`
    the game object that is following this path
  `attribute_modifying` :`str`
    the name of the attribute this path is modifying
  `time` :`float`
    the time to the vertex of the path
  `height_of_path` :`float`
    the difference between the initial distance and the vertex of the path
  `max_time` :`float`
    the max time of the path - the time the path should end (None if the path should not end)

  ## Returns

  None

  Expand source code

      class PhysicsPath(PhysicsFollowablePath):
          """The same class as PhysicsFollowablePath, but this is kept to keep the API the same between library versions"""

          pass

  ### Ancestors

  - PhysicsFollowablePath
  - FollowablePath
  - abc.ABC
  - PhysicsFunction

  ### Inherited members

  - `PhysicsFollowablePath`:
    - `get_a_b_and_c`
    - `get_acceleration_displacement`
    - `get_acceleration_displacement_from_time`
    - `get_delta_value`
    - `get_displacement`
    - `get_displacement_due_to_acceleration`
    - `get_displacement_due_to_velocity`
    - `get_distance`
    - `get_final_velocity`
    - `get_full_cycle_time`
    - `get_indefinite_integral_of_acceleration_equation`
    - `get_indefinite_integral_of_position_equation`
    - `get_indefinite_integral_of_velocity_equation`
    - `get_time_to_vertex`
    - `get_times_to_point`
    - `get_total_displacement`
    - `get_value_at_time`
    - `get_velocity_displacement`
    - `get_velocity_using_displacement`
    - `get_velocity_using_time`
    - `get_vertex`
    - `has_finished`
    - `is_done`
    - `reset`
    - `restart`
    - `run`
    - `set_acceleration_with_displacement`
    - `set_acceleration_with_velocity`
    - `set_all_variables`
    - `set_initial_distance`
    - `set_variables`
    - `set_velocity_with_displacement`
    - `start`
`class QuadraticEquation`

  The same class as QuadraticFunction, but this is kept to keep the API the same between library versions

  Expand source code

      class QuadraticEquation(QuadraticFunction):
          """The same class as QuadraticFunction, but this is kept to keep the API the same between library versions"""

          pass

  ### Ancestors

  - QuadraticFunction
  - Function
  - abc.ABC

  ### Inherited members

  - `QuadraticFunction`:
    - `get_a_b_and_c`
    - `get_area_under_curve`
    - `get_indefinite_integral`
    - `get_indefinite_integral_using_quadratic_form`
    - `get_indefinite_integral_using_vertex_form`
    - `get_inverted_function`
    - `get_new_function`
    - `get_number`
    - `get_x_coordinate`
    - `get_x_coordinates`
    - `get_y_coordinate`
    - `points_set_variables`
    - `set_variables`