From 8dfa3654be2c719e35321b94503037b59c59df39 Mon Sep 17 00:00:00 2001 From: Samir Naik Date: Wed, 3 Dec 2003 21:29:23 +0000 Subject: [PATCH] fixed bug in makePathTrack --- direct/src/level/PathEntity.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/direct/src/level/PathEntity.py b/direct/src/level/PathEntity.py index 8e4dc97288..d6af79afa0 100755 --- a/direct/src/level/PathEntity.py +++ b/direct/src/level/PathEntity.py @@ -21,10 +21,10 @@ class PathEntity(BasicEntities.NodePathEntity): assert (len(self.path) > 1) # end with the starting point at the end, so we have a continuous loop - self.path = self.path + [self.path[0]] - for pointIndex in range(len(self.path) - 1): - startPoint = self.path[pointIndex] - endPoint = self.path[pointIndex + 1] + path = self.path + [self.path[0]] + for pointIndex in range(len(path) - 1): + startPoint = path[pointIndex] + endPoint = path[pointIndex + 1] # Face the endpoint v = startPoint - endPoint