Compare commits

..

4 Commits

Author SHA1 Message Date
218d8c63d2 Fix 2024-03-30 17:53:00 +01:00
1d1d18ad1c Remove the last setattr on the store
benign in this case since the variable is builtin, but consistency and good practices
2024-03-30 17:33:28 +01:00
31ebf9356a Avoid mutable objects in signature 2024-03-30 17:18:54 +01:00
f7f0ecb566 Default queues instead of using instanciation magic 2024-03-30 17:17:14 +01:00
63 changed files with 565 additions and 752 deletions

120
README.md

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -82,12 +82,12 @@ init python:
child = getattr(self, layer) child = getattr(self, layer)
if isinstance(child, ImageReference): if isinstance(child, ImageReference):
name = getattr(self, f"_{layer}") name = getattr(self, "_{}".format(layer))
attributes = renpy.get_attributes(name) or renpy.get_attributes(f"{tag_prefix}_{layer}") attributes = renpy.get_attributes(name) or renpy.get_attributes("{}_{}".format(tag_prefix, layer))
if attributes: if attributes:
attributes = " ".join(attributes) attributes = " ".join(attributes)
child = ImageReference(f"{name} {attributes}") child = ImageReference("{} {}".format(name, attributes))
elif child.name != name: elif child.name != name:
child = ImageReference(name) child = ImageReference(name)
else: else:

View File

@ -24,7 +24,7 @@ init python:
states.gen.image.offset = (0, 600) states.gen.image.offset = (0, 600)
if face: if face:
variant = f"genie {face}" variant = "genie {}".format(face)
renpy.set_tag_attributes(variant) renpy.set_tag_attributes(variant)
side = "genie" side = "genie"

View File

@ -140,9 +140,9 @@ init python:
elif chibi.action in ("drink_potion", "sniff_potion", "hold_potion"): elif chibi.action in ("drink_potion", "sniff_potion", "hold_potion"):
if not hermione.is_any_worn("top", "bottom"): if not hermione.is_any_worn("top", "bottom"):
chibi["base"] = f"ch_hem {chibi.action}_nude" chibi["base"] = "ch_hem {}_nude".format(chibi.action)
else: else:
chibi["base"] = f"ch_hem {chibi.action}" chibi["base"] = "ch_hem {}".format(chibi.action)
# Sets up a chibi scene with Hermione and Genie in it # Sets up a chibi scene with Hermione and Genie in it

View File

@ -534,6 +534,6 @@ label hermione_chitchat:
block if states.her.ev.potions.breast_expand_drank: block if states.her.ev.potions.breast_expand_drank:
her "You don't happen to have any more of that breast expansion potion, [name_genie_hermione]?" ("open", "base", "base", "mid") her "You don't happen to have any more of that breast expansion potion, [name_genie_hermione]?" ("open", "base", "base", "mid")
her "I've noticed some correlations between grades and the student's chest size, so I thought I'd give it a shot during our next exam..." ("open", "base", "base", "mid") her "I've noticed some correlations between your grades and your chest size, so I thought I'd give it a shot during our next exam..." ("open", "base", "base", "mid")
return return

View File

@ -1168,7 +1168,7 @@ label ll_pf_masturbate_T4_E1_repeat:
lun "I never realised that the tests at Hogwarts just happened to have acronyms, that's fascinating!" ("grin", "base", "base", "mid") lun "I never realised that the tests at Hogwarts just happened to have acronyms, that's fascinating!" ("grin", "base", "base", "mid")
gen "Yep... I'm sure some writer didn't spend hours coming up with those." gen "Yep... I'm sure some writer didn't spend hours coming up with those."
lun "*Huh*?" ("soft", "base", "raised", "mid") lun "*Huh*?" ("soft", "base", "raised", "mid")
gen "Anyway...{w=0.4} Now that that's established, you may begin the test.{#LINT_IGNORE}" gen "Anyway...{w=0.4} Now that that's established, you may begin the test."
lun "Oh, alright!" ("base", "base", "base", "mid") lun "Oh, alright!" ("base", "base", "base", "mid")
gen "Why don't you start off with the thought process behind the removal of your top." gen "Why don't you start off with the thought process behind the removal of your top."
lun "Oh! Oh! I know that!" ("smile", "base", "base", "stare") lun "Oh! Oh! I know that!" ("smile", "base", "base", "stare")

