[hotfix] disable trap for photosensitive creatures
This commit is contained in:
parent
a290dccb67
commit
92adc6ea9b
16
animation.py
16
animation.py
|
@ -48,9 +48,9 @@ class RandomSingle(Animation):
|
|||
by Max & Lightmoll (https://lght.ml)
|
||||
from 2022-06-08
|
||||
"""
|
||||
def __init__(self, color):
|
||||
def __init__(self, color, looptime=60):
|
||||
super().__init__()
|
||||
self.PERIOD = 4 * 30 #frames
|
||||
self.PERIOD = looptime * 30 #frames
|
||||
self.color = self._rand_color()
|
||||
self.last_colors = []
|
||||
self.frame_counter = 0
|
||||
|
@ -92,10 +92,10 @@ class TwoColor(Steady):
|
|||
by Max & Lightmoll (https://lght.ml)
|
||||
from 2022-06-08
|
||||
"""
|
||||
def __init__(self, color):
|
||||
def __init__(self, color, looptime=60):
|
||||
super().__init__(color)
|
||||
self.start_time = time()
|
||||
self.PERIOD = 0.5 #s
|
||||
self.PERIOD = looptime * 0.5 #s
|
||||
self.COL_1 = color #input color
|
||||
|
||||
self.COL_2 = (255-self.r, 255-self.g, 255-self.b) #compl. color
|
||||
|
@ -174,7 +174,7 @@ class Caramelldansen(Steady):
|
|||
|
||||
|
||||
class FadeTo(Steady):
|
||||
def __init__(self, color, t=2.0):
|
||||
def __init__(self, color, t=60.0):
|
||||
super(FadeTo, self).__init__(color)
|
||||
self.t = t
|
||||
self.start = time()
|
||||
|
@ -192,7 +192,7 @@ class FadeTo(Steady):
|
|||
|
||||
|
||||
class RotatingRainbow(Animation):
|
||||
def __init__(self, looptime=10.0):
|
||||
def __init__(self, looptime=60.0):
|
||||
super(RotatingRainbow, self).__init__()
|
||||
self.looptime = looptime
|
||||
pass
|
||||
|
@ -216,7 +216,7 @@ class RotatingRainbow(Animation):
|
|||
|
||||
|
||||
class Chase(Steady):
|
||||
def __init__(self, color, looptime=1.0):
|
||||
def __init__(self, color, looptime=60.0):
|
||||
super(Chase, self).__init__(color)
|
||||
self.looptime = looptime
|
||||
|
||||
|
@ -234,7 +234,7 @@ class Chase(Steady):
|
|||
|
||||
|
||||
class ChaseRandom(Animation):
|
||||
def __init__(self, color, looptime=1.0):
|
||||
def __init__(self, color, looptime=60.0):
|
||||
super(Chase, self).__init__(color)
|
||||
self.looptime = looptime
|
||||
|
||||
|
|
Loading…
Reference in a new issue