mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-04 10:54:24 -04:00
fixed bug in makePathTrack
This commit is contained in:
parent
e1ae6ee0b3
commit
8dfa3654be
@ -21,10 +21,10 @@ class PathEntity(BasicEntities.NodePathEntity):
|
|||||||
assert (len(self.path) > 1)
|
assert (len(self.path) > 1)
|
||||||
|
|
||||||
# end with the starting point at the end, so we have a continuous loop
|
# end with the starting point at the end, so we have a continuous loop
|
||||||
self.path = self.path + [self.path[0]]
|
path = self.path + [self.path[0]]
|
||||||
for pointIndex in range(len(self.path) - 1):
|
for pointIndex in range(len(path) - 1):
|
||||||
startPoint = self.path[pointIndex]
|
startPoint = path[pointIndex]
|
||||||
endPoint = self.path[pointIndex + 1]
|
endPoint = path[pointIndex + 1]
|
||||||
# Face the endpoint
|
# Face the endpoint
|
||||||
v = startPoint - endPoint
|
v = startPoint - endPoint
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user