View File

@ -1609,7 +1609,7 @@ label ll_pf_blowjob_T4_E4_repeat:
show screen blkfade show screen blkfade
with d5 with d5
nar "As Luna crawls out from under your desk, you slump back into your chair, exhausted by the sheer intensity of the session." nar "As Luna crawls out from under your desk, you slump back into your chair, exhausted by the cheer intensity of the session."
hide cg hide cg
hide screen blkfade hide screen blkfade

View File

@ -95,7 +95,6 @@ label update_lun_tier:
# T5 NOT AVAILABLE # T5 NOT AVAILABLE
return return
# unreachable
# Requirement: Tier 4 - Blow me T4 E3 # Requirement: Tier 4 - Blow me T4 E3
$ lun_level_up = 4 $ lun_level_up = 4
return return

View File

@ -206,7 +206,7 @@ default ton_outfit_mechanic = DollOutfit([ton_hair_mechanic, ton_top_vest_mechan
default ton_robe_office = DollCloth("tonks", ("upper body", "robes"), "robe", "office",["#353843ff", "#fff24aff"]) default ton_robe_office = DollCloth("tonks", ("upper body", "robes"), "robe", "office",["#353843ff", "#fff24aff"])
default ton_top_office = DollCloth("tonks", ("upper body", "shirts"), "top", "office", ["#e7e7e7ff", "#d1cebbff"]) default ton_top_office = DollCloth("tonks", ("upper body", "shirts"), "top", "office", ["#e7e7e7ff", "#d1cebbff"])
default ton_bottoms_office = DollCloth("tonks", ("lower body", "trousers"), "bottom", "office",["#353843ff"]) default ton_bottoms_office = DollCloth("tonks", ("lower body", "trousers"), "bottom", "office",["#353843ff"])
default ton_accessory_office = DollCloth("tonks", ("misc", "accessory"), "accessory", "office_pin", ["#e7e7e7ff", "#fff24aff", "#d8422cff"], zorder=235) default ton_accessory_office = DollCloth("tonks", ("misc", "accessory"), "accessory", "office_pin", ["#e7e7e7ff", "#fff24aff", "#d8422cff"], zorder=225)
default ton_outfit_office = DollOutfit([ton_hair_base, ton_robe_office, ton_top_office, ton_bottoms_office, ton_accessory_office], price=450, name="SECS Outfit", desc="A smart suit for a clever girl.") default ton_outfit_office = DollOutfit([ton_hair_base, ton_robe_office, ton_top_office, ton_bottoms_office, ton_accessory_office], price=450, name="SECS Outfit", desc="A smart suit for a clever girl.")

View File

@ -14,7 +14,7 @@ screen chibi(chibi_object):
screen chibi_emote(emote, chibi_object): screen chibi_emote(emote, chibi_object):
zorder chibi_object.zorder zorder chibi_object.zorder
sensitive False sensitive False
add f"emo_{emote}": add "emo_{}".format(emote):
at emote_effect at emote_effect
anchor (0.5, 1.0) anchor (0.5, 1.0)
pos chibi_object.pos pos chibi_object.pos
@ -45,12 +45,12 @@ init -1 python:
def get_chibi_object(name): def get_chibi_object(name):
"""Get a chibi object by its character's name.""" """Get a chibi object by its character's name."""
name = f"{name}_chibi" name = "{}_chibi".format(name)
c = getattr(renpy.store, name, None) c = getattr(renpy.store, name, None)
if c and isinstance(c, Chibi): if c and isinstance(c, Chibi):
return c return c
else: else:
raise Exception(f"Chibi object not found. {name}") raise Exception("Chibi object not found. {}".format(name))
def complete_chibi_moves(**elapsed): def complete_chibi_moves(**elapsed):
"""Resume old chibi action after (multiple) reduced move calls.""" """Resume old chibi action after (multiple) reduced move calls."""
@ -120,7 +120,7 @@ init -1 python:
if image_path: if image_path:
self.image_path = image_path self.image_path = image_path
else: else:
self.image_path = f"characters/{tag}/chibis" self.image_path = "characters/{}/chibis".format(tag)
if actions: if actions:
# Override class variable for this instance # Override class variable for this instance
@ -138,11 +138,11 @@ init -1 python:
self.transform = None self.transform = None
# Define a screen for the chibi # Define a screen for the chibi
self.screen_tag = f"{tag}_chibi" self.screen_tag = "{}_chibi".format(tag)
renpy.define_screen(self.screen_tag, Chibi._screen, tag=self.screen_tag, zorder="chibi_object.zorder") renpy.define_screen(self.screen_tag, Chibi._screen, tag=self.screen_tag, zorder="chibi_object.zorder")
# Define a screen for the chibi emote # Define a screen for the chibi emote
self.emote_tag = f"{tag}_chibi_emote" self.emote_tag = "{}_chibi_emote".format(tag)
renpy.define_screen(self.emote_tag, Chibi._emote_screen, tag=self.emote_tag, zorder="chibi_object.zorder") renpy.define_screen(self.emote_tag, Chibi._emote_screen, tag=self.emote_tag, zorder="chibi_object.zorder")
@staticmethod @staticmethod
@ -282,7 +282,7 @@ init -1 python:
# Combine with base transform # Combine with base transform
return combine_transforms(self.base_transform(), trans(*args)) return combine_transforms(self.base_transform(), trans(*args))
elif config.developer: elif config.developer:
raise Exception(f"Expected an ATL transform: {name}") raise Exception("Expected a transform: {}".format(name))
# No transform was given or found # No transform was given or found
return self.base_transform() return self.base_transform()
@ -358,7 +358,7 @@ init -1 python:
room = room or renpy.store.states.room room = room or renpy.store.states.room
chibi_room = ChibiRoom.rooms.get(room, None) chibi_room = ChibiRoom.rooms.get(room, None)
if not chibi_room: if not chibi_room:
raise Exception(f"Chibi room is not defined for {room}") raise Exception("Chibi room is not defined for {}".format(room))
return chibi_room return chibi_room
@staticmethod @staticmethod

View File

@ -37,7 +37,7 @@ init 1 python:
ltype, *tails = fn.rsplit("_") ltype, *tails = fn.rsplit("_")
# if not ltype in types: # if not ltype in types:
# print(f"Invalid layer type for file: {f}") # print("Invalid layer type for file: {}".format(f))
# continue # continue
zorder = types.get(ltype) or self.zorder zorder = types.get(ltype) or self.zorder
@ -50,7 +50,7 @@ init 1 python:
lmodifier, *tails = tails lmodifier, *tails = tails
if not lmodifier in modifiers: if not lmodifier in modifiers:
print(f"Invalid modifier for file: {f}") print("Invalid modifier for file: {}".format(f))
continue continue
zorder_mod = modifiers.get(lmodifier) zorder_mod = modifiers.get(lmodifier)

View File

@ -211,9 +211,11 @@ init 5 python:
self.set_pose(pose or self.walk) self.set_pose(pose or self.walk)
# Note: Warper names and their count can change over time,
# so it's easier to just evaluate the input.
# List of available warpers: # List of available warpers:
# https://www.renpy.org/doc/html/atl.html?#warpers # https://www.renpy.org/doc/html/atl.html?#warpers
warper = getattr(_warper, warper, _warper.linear) warper = eval(f"_warper.{warper}")
distances = [] distances = []
times = [] times = []

View File

@ -108,7 +108,7 @@ init python:
ltype, *tails = fn.rsplit("_") ltype, *tails = fn.rsplit("_")
if not ltype.isdigit() and not ltype in types: if not ltype.isdigit() and not ltype in types:
print(f"Invalid layer type for file: {f}") print("Invalid layer type for file: {}".format(f))
continue continue
zorder = z if (z := types.get(ltype)) is not None else self.zorder zorder = z if (z := types.get(ltype)) is not None else self.zorder
@ -121,7 +121,7 @@ init python:
lmodifier, *tails = tails lmodifier, *tails = tails
if not lmodifier in modifiers: if not lmodifier in modifiers:
print(f"Invalid modifier for file: {f}") print("Invalid modifier for file: {}".format(f))
continue continue
zorder_mod = modifiers.get(lmodifier) zorder_mod = modifiers.get(lmodifier)

View File

@ -131,7 +131,7 @@ init python:
lmodifier, *tails = tails lmodifier, *tails = tails
if not lmodifier in modifiers: if not lmodifier in modifiers:
print(f"Invalid modifier for file: {f}") print("Invalid modifier for file: {}".format(f))
continue continue
zorder_mod = modifiers.get(lmodifier) zorder_mod = modifiers.get(lmodifier)

View File

@ -54,7 +54,7 @@ init python:
ltype, *tails = fn.rsplit("_") ltype, *tails = fn.rsplit("_")
if not ltype in types: if not ltype in types:
print(f"Invalid layer type for file: {f}") print("Invalid layer type for file: {}".format(f))
continue continue
zorder = types.get(ltype) or face_layers.get(part) zorder = types.get(ltype) or face_layers.get(part)
@ -63,7 +63,7 @@ init python:
lmodifier, *tails = tails lmodifier, *tails = tails
if not lmodifier in modifiers: if not lmodifier in modifiers:
print(f"Invalid modifier for file: {f}") print("Invalid modifier for file: {}".format(f))
continue continue
zorder_mod = modifiers.get(lmodifier) zorder_mod = modifiers.get(lmodifier)

View File

@ -5,13 +5,13 @@ init python:
for c in states.dolls: for c in states.dolls:
char = get_character_object(c) char = get_character_object(c)
body_default = get_character_body(c, typ="default") body_default = get_character_body(c, type="default")
char.equip(body_default) char.equip(body_default)
outfit_default = get_character_outfit(c, typ="default") outfit_default = get_character_outfit(c, type="default")
char.equip(outfit_default) char.equip(outfit_default)
outfit_last = outfit = get_character_outfit(c, typ="last") outfit_last = outfit = get_character_outfit(c, type="last")
outfit_last.save() outfit_last.save()
char.set_face(mouth="base", eyes="base", eyebrows="base", pupils="mid", cheeks="none", tears="none") char.set_face(mouth="base", eyes="base", eyebrows="base", pupils="mid", cheeks="none", tears="none")

View File

@ -538,7 +538,7 @@ init python:
# Grab data # Grab data
if fromfile: if fromfile:
try: try:
imported = image_payload.extract(path) imported = ImagePayload().extract(path)
except Exception as e: except Exception as e:
renpy.notify("Import failed: Corrupted file.") renpy.notify("Import failed: Corrupted file.")
print(e) print(e)

View File

@ -49,7 +49,7 @@ init python:
lmodifier, *tails = tails lmodifier, *tails = tails
if not lmodifier in modifiers: if not lmodifier in modifiers:
print(f"Invalid modifier for file: {f}") print("Invalid modifier for file: {}".format(f))
continue continue
zorder_mod = modifiers.get(lmodifier) zorder_mod = modifiers.get(lmodifier)

View File

@ -218,11 +218,11 @@ init python:
d, d,
"interface/wardrobe/export_frame.webp", "interface/wardrobe/export_frame.webp",
Text(states.active_girl, align=(0.5, 0.995)), Text(states.active_girl, align=(0.5, 0.995)),
Text(f"Ver. {config.version}", size=10, align=(0.99, 0.99)) Text("Ver. {}".format(config.version), size=10, align=(0.99, 0.99))
) )
displayable_to_file(d, path, size=(310, 470) ) displayable_to_file(d, path, size=(310, 470) )
image_payload.inject("_temp.png", filename, str(exported)) ImagePayload().inject("_temp.png", filename, str(exported))
os.remove(path) os.remove(path)
else: else:
set_clipboard(exported) set_clipboard(exported)
@ -286,3 +286,4 @@ init python:
if self.has_type(arg): if self.has_type(arg):
return True return True
return False return False

Some files were not shown because too many files have changed in this diff Show More