added Vertex method to allow for +=

This commit is contained in:
Stephen M. McQuay 2012-05-30 22:57:26 -06:00
parent 443363a7a4
commit 23f343a608
1 changed files with 2 additions and 0 deletions

View File

@ -95,6 +95,8 @@ class Vertex(list):
# for now just assume type(other) = Vertex... bad, I know
return Vertex(self.x + other.x, self.y + other.y, self.z + other.z)
__iadd__ = __add__
def __radd__(self, other):
return other + self