def __init__(self, robot, combined='b-', color=None, linewidth=3, linestyle=None, buffer_size=1000): body = PointMass( robot.com, robot.mass, name='RobotCOMState', visible=False) super(COMTrajectoryDrawer, self).__init__( body, combined, color, linewidth, linestyle) self.robot = robot
def get_com_point_mass(self): """ Get the center of mass as a PointMass instance. Returns ------- com : PointMass Center of mass of the robot. """ return PointMass(pos=self.com, mass=self.mass)