commit 81b2f9c8bd34d1b24f86c252ad47eaffbd4f7c1c
parent e238cf4bcb6061fd6f5282b3fe5c5008d6007326
Author: Gerd Beuster <gerd@frombelow.net>
Date: Mon, 8 Feb 2021 21:11:44 +0100
Update for Python 3
Diffstat:
23 files changed, 71 insertions(+), 503 deletions(-)
diff --git a/.gitignore b/.gitignore
@@ -0,0 +1,3 @@
+*.ppe
+*.pyc
+__pycache__/+
\ No newline at end of file
diff --git a/BUGS.txt b/BUGS.txt
@@ -0,0 +1,6 @@
+The following programs throw errors:
+
+Controlled Eruption.py
+wx test 2.py
+wx test.py
+
diff --git a/Catherine wheel.py b/Catherine wheel.py
@@ -9,7 +9,7 @@ clock = pygame.time.Clock()
wheel = PyIgnition.ParticleEffect(screen, (0, 0), (600, 600))
flame = wheel.CreateSource((300, 300), initspeed = 20.0, initdirection = 0.0, initspeedrandrange = 0.0, initdirectionrandrange = 0.5, particlesperframe = 3, particlelife = 50, drawtype = PyIgnition.DRAWTYPE_SCALELINE, colour = (255, 200, 200), length = 20.0)
-sparks = wheel.CreateSource((300, 300), initspeed = 1.0, initdirection = 0.0, initspeedrandrange = 0.9, initdirectionrandrange = 3.141592653, particlesperframe = 1, particlelife = 300, genspacing = 3, drawtype = PyIgnition.DRAWTYPE_IMAGE, imagepath = "spark.png")
+sparks = wheel.CreateSource((300, 300), initspeed = 1.0, initdirection = 0.0, initspeedrandrange = 0.9, initdirectionrandrange = 3.141592653, particlesperframe = 1, particlelife = 300, genspacing = 3, drawtype = PyIgnition.DRAWTYPE_IMAGE, imagepath = "Spark.png")
wheel.CreateDirectedGravity(strength = 0.05, direction = [0, 1])
velocity = 0.1
diff --git a/Fire.ppe b/Fire.ppe
@@ -1,94 +0,0 @@
-<?xml version = "1.0"?>
-<?pyignition version = "1.000000"?>
-
-<effect>
- <source>
- <pos>(300, 500)</pos>
- <initspeed>2.000000</initspeed>
- <initdirection>0.000000</initdirection>
- <initspeedrandrange>1.000000</initspeedrandrange>
- <initdirectionrandrange>0.500000</initdirectionrandrange>
- <particlesperframe>10</particlesperframe>
- <particlelife>100</particlelife>
- <genspacing>0</genspacing>
- <drawtype>circle</drawtype>
- <colour>(255, 200, 100)</colour>
- <radius>3.000000</radius>
- <length>0.000000</length>
- <imagepath>None</imagepath>
- <keyframes>
- </keyframes>
- <particlekeyframes>
- <keyframe frame = "10">
- <colour_r>200</colour_r>
- <length>None</length>
- <interpolationtype>linear</interpolationtype>
- <radius>4.0</radius>
- <colour_b>20</colour_b>
- <colour_g>50</colour_g>
- </keyframe>
- <keyframe frame = "30">
- <colour_r>150</colour_r>
- <length>None</length>
- <interpolationtype>linear</interpolationtype>
- <radius>6.0</radius>
- <colour_b>0</colour_b>
- <colour_g>0</colour_g>
- </keyframe>
- <keyframe frame = "60">
- <colour_r>50</colour_r>
- <length>None</length>
- <interpolationtype>linear</interpolationtype>
- <radius>20.0</radius>
- <colour_b>20</colour_b>
- <colour_g>20</colour_g>
- </keyframe>
- <keyframe frame = "80">
- <colour_r>0</colour_r>
- <length>None</length>
- <interpolationtype>linear</interpolationtype>
- <radius>50.0</radius>
- <colour_b>0</colour_b>
- <colour_g>0</colour_g>
- </keyframe>
- </particlekeyframes>
- </source>
-
- <directedgravity>
- <strength>0.070000</strength>
- <strengthrandrange>0.000000</strengthrandrange>
- <direction>(0.000000, -1.000000)</direction>
- <keyframes>
- </keyframes>
- </directedgravity>
-
- <directedgravity>
- <strength>0.050000</strength>
- <strengthrandrange>0.000000</strengthrandrange>
- <direction>(1.000000, 0.000000)</direction>
- <keyframes>
- </keyframes>
- </directedgravity>
-
- <rectangle>
- <pos>(400, 100)</pos>
- <colour>(200, 100, 100)</colour>
- <bounce>0.200000</bounce>
- <width>100</width>
- <height>20</height>
- <keyframes>
- <keyframe frame = "500">
- <width>200</width>
- <pos_x>400</pos_x>
- <pos_y>250</pos_y>
- <bounce>None</bounce>
- <colour_b>None</colour_b>
- <interpolationtype>linear</interpolationtype>
- <colour_r>None</colour_r>
- <colour_g>None</colour_g>
- <height>30</height>
- </keyframe>
- </keyframes>
- </rectangle>
-
-</effect>-
\ No newline at end of file
diff --git a/Line counter.py b/Line counter.py
@@ -7,66 +7,66 @@ whitespace = 0
files = os.listdir(os.getcwd())
allowedextensions = ["py"]
excluded = ["Bubbles!.py", "Catherine wheel.py", "Controlled Eruption.py", "Gravity test.py",
- "Keyframe selector widget testery.py", "keyframes test.py", "particleeditor.py",
- "pygamedisplay.py", "PyIgnition test - fire.py", "Test load.py", "timelinectrl.py",
- "Vortex gravity test.py", "Water.py", "Wind.py", "wx test.py", "wx test 2.py",
- "xml OLD.py", "XML reader test.py"]
+ "Keyframe selector widget testery.py", "keyframes test.py", "particleeditor.py",
+ "pygamedisplay.py", "PyIgnition test - fire.py", "Test load.py", "timelinectrl.py",
+ "Vortex gravity test.py", "Water.py", "Wind.py", "wx test.py", "wx test 2.py",
+ "xml OLD.py", "XML reader test.py"]
-print " --ExeSoft line counter--"
+print (" --ExeSoft line counter--")
print
-print "Counting lines in all files with the following extensions:"
+print ("Counting lines in all files with the following extensions:")
for extension in allowedextensions:
- print "\t*.%s" % extension
+ print ("\t*.%s" % extension)
print
-print "Excluding the following files:"
+print ("Excluding the following files:")
for excludedfile in excluded:
- print "\t%s" % excludedfile
+ print ("\t%s" % excludedfile)
print
-print "Counting..."
+print ("Counting...")
for item in files:
- extension = item.split(".")[len(item.split(".")) - 1]
- if (extension in allowedextensions) and (item not in excluded) and (item != "Line counter.py"):
- opened = open(item)
- print "\tCounting in \'%s\'..." % item
+ extension = item.split(".")[len(item.split(".")) - 1]
+ if (extension in allowedextensions) and (item not in excluded) and (item != "Line counter.py"):
+ opened = open(item)
+ print ("\tCounting in \'%s\'..." % item)
- totalcount = 0
- totalextended = 0
- for line in opened.readlines():
- temp = line.replace("\t", "")
- temp = temp.replace(" ", "")
- temp = temp.replace("\n", "")
- if (temp != "") and (temp[0] != "#"):
- totalcount += 1
- totalextended += 1
- else:
- if temp == "":
- whitespace += 1
- elif temp[0] == "#":
- comments += 1
- totalextended += 1
+ totalcount = 0
+ totalextended = 0
+ for line in opened.readlines():
+ temp = line.replace("\t", "")
+ temp = temp.replace(" ", "")
+ temp = temp.replace("\n", "")
+ if (temp != "") and (temp[0] != "#"):
+ totalcount += 1
+ totalextended += 1
+ else:
+ if temp == "":
+ whitespace += 1
+ elif temp[0] == "#":
+ comments += 1
+ totalextended += 1
- lines += totalcount
- linesextended += totalextended
- opened.close()
+ lines += totalcount
+ linesextended += totalextended
+ opened.close()
print
-print "Done!"
-raw_input()
+print ("Done!")
+input()
print
print
-print "Line counts:\n\t-Excluding comments and whitespace: %i\n\t-Everything: %i" % (lines, linesextended)
-raw_input()
+print ("Line counts:\n\t-Excluding comments and whitespace: %i\n\t-Everything: %i" % (lines, linesextended))
+input()
print
-print "Extras:\n\t-Number of comments: %i\n\t-Number of blank lines: %i" % (comments, whitespace)
-raw_input()
+print ("Extras:\n\t-Number of comments: %i\n\t-Number of blank lines: %i" % (comments, whitespace))
+input()
print
codepercent = (float(lines) / float(linesextended)) * 100.0
commentpercent = (float(comments) / float(linesextended)) * 100.0
whitespacepercent = (float(whitespace) / float(linesextended)) * 100.0
-print "Code breakdown:"
-print "\t-Functional code: %f%%\n\t-Comments: %f%%\n\t-Whitespace: %f%%" % (codepercent, commentpercent, whitespacepercent)
-raw_input()
+print ("Code breakdown:")
+print ("\t-Functional code: %f%%\n\t-Comments: %f%%\n\t-Whitespace: %f%%" % (codepercent, commentpercent, whitespacepercent))
+input()
diff --git a/PyIgnition test.ppe b/PyIgnition test.ppe
@@ -1,129 +0,0 @@
-<?xml version = "1.0"?>
-<?pyignition version = "1.000000"?>
-
-<effect>
- <source>
- <pos>(10, 10)</pos>
- <initspeed>5.000000</initspeed>
- <initdirection>2.356194</initdirection>
- <initspeedrandrange>2.000000</initspeedrandrange>
- <initdirectionrandrange>1.000000</initdirectionrandrange>
- <particlesperframe>5</particlesperframe>
- <particlelife>125</particlelife>
- <genspacing>0</genspacing>
- <drawtype>scaleline</drawtype>
- <colour>(255, 255, 255)</colour>
- <radius>0.000000</radius>
- <length>10.000000</length>
- <imagepath>None</imagepath>
- <keyframes>
- </keyframes>
- <particlekeyframes>
- <keyframe frame = "50">
- <colour_r>0</colour_r>
- <length>10.0</length>
- <interpolationtype>linear</interpolationtype>
- <radius>None</radius>
- <colour_b>0</colour_b>
- <colour_g>255</colour_g>
- </keyframe>
- <keyframe frame = "75">
- <colour_r>255</colour_r>
- <length>10.0</length>
- <interpolationtype>linear</interpolationtype>
- <radius>None</radius>
- <colour_b>0</colour_b>
- <colour_g>255</colour_g>
- </keyframe>
- <keyframe frame = "100">
- <colour_r>0</colour_r>
- <length>10.0</length>
- <interpolationtype>linear</interpolationtype>
- <radius>None</radius>
- <colour_b>255</colour_b>
- <colour_g>255</colour_g>
- </keyframe>
- <keyframe frame = "125">
- <colour_r>0</colour_r>
- <length>10.0</length>
- <interpolationtype>linear</interpolationtype>
- <radius>None</radius>
- <colour_b>0</colour_b>
- <colour_g>0</colour_g>
- </keyframe>
- </particlekeyframes>
- </source>
-
- <pointgravity>
- <strength>1.000000</strength>
- <strengthrandrange>0.000000</strengthrandrange>
- <pos>(500, 380)</pos>
- <keyframes>
- <keyframe frame = "300">
- <interpolationtype>linear</interpolationtype>
- <pos_x>0</pos_x>
- <strength>10.0</strength>
- <strengthrandrange>None</strengthrandrange>
- <pos_y>0</pos_y>
- </keyframe>
- <keyframe frame = "450">
- <interpolationtype>linear</interpolationtype>
- <pos_x>40</pos_x>
- <strength>10.0</strength>
- <strengthrandrange>None</strengthrandrange>
- <pos_y>40</pos_y>
- </keyframe>
- <keyframe frame = "550">
- <interpolationtype>linear</interpolationtype>
- <pos_x>600</pos_x>
- <strength>-2.0</strength>
- <strengthrandrange>None</strengthrandrange>
- <pos_y>480</pos_y>
- </keyframe>
- <keyframe frame = "600">
- <interpolationtype>linear</interpolationtype>
- <pos_x>600</pos_x>
- <strength>-20.0</strength>
- <strengthrandrange>None</strengthrandrange>
- <pos_y>0</pos_y>
- </keyframe>
- <keyframe frame = "650">
- <interpolationtype>linear</interpolationtype>
- <pos_x>500</pos_x>
- <strength>1.0</strength>
- <strengthrandrange>None</strengthrandrange>
- <pos_y>380</pos_y>
- </keyframe>
- </keyframes>
- </pointgravity>
-
- <directedgravity>
- <strength>0.040000</strength>
- <strengthrandrange>0.000000</strengthrandrange>
- <direction>(1.000000, 0.000000)</direction>
- <keyframes>
- <keyframe frame = "300">
- <direction_y>1</direction_y>
- <direction_x>-0.5</direction_x>
- <interpolationtype>linear</interpolationtype>
- <strength>1.0</strength>
- <strengthrandrange>None</strengthrandrange>
- </keyframe>
- <keyframe frame = "600">
- <direction_y>-0.1</direction_y>
- <direction_x>1.0</direction_x>
- <interpolationtype>linear</interpolationtype>
- <strength>1.0</strength>
- <strengthrandrange>None</strengthrandrange>
- </keyframe>
- <keyframe frame = "650">
- <direction_y>0</direction_y>
- <direction_x>1</direction_x>
- <interpolationtype>linear</interpolationtype>
- <strength>0.04</strength>
- <strengthrandrange>None</strengthrandrange>
- </keyframe>
- </keyframes>
- </directedgravity>
-
-</effect>-
\ No newline at end of file
diff --git a/PyIgnition.pyc b/PyIgnition.pyc
Binary files differ.
diff --git a/Water.ppe b/Water.ppe
@@ -1,215 +0,0 @@
-<?xml version = "1.0"?>
-<?pyignition version = "1.000000"?>
-
-<effect>
- <source>
- <pos>(0, 0)</pos>
- <initspeed>2.000000</initspeed>
- <initdirection>3.141593</initdirection>
- <initspeedrandrange>1.000000</initspeedrandrange>
- <initdirectionrandrange>3.141593</initdirectionrandrange>
- <particlesperframe>20</particlesperframe>
- <particlelife>80</particlelife>
- <genspacing>0</genspacing>
- <drawtype>circle</drawtype>
- <colour>(100, 100, 250)</colour>
- <radius>10.000000</radius>
- <length>0.000000</length>
- <imagepath>None</imagepath>
- <keyframes>
- </keyframes>
- <particlekeyframes>
- <keyframe frame = "60">
- <colour_r>100</colour_r>
- <length>None</length>
- <interpolationtype>linear</interpolationtype>
- <radius>10.0</radius>
- <colour_b>250</colour_b>
- <colour_g>100</colour_g>
- </keyframe>
- <keyframe frame = "80">
- <colour_r>255</colour_r>
- <length>None</length>
- <interpolationtype>linear</interpolationtype>
- <radius>20.0</radius>
- <colour_b>255</colour_b>
- <colour_g>255</colour_g>
- </keyframe>
- </particlekeyframes>
- </source>
-
- <directedgravity>
- <strength>0.200000</strength>
- <strengthrandrange>0.000000</strengthrandrange>
- <direction>(0.000000, 1.000000)</direction>
- <keyframes>
- </keyframes>
- </directedgravity>
-
- <circle>
- <pos>(100, 200)</pos>
- <colour>(0, 0, 0)</colour>
- <bounce>0.100000</bounce>
- <radius>50.000000</radius>
- <keyframes>
- </keyframes>
- </circle>
-
- <circle>
- <pos>(400, 100)</pos>
- <colour>(0, 0, 0)</colour>
- <bounce>0.100000</bounce>
- <radius>50.000000</radius>
- <keyframes>
- <keyframe frame = "250">
- <pos_x>400</pos_x>
- <pos_y>500</pos_y>
- <radius>None</radius>
- <bounce>None</bounce>
- <colour_b>None</colour_b>
- <interpolationtype>cosine</interpolationtype>
- <colour_r>None</colour_r>
- <colour_g>None</colour_g>
- </keyframe>
- <keyframe frame = "300">
- <pos_x>None</pos_x>
- <pos_y>None</pos_y>
- <radius>None</radius>
- <bounce>None</bounce>
- <colour_b>50</colour_b>
- <interpolationtype>linear</interpolationtype>
- <colour_r>0</colour_r>
- <colour_g>255</colour_g>
- </keyframe>
- </keyframes>
- </circle>
-
- <circle>
- <pos>(300, 300)</pos>
- <colour>(0, 0, 0)</colour>
- <bounce>0.100000</bounce>
- <radius>50.000000</radius>
- <keyframes>
- </keyframes>
- </circle>
-
- <circle>
- <pos>(500, 250)</pos>
- <colour>(0, 0, 0)</colour>
- <bounce>0.100000</bounce>
- <radius>50.000000</radius>
- <keyframes>
- <keyframe frame = "200">
- <pos_x>500</pos_x>
- <pos_y>250</pos_y>
- <radius>None</radius>
- <bounce>None</bounce>
- <colour_b>None</colour_b>
- <interpolationtype>linear</interpolationtype>
- <colour_r>None</colour_r>
- <colour_g>None</colour_g>
- </keyframe>
- <keyframe frame = "230">
- <pos_x>100</pos_x>
- <pos_y>300</pos_y>
- <radius>None</radius>
- <bounce>None</bounce>
- <colour_b>None</colour_b>
- <interpolationtype>cosine</interpolationtype>
- <colour_r>None</colour_r>
- <colour_g>None</colour_g>
- </keyframe>
- </keyframes>
- </circle>
-
- <circle>
- <pos>(150, 400)</pos>
- <colour>(0, 0, 0)</colour>
- <bounce>0.100000</bounce>
- <radius>50.000000</radius>
- <keyframes>
- </keyframes>
- </circle>
-
- <rectangle>
- <pos>(500, 450)</pos>
- <colour>(100, 200, 200)</colour>
- <bounce>0.200000</bounce>
- <width>250</width>
- <height>100</height>
- <keyframes>
- <keyframe frame = "200">
- <width>400.0</width>
- <pos_x>400</pos_x>
- <pos_y>100</pos_y>
- <bounce>None</bounce>
- <colour_b>None</colour_b>
- <interpolationtype>cosine</interpolationtype>
- <colour_r>None</colour_r>
- <colour_g>None</colour_g>
- <height>None</height>
- </keyframe>
- <keyframe frame = "300">
- <width>None</width>
- <pos_x>None</pos_x>
- <pos_y>None</pos_y>
- <bounce>None</bounce>
- <colour_b>0</colour_b>
- <interpolationtype>linear</interpolationtype>
- <colour_r>255</colour_r>
- <colour_g>0</colour_g>
- <height>None</height>
- </keyframe>
- </keyframes>
- </rectangle>
-
- <boundaryline>
- <pos>(700, 500)</pos>
- <colour>(0, 0, 0)</colour>
- <bounce>0.100000</bounce>
- <normal>(-0.707107, -0.707107)</normal>
- <keyframes>
- <keyframe frame = "300">
- <pos_x>None</pos_x>
- <pos_y>None</pos_y>
- <normal_x>-0.894427191</normal_x>
- <bounce>None</bounce>
- <colour_b>None</colour_b>
- <interpolationtype>linear</interpolationtype>
- <colour_r>None</colour_r>
- <colour_g>None</colour_g>
- <normal_y>-0.4472135955</normal_y>
- </keyframe>
- <keyframe frame = "500">
- <pos_x>None</pos_x>
- <pos_y>None</pos_y>
- <normal_x>-1</normal_x>
- <bounce>None</bounce>
- <colour_b>None</colour_b>
- <interpolationtype>linear</interpolationtype>
- <colour_r>None</colour_r>
- <colour_g>None</colour_g>
- <normal_y>0</normal_y>
- </keyframe>
- </keyframes>
- </boundaryline>
-
- <boundaryline>
- <pos>(0, 600)</pos>
- <colour>(0, 0, 0)</colour>
- <bounce>0.100000</bounce>
- <normal>(0.000000, -1.000000)</normal>
- <keyframes>
- </keyframes>
- </boundaryline>
-
- <boundaryline>
- <pos>(0, 600)</pos>
- <colour>(0, 0, 0)</colour>
- <bounce>0.100000</bounce>
- <normal>(1.000000, 0.000000)</normal>
- <keyframes>
- </keyframes>
- </boundaryline>
-
-</effect>-
\ No newline at end of file
diff --git a/constants.pyc b/constants.pyc
Binary files differ.
diff --git a/gravity.py b/gravity.py
@@ -15,7 +15,7 @@ def RandomiseStrength(base, range):
class DirectedGravity:
def __init__(self, strength = 0.0, strengthrandrange = 0.0, direction = [0, 1]):
- self.selected = False
+ self.selected = False
self.type = "directed"
self.initstrength = strength
self.strength = strength
@@ -64,7 +64,7 @@ class DirectedGravity:
class PointGravity:
def __init__(self, strength = 0.0, strengthrandrange = 0.0, pos = (0, 0)):
- self.selected = False
+ self.selected = False
self.type = "point"
self.initstrength = strength
self.strength = strength
@@ -150,8 +150,8 @@ class VortexGravity(PointGravity):
try:
self.alreadyshownerror
except:
- print "WARNING: VortexGravity relies upon particle velocities as well as positions, and so its \
- force can only be obtained using GetForceOnParticle([PyIgnition particle object]).".replace("\t", "")
+ print ("WARNING: VortexGravity relies upon particle velocities as well as positions, and so its \
+ force can only be obtained using GetForceOnParticle([PyIgnition particle object]).".replace("\t", ""))
self.alreadyshownerror = True
return [0.0, 0.0]
diff --git a/gravity.pyc b/gravity.pyc
Binary files differ.
diff --git a/interpolate.py b/interpolate.py
@@ -47,14 +47,14 @@ def InterpolateKeyframes(curframe, variables, keyframes):
if not ('interpolationtype' in variables):
variables['interpolationtype'] = INTERPOLATIONTYPE_LINEAR
- keys = variables.keys()
+ keys = list(variables.keys())
- for i in xrange(len(keys)): # Determine current keyframe and next one for this variable
+ for i in range(len(keys)): # Determine current keyframe and next one for this variable
key = keys[i]
curkeyframe = None
nextkeyframe = None
- for i in xrange(len(keyframes)):
+ for i in range(len(keyframes)):
try:
frame = keyframes[i]
if (frame.variables[key] != None): # If the current keyframe has a keyed value for the current variable
@@ -74,4 +74,4 @@ def InterpolateKeyframes(curframe, variables, keyframes):
elif keyframes[nextkeyframe].variables['interpolationtype'] == INTERPOLATIONTYPE_COSINE:
finalvariables[key] = CosineInterpolateKeyframes(curframe, keyframes[curkeyframe].frame, keyframes[nextkeyframe].frame, keyframes[curkeyframe].variables[key], keyframes[nextkeyframe].variables[key])
- return finalvariables-
\ No newline at end of file
+ return finalvariables
diff --git a/interpolate.pyc b/interpolate.pyc
Binary files differ.
diff --git a/keyframes test.py b/keyframes test.py
@@ -1,6 +1,6 @@
## Keyframing test
-import keyframes, interpolate, pygame
+import keyframes, interpolate, pygame, sys
screen = pygame.display.set_mode((800, 600))
@@ -30,7 +30,9 @@ class Circle:
self.curframe = self.curframe + 1
def Draw(self):
- pygame.draw.circle(self.screen, (self.variables["r"], self.variables["g"], self.variables["b"]), (self.variables["x"], self.variables["y"]), self.variables["rad"])
+ pygame.draw.circle(self.screen,
+ (int(self.variables["r"]), int(self.variables["g"]), int(self.variables["b"])),
+ (int(self.variables["x"]), int(self.variables["y"])), int(self.variables["rad"]))
circle = Circle((0, 0), (0, 255, 0), 10, screen)
@@ -45,4 +47,4 @@ while True:
circle.Draw()
pygame.display.update()
- clock.tick(30)-
\ No newline at end of file
+ clock.tick(30)
diff --git a/keyframes.py b/keyframes.py
@@ -12,7 +12,7 @@ def CreateKeyframe(parentframes, frame, variables):
# Look for duplicate keyframes and copy other defined variables
try:
- oldkey = (keyframe for keyframe in parentframes if keyframe.frame == frame).next()
+ oldkey = (keyframe for keyframe in parentframes if keyframe.frame == frame).__next__()
except StopIteration:
oldkey = None
@@ -55,4 +55,4 @@ class Keyframe:
if not ('interpolationtype' in self.variables):
self.variables['interpolationtype'] = INTERPOLATIONTYPE_LINEAR
- -
\ No newline at end of file
+
diff --git a/keyframes.pyc b/keyframes.pyc
Binary files differ.
diff --git a/obstacles.py b/obstacles.py
@@ -35,7 +35,7 @@ def normalise(vec):
class Obstacle:
def __init__(self, parenteffect, pos, colour, bounce):
- self.selected = False
+ self.selected = False
self.parenteffect = parenteffect
self.pos = pos
self.colour = colour
diff --git a/obstacles.pyc b/obstacles.pyc
Binary files differ.
diff --git a/particles.py b/particles.py
@@ -86,7 +86,7 @@ class Particle:
elif self.drawtype == DRAWTYPE_IMAGE: # Image
if self.image != None:
size = self.image.get_size()
- display.blit(self.image, (offset[0] + int(self.pos[0] - (size[1]* 0.5)), offset[1] + int(self.pos[1] - (size[1] * 0.5))))
+ display.blit(self.image, (offset[0] + int(self.pos[0] - (size[1]* 0.5)), offset[1] + int(self.pos[1] - (size[1] * 0.5))))
def CreateKeyframe(self, frame, colour = (None, None, None), radius = None, length = None):
keyframes.CreateKeyframe(self.keyframes, frame, {'colour_r':colour[0], 'colour_g':colour[1], 'colour_b':colour[2], 'radius':radius, 'length':length})
@@ -94,7 +94,7 @@ class Particle:
class ParticleSource:
def __init__(self, parenteffect, pos, initspeed, initdirection, initspeedrandrange, initdirectionrandrange, particlesperframe, particlelife, genspacing, drawtype = 0, colour = (0, 0, 0), radius = 0.0, length = 0.0, imagepath = None):
- self.selected = False
+ self.selected = False
self.parenteffect = parenteffect
self.pos = pos
self.initspeed = initspeed
@@ -173,7 +173,7 @@ class ParticleSource:
else: # Otherwise, interpolate the particle variables for each frame of its life
particlelife = self.particlelife
- for i in xrange(0, particlelife + 1):
+ for i in range(0, particlelife + 1):
vars = interpolate.InterpolateKeyframes(i, {'colour_r':0, 'colour_g':0, 'colour_b':0, 'radius':0, 'length':0}, self.particlekeyframes)
self.particlecache.append(vars)
diff --git a/particles.pyc b/particles.pyc
Binary files differ.
diff --git a/pygamedisplay.pyc b/pygamedisplay.pyc
Binary files differ.
diff --git a/timelinectrl.pyc b/timelinectrl.pyc
Binary files differ.
diff --git a/xml.pyc b/xml.pyc
Binary files differ.