Compare commits
7 Commits
Author | SHA1 | Date |
---|---|---|
Gouvernathor | 1f8e939cf9 | |
Gouvernathor | caa4cd0b2c | |
Gouvernathor | cd63abd27b | |
Gouvernathor | c0bc1cd69f | |
Gouvernathor | 00eda2aae5 | |
Gouvernathor | ae5ff121d9 | |
Gouvernathor | 2525bea67d |
|
@ -91,6 +91,8 @@ python early hide:
|
|||
chibi = eval(f"{who}_chibi")
|
||||
except Exception:
|
||||
renpy.error(f"Character chibi not defined: {who}")
|
||||
if not hasattr(chibi, action):
|
||||
renpy.error(f"Chibi action not defined: {who} {action}")
|
||||
|
||||
def predict(self):
|
||||
who, action = self
|
||||
|
@ -142,6 +144,23 @@ python early hide:
|
|||
|
||||
return {"blocks": blocks}
|
||||
|
||||
def lint(self):
|
||||
any_true = False
|
||||
for block, weight, condition in self["blocks"]:
|
||||
if not isinstance(weight, (int, float)):
|
||||
renpy.error(f"Weight must be a number, not {weight!r}")
|
||||
|
||||
if condition == "True":
|
||||
any_true = True
|
||||
else:
|
||||
try:
|
||||
eval(condition)
|
||||
except Exception:
|
||||
renpy.error(f"Condition could not be evaluated: {condition!r}")
|
||||
|
||||
if not any_true:
|
||||
renpy.error("All blocks have a condition, which will raise an exception if all conditions are False at the same time at runtime")
|
||||
|
||||
def next(self):
|
||||
blocks = [(block, weight) for block, weight, condition in self["blocks"] if eval(condition)]
|
||||
total_weight = sum(weight for _, weight in blocks)
|
|
@ -61,8 +61,10 @@ transform blink_repeat:
|
|||
repeat
|
||||
|
||||
transform bob(t=1):
|
||||
on show, appear, start:
|
||||
yoffset absolute(0)
|
||||
animation
|
||||
subpixel True
|
||||
yoffset absolute(0)
|
||||
block:
|
||||
ease t yoffset absolute(10)
|
||||
ease t yoffset absolute(0)
|
||||
repeat
|
||||
|
@ -155,4 +157,3 @@ init python:
|
|||
trans.xoffset = renpy.random.randint(-2, 2)
|
||||
trans.yoffset = renpy.random.randint(-2, 2)
|
||||
return clamp(1.0 - st, 0.05, 1.0)
|
||||
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
transform sprite_fly_idle:
|
||||
on show, appear, start:
|
||||
yoffset absolute(110)
|
||||
animation
|
||||
subpixel True
|
||||
yoffset absolute(110)
|
||||
block:
|
||||
ease_back 2.5 yoffset absolute(90)
|
||||
ease_back 2.5 yoffset absolute(110)
|
||||
repeat
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,2 +1 @@
|
|||
|
||||
define ALLOWED_CHARACTERS = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz "
|
||||
|
|
|
@ -173,8 +173,9 @@ screen achievement_window(msg="", title="", icon=None, xpos=0, ypos=60):
|
|||
timer 6.0 action Hide("achievement_window")
|
||||
|
||||
transform rotate_circular(t=7):
|
||||
on show, appear, start:
|
||||
subpixel True
|
||||
animation
|
||||
subpixel True
|
||||
block:
|
||||
rotate 0
|
||||
linear t rotate 360
|
||||
repeat
|
||||
|
|
Loading…
Reference in New Issue