def display_pointer(self, mass=40): stroke(255) fill(100) theta = self.velocity.angle with push_matrix(): translate(self.location.x, self.location.y) rotate_z(theta + PI / 2) triangle((0, -mass / 2), (-mass / 4, mass / 2), (mass / 4, mass / 2)) fill(0, 255, 0) circle((self.location.x, self.location.y), 5)
def display(self): stroke(255) fill(255) theta = self.velocity.angle with push_matrix(): translate(self.location.x, self.location.y) rotate_z(theta + PI / 2) triangle( (0, -self.mass / 2), (-self.mass / 4, self.mass / 2), (self.mass / 4, self.mass / 2), ) fill(0, 255, 0) circle((self.location.x, self.location.y), 5)