Compare commits

...

10 Commits
main ... gouv-5

19 changed files with 107 additions and 95 deletions

View File

@ -1,5 +1,14 @@
python early hide: python early hide:
import inspect import inspect
try:
from renpy.lint import python_builtins, renpy_builtins
except ImportError:
import builtins
python_builtins = set(dir(builtins))
del builtins
renpy_builtins = set()
__register_params = frozenset(inspect.signature(renpy.register_statement).parameters).difference({"name", "parse"}) __register_params = frozenset(inspect.signature(renpy.register_statement).parameters).difference({"name", "parse"})
def register_decorator(cls): def register_decorator(cls):
""" """
@ -54,6 +63,12 @@ python early hide:
evaled = {n: eval(e) for n, e in self.items()} evaled = {n: eval(e) for n, e in self.items()}
renpy.dynamic(**evaled) renpy.dynamic(**evaled)
def lint(self):
for domain, st in (("Python", python_builtins), ("Ren'Py", renpy_builtins)):
inter = st.intersection(self)
if inter:
renpy.error(f"Dynamic statement redefines one or several {domain} builtins: {', '.join(map(repr, inter))}")
@register_decorator @register_decorator
class chibi: class chibi:
@staticmethod @staticmethod

View File

@ -18,7 +18,7 @@ init python:
renpy.show_screen(controller, focused) renpy.show_screen(controller, focused)
screen cho_dual_cg(focused, _layer="screens", bubble="cho_handjob_bubble", mask="cho_handjob_bubble_mask"): screen cho_dual_cg(focused, _layer="screens", bubble_="cho_handjob_bubble", mask="cho_handjob_bubble_mask"):
tag switcher tag switcher
zorder 300 zorder 300
@ -27,12 +27,12 @@ screen cho_dual_cg(focused, _layer="screens", bubble="cho_handjob_bubble", mask=
if d: if d:
$ btn = AlphaMask(Fixed(Transform(d, align=( (1.0, 0.05) if flip else (0.0, 0.05) ), zoom=0.5, xzoom=flip)), Transform(mask, zoom=0.25)) $ btn = AlphaMask(Fixed(Transform(d, align=( (1.0, 0.05) if flip else (0.0, 0.05) ), zoom=0.5, xzoom=flip)), Transform(mask, zoom=0.25))
$ btn = Fixed(Transform(bubble, zoom=0.25), btn) $ btn = Fixed(Transform(bubble_, zoom=0.25), btn)
imagebutton: imagebutton:
idle Transform(btn, alpha=0.75) idle Transform(btn, alpha=0.75)
hover Transform(btn, alpha=1.0) hover Transform(btn, alpha=1.0)
action Function(cg_pov_switch, layer=_layer) action Function(cg_pov_switch, layer=_layer)
focus_mask True focus_mask True
at transform: at transform:
xzoom flip xzoom flip

View File

@ -50,10 +50,10 @@ label ast_walk(xpos=None, ypos=None, speed=1.0, action=None, reduce=False, path=
return return
# Screens # Screens
screen ast_cloth_pile(position=(440, 425)): # Default position: Right of desk, below feet. screen ast_cloth_pile(pos=(440, 425)): # Default position: Right of desk, below feet.
tag ast_cloth_pile tag ast_cloth_pile
zorder astoria_chibi.zorder zorder astoria_chibi.zorder
add "characters/chibis/cloth_pile_r.webp" pos position zoom 0.5 add "characters/chibis/cloth_pile_r.webp" pos pos zoom 0.5
# Chibi definition # Chibi definition
default astoria_chibi = Chibi("astoria", ["fix", "base", "bottom", "shoes", "top", "robe", "gloves"], update_astoria_chibi) default astoria_chibi = Chibi("astoria", ["fix", "base", "bottom", "shoes", "top", "robe", "gloves"], update_astoria_chibi)

View File

@ -50,10 +50,10 @@ label cho_walk(xpos=None, ypos=None, speed=1.0, action=None, reduce=False, path=
return return
# Screens # Screens
screen cho_cloth_pile(position=(440, 425)): # Default position: Right of desk, below feet. screen cho_cloth_pile(pos=(440, 425)): # Default position: Right of desk, below feet.
tag cho_cloth_pile tag cho_cloth_pile
zorder cho_chibi.zorder zorder cho_chibi.zorder
add "characters/chibis/cloth_pile_r.webp" pos position zoom 0.5 add "characters/chibis/cloth_pile_r.webp" pos pos zoom 0.5
# Chibi definition # Chibi definition
default cho_chibi = Chibi("cho", ["fix", "base", "bottom", "shoes", "top", "robe", "gloves"], update_cho_chibi) default cho_chibi = Chibi("cho", ["fix", "base", "bottom", "shoes", "top", "robe", "gloves"], update_cho_chibi)

View File

@ -910,7 +910,7 @@ label cc_pf_strip_T2_intro_E3:
hide screen bld1 hide screen bld1
hide screen blkfade hide screen blkfade
with d3 with d3
call teleport(position="cho", effect=False) call teleport(position_="cho", effect=False)
pause .5 pause .5
call bld call bld
@ -1239,4 +1239,3 @@ label cc_pf_strip_T2_E3_fail_repeat:
call cho_walk(action="leave") call cho_walk(action="leave")
jump end_cho_event jump end_cho_event

View File

@ -101,7 +101,7 @@ label hufflepuff_match:
with d3 with d3
call gen_chibi("stand", "door", "base") call gen_chibi("stand", "door", "base")
call teleport(position="genie", effect=False) call teleport(position_="genie", effect=False)
pause .5 pause .5
call gen_chibi("stand", "door", "base", flip=False) call gen_chibi("stand", "door", "base", flip=False)

View File

@ -1680,7 +1680,7 @@ label cho_quid_E14:
play sound "sounds/kick.ogg" play sound "sounds/kick.ogg"
call gen_chibi("stand", 430, "base") call gen_chibi("stand", 430, "base")
call teleport(position="genie", effect=False) call teleport(position_="genie", effect=False)
cho @ cheeks blush "Whoa! I didn't know you could apparate at Hogwarts!" ("angry", "narrow", "base", "mid") cho @ cheeks blush "Whoa! I didn't know you could apparate at Hogwarts!" ("angry", "narrow", "base", "mid")
gen "Appa--{w=0.4} What?" ("base", xpos="far_left", ypos="base") gen "Appa--{w=0.4} What?" ("base", xpos="far_left", ypos="base")

View File

@ -31,9 +31,9 @@ style meter_text:
align (0.0, 0.5) align (0.0, 0.5)
xoffset 5 xoffset 5
screen swear_bubble(type): screen swear_bubble(kind):
tag bubble tag bubble
zorder 30 zorder 30
add "interface/meter/bubble/"+str(type)+".webp" ypos 100 xpos 100 add "interface/meter/bubble/[kind].webp" ypos 100 xpos 100
timer 1.0 action Hide("swear_bubble") timer 1.0 action Hide("swear_bubble")

View File

@ -146,7 +146,7 @@ label slytherin_match:
with d3 with d3
call gen_chibi("stand", "door", "base") call gen_chibi("stand", "door", "base")
call teleport(position="genie", effect=False) call teleport(position_="genie", effect=False)
pause .2 pause .2
call ton_chibi("stand", "desk", "base", flip=True) call ton_chibi("stand", "desk", "base", flip=True)

View File

@ -1,5 +1,3 @@
### Hermione Blowjob ### ### Hermione Blowjob ###
label start_hg_pf_blowjob: label start_hg_pf_blowjob:
@ -823,10 +821,10 @@ label hg_pf_hidden_blowjob:
jump hg_hidden_blowjob_luna jump hg_hidden_blowjob_luna
random: random:
block if states.her.ev.suck_it.snape_encounter: block:
jump hg_hidden_blowjob_snape jump hg_hidden_blowjob_snape
block if states.her.ev.suck_it.tonks_encounter: block:
jump hg_hidden_blowjob_tonks jump hg_hidden_blowjob_tonks
block if states.her.ev.suck_it.luna_encounter: block if states.her.ev.suck_it.luna_encounter:

View File

@ -95,6 +95,7 @@ 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

@ -50,10 +50,10 @@ label ton_walk(xpos=None, ypos=None, speed=1.0, action=None, reduce=False, path=
return return
# Screens # Screens
screen ton_cloth_pile(position=(440, 425)): # Default position: Right of desk, below feet. screen ton_cloth_pile(pos=(440, 425)): # Default position: Right of desk, below feet.
tag ton_cloth_pile tag ton_cloth_pile
zorder tonks_chibi.zorder zorder tonks_chibi.zorder
add "characters/chibis/cloth_pile_r.webp" pos position zoom 0.5 add "characters/chibis/cloth_pile_r.webp" pos pos zoom 0.5
label ton_sit(xpos=nxpos, ypos=nypos, flip=None, chair=True): # TODO: replace this with the regular chibi call and add a sitting pose/action -- call ton_chibi("sit", chair=False) label ton_sit(xpos=nxpos, ypos=nypos, flip=None, chair=True): # TODO: replace this with the regular chibi call and add a sitting pose/action -- call ton_chibi("sit", chair=False)

View File

@ -5,8 +5,8 @@ transform combine_transforms(one, two):
one one
two two
transform chibi_base(position, flip, scale): transform chibi_base(pos, flip, scale):
pos position pos pos
anchor (0.0, 1.0) anchor (0.0, 1.0)
xzoom (-1 if flip else 1) xzoom (-1 if flip else 1)
zoom (0.5 * scale) zoom (0.5 * scale)

View File

@ -145,6 +145,7 @@ label day_start:
# Start Quests # Start Quests
jump quests jump quests
# unreachable
$ renpy.choice_for_skipping() $ renpy.choice_for_skipping()
call screen room_menu call screen room_menu
@ -239,6 +240,7 @@ label night_start:
# Start Quests # Start Quests
jump quests jump quests
# unreachable
$ renpy.choice_for_skipping() $ renpy.choice_for_skipping()
call screen room_menu call screen room_menu

View File

@ -103,34 +103,33 @@ label increase_house_points(house, points):
return return
#TODO Check and fix teleport/heal effect position (chibis are now anchored bottom-left) #TODO Check and fix teleport/heal effect position (chibis are now anchored bottom-left)
label teleport(position=None,effect=True,poof_label=None): label teleport(position_=None, effect=True, poof_label=None):
python: if position_ == "genie":
if position == "genie": dynamic:
teleport_xpos = genie_chibi.pos[0]+75 teleport_pos = (genie_chibi.pos[0]+75, genie_chibi.pos[1])
teleport_ypos = genie_chibi.pos[1]
teleport_zorder = 3 teleport_zorder = 3
elif position == "hermione": elif position_ == "hermione":
teleport_xpos = hermione_chibi.pos[0]+45 dynamic:
teleport_ypos = hermione_chibi.pos[1] teleport_pos = (hermione_chibi.pos[0]+45, hermione_chibi.pos[1])
teleport_zorder = 3 teleport_zorder = 3
elif position == "cho": elif position_ == "cho":
teleport_xpos = cho_chibi.pos[0]+45 dynamic:
teleport_ypos = cho_chibi.pos[1] teleport_pos = (cho_chibi.pos[0]+45, cho_chibi.pos[1])
teleport_zorder = 3 teleport_zorder = 3
elif position == "astoria": elif position_ == "astoria":
teleport_xpos = astoria_chibi.pos[0]+45 dynamic:
teleport_ypos = astoria_chibi.pos[1] teleport_pos = (astoria_chibi.pos[0]+45, astoria_chibi.pos[1])
teleport_zorder = 3 teleport_zorder = 3
elif position == "desk": elif position_ == "desk":
teleport_xpos = 320 dynamic:
teleport_ypos = 450 teleport_pos = (320, 450)
teleport_zorder = 5 teleport_zorder = 5
else: else:
teleport_xpos = position[0] dynamic:
teleport_ypos = position[1] teleport_pos = position_
teleport_zorder = 2 teleport_zorder = 2
if effect == True: if effect:
play sound "sounds/magic4.ogg" play sound "sounds/magic4.ogg"
show screen whitefade show screen whitefade
with d1 with d1
@ -142,33 +141,31 @@ label teleport(position=None,effect=True,poof_label=None):
with d1 with d1
hide screen blkfade hide screen blkfade
show screen heal_animation show heal_ani onlayer screens zorder teleport_zorder:
anchor (0.5, 1.0)
pos teleport_pos
zoom 0.5
with d3 with d3
#stop music fadeout 1 #stop music fadeout 1
hide screen heal_animation hide heal_animation onlayer screens
if poof_label is not None: if poof_label is not None:
$ renpy.call(poof_label) call expression poof_label
show screen teleport_animation show teleport_ani onlayer screens zorder teleport_zorder:
anchor (0.5, 0.7)
pos teleport_pos
zoom 0.5
with d5 with d5
hide screen teleport_animation hide teleport_animation onlayer screens
with d5 with d5
if effect == True: if effect:
pause 1 pause 1
return return
screen teleport_animation():
add "teleport_ani" anchor (0.5, 0.7) xpos teleport_xpos ypos teleport_ypos zoom 0.5
zorder teleport_zorder
screen heal_animation():
add "heal_ani" anchor (0.5, 1.0) xpos teleport_xpos ypos teleport_ypos zoom 0.5
zorder teleport_zorder
# Dummy labels. To prevent crashes. # TODO: Remove later. # Dummy labels. To prevent crashes. # TODO: Remove later.
default hermione_action = None default hermione_action = None

View File

@ -156,8 +156,8 @@ init -1 python:
if config.developer: if config.developer:
def __setattr__(self, attr, value): def __setattr__(self, attr, value):
if hasattr(self, attr) and getattr(self, attr) != value: if getattr(self, attr, value) != value:
id = getattr(self, "id") id = self.id
rollback = f"{stdcol.UNDERLINE}(Rollback){stdcol.END} " if renpy.in_rollback() else "" rollback = f"{stdcol.UNDERLINE}(Rollback){stdcol.END} " if renpy.in_rollback() else ""
caller_id = renpy.get_filename_line() caller_id = renpy.get_filename_line()

View File

@ -426,7 +426,7 @@ label not_so_great_escape:
play sound "sounds/magic4.ogg" play sound "sounds/magic4.ogg"
call gen_chibi("stand", 370, 295) call gen_chibi("stand", 370, 295)
call teleport(position="genie", effect=False) call teleport(position_="genie", effect=False)
stop music fadeout 3 stop music fadeout 3
gen "You'll never catch me alive!" ("angry", xpos="far_left", ypos="head") gen "You'll never catch me alive!" ("angry", xpos="far_left", ypos="head")

View File

@ -3,7 +3,7 @@ init -999:
import json import json
import os import os
if not getattr(persistent, "mods_enabled"): if not persistent.mods_enabled:
persistent.mods_enabled = _set() persistent.mods_enabled = _set()
mods_list = _dict() mods_list = _dict()

View File

@ -144,7 +144,7 @@ init python:
# In case the player already started the event chain, send the letter early. # In case the player already started the event chain, send the letter early.
letter_cards_store.send() letter_cards_store.send()
getattr(store, "letter_cards_store").wait = 7 store.letter_cards_store.wait = 7
# Fix revertable types for modding # Fix revertable types for modding
mods_enabled = getattr(persistent, "mods_enabled", _set()) or _set() mods_enabled = getattr(persistent, "mods_enabled", _set()) or _set()
@ -154,7 +154,7 @@ init python:
setattr(persistent, "mods_list", _dict(mods_list)) setattr(persistent, "mods_list", _dict(mods_list))
# Fix event issue with Cho # Fix event issue with Cho
ev = getattr(store, "cho_ev_inspect_her_body_t2_e3") ev = store.cho_ev_inspect_her_body_t2_e3
if ev.completed and not states.cho.ev.inspect_her_body.T2_E3_complete: if ev.completed and not states.cho.ev.inspect_her_body.T2_E3_complete:
states.cho.ev.inspect_her_body.T2_E3_complete = True states.cho.ev.inspect_her_body.T2_E3_complete = True
@ -169,39 +169,39 @@ init python:
k.modpath = "mods/" + k.modpath.split("/")[-1] k.modpath = "mods/" + k.modpath.split("/")[-1]
if current < 1.46: if current < 1.46:
getattr(store, "her_ev_cumslut_public_t5_e1").label = "hg_pr_cumslut_T5_return" store.her_ev_cumslut_public_t5_e1.label = "hg_pr_cumslut_T5_return"
getattr(store, "her_ev_cumslut_public_t5_e1").reset() store.her_ev_cumslut_public_t5_e1.reset()
getattr(store, "her_ev_cumslut_public_t5_e1").dequeue() store.her_ev_cumslut_public_t5_e1.dequeue()
getattr(store, "her_ev_cumslut_public_t5_e2").label = "hg_pr_cumslut_T5_return" store.her_ev_cumslut_public_t5_e2.label = "hg_pr_cumslut_T5_return"
getattr(store, "her_ev_cumslut_public_t5_e2").reset() store.her_ev_cumslut_public_t5_e2.reset()
getattr(store, "her_ev_cumslut_public_t5_e2").dequeue() store.her_ev_cumslut_public_t5_e2.dequeue()
getattr(store, "her_ev_cumslut_public_t5_e3").label = "hg_pr_cumslut_T5_return" store.her_ev_cumslut_public_t5_e3.label = "hg_pr_cumslut_T5_return"
getattr(store, "her_ev_cumslut_public_t5_e3").reset() store.her_ev_cumslut_public_t5_e3.reset()
getattr(store, "her_ev_cumslut_public_t5_e3").dequeue() store.her_ev_cumslut_public_t5_e3.dequeue()
getattr(store, "her_ev_cumslut_public_t5_e1_hub").label = "hg_pr_cumslut" store.her_ev_cumslut_public_t5_e1_hub.label = "hg_pr_cumslut"
getattr(store, "her_ev_cumslut_public_t5_e1_hub").req = "states.her.tier == 5" store.her_ev_cumslut_public_t5_e1_hub.req = "states.her.tier == 5"
getattr(store, "her_ev_cumslut_public_t5_e1_hub").reset() store.her_ev_cumslut_public_t5_e1_hub.reset()
getattr(store, "her_ev_cumslut_public_t5_e2_hub").label = "hg_pr_cumslut" store.her_ev_cumslut_public_t5_e2_hub.label = "hg_pr_cumslut"
getattr(store, "her_ev_cumslut_public_t5_e2_hub").req = "states.her.tier == 5" store.her_ev_cumslut_public_t5_e2_hub.req = "states.her.tier == 5"
getattr(store, "her_ev_cumslut_public_t5_e2_hub").reset() store.her_ev_cumslut_public_t5_e2_hub.reset()
getattr(store, "her_ev_cumslut_public_t5_e3_hub").label = "hg_pr_cumslut" store.her_ev_cumslut_public_t5_e3_hub.label = "hg_pr_cumslut"
getattr(store, "her_ev_cumslut_public_t5_e3_hub").req = "states.her.tier == 5" store.her_ev_cumslut_public_t5_e3_hub.req = "states.her.tier == 5"
getattr(store, "her_ev_cumslut_public_t5_e3_hub").reset() store.her_ev_cumslut_public_t5_e3_hub.reset()
getattr(store, "lun_ev_talk_to_me_t3_e1").req = "states.lun.tier == 3" store.lun_ev_talk_to_me_t3_e1.req = "states.lun.tier == 3"
getattr(store, "lun_ev_talk_to_me_t3_e1").reset() store.lun_ev_talk_to_me_t3_e1.reset()
getattr(store, "lun_ev_inspect_her_body_t3_e1").req = "states.lun.tier == 3" store.lun_ev_inspect_her_body_t3_e1.req = "states.lun.tier == 3"
getattr(store, "lun_ev_inspect_her_body_t3_e1").reset() store.lun_ev_inspect_her_body_t3_e1.reset()
getattr(store, "lun_ev_play_with_yourself_t3_e1").req = "states.lun.tier == 3" store.lun_ev_play_with_yourself_t3_e1.req = "states.lun.tier == 3"
getattr(store, "lun_ev_play_with_yourself_t3_e1").reset() store.lun_ev_play_with_yourself_t3_e1.reset()
getattr(store, "lun_ev_play_with_yourself_t3_e2").req = "states.lun.tier == 3" store.lun_ev_play_with_yourself_t3_e2.req = "states.lun.tier == 3"
getattr(store, "lun_ev_play_with_yourself_t3_e2").reset() store.lun_ev_play_with_yourself_t3_e2.reset()
getattr(store, "lun_ev_play_with_yourself_t3_e3").req = "states.lun.tier == 3" store.lun_ev_play_with_yourself_t3_e3.req = "states.lun.tier == 3"
getattr(store, "lun_ev_play_with_yourself_t3_e3").reset() store.lun_ev_play_with_yourself_t3_e3.reset()
getattr(store, "lun_ev_play_with_yourself_t3_e4").req = "states.lun.tier == 3" store.lun_ev_play_with_yourself_t3_e4.req = "states.lun.tier == 3"
getattr(store, "lun_ev_play_with_yourself_t3_e4").reset() store.lun_ev_play_with_yourself_t3_e4.reset()
if states.lun.tier == 3: if states.lun.tier == 3:
states.lun.level = 9 states.lun.level = 9
@ -212,7 +212,7 @@ init python:
doll.body.matrix = IdentityMatrix() doll.body.matrix = IdentityMatrix()
if current < 1.461: if current < 1.461:
getattr(store, "ton_accessory_office").zorder = 235 store.ton_accessory_office.zorder = 235
if current < 1.462: if current < 1.462:
lun_ev_blowjob_t4_e1.enqueue() lun_ev_blowjob_t4_e1.enqueue()