Compare commits
No commits in common. "6b6ad56af461b8882f0cbcf9941724289698ea46" and "0d8e91b5a5af4eeb8176de38d14800afda62f7ee" have entirely different histories.
6b6ad56af4
...
0d8e91b5a5
@ -1,6 +1,3 @@
|
||||
# will be populated by the chibi inits
|
||||
define __poses = {}
|
||||
|
||||
init 5 python:
|
||||
class DollChibi(renpy.Displayable):
|
||||
|
||||
@ -24,10 +21,7 @@ init 5 python:
|
||||
if doll is None:
|
||||
doll = states.dolls[name]
|
||||
self.char = doll
|
||||
|
||||
__poses[name] = {}
|
||||
if poses is not None:
|
||||
self.poses.update(poses)
|
||||
self.poses = poses or {}
|
||||
|
||||
# Animation
|
||||
self.anim_frames = None
|
||||
@ -48,10 +42,11 @@ init 5 python:
|
||||
|
||||
self.instances[name] = self
|
||||
|
||||
# no setter, on purpose
|
||||
@property
|
||||
def poses(self):
|
||||
return __poses[self.name]
|
||||
def register(self, pose, frames, size):
|
||||
self.poses[pose] = (frames, size)
|
||||
|
||||
if config.developer:
|
||||
print(f"Registered \"{pose}\" pose for {self.name}")
|
||||
|
||||
@functools.cache
|
||||
def build_image(self, hash, pose):
|
||||
@ -371,10 +366,7 @@ init 5 python:
|
||||
|
||||
init offset = 5
|
||||
|
||||
default hooch_chibi = DollChibi(name="hooch", doll=hooch, poses=dict(
|
||||
stand=(1, (600, 800)),
|
||||
walk=(8, (600, 800)),
|
||||
))
|
||||
default hooch_chibi = DollChibi(name="hooch", doll=hooch)
|
||||
# default cho_chibi_new = DollChibi(name="cho", doll=cho)
|
||||
# default tonks_chibi_new = DollChibi(name="tonks", doll=tonks, poses=dict(
|
||||
# stand=(1, (600, 800)),
|
||||
|
@ -16,4 +16,9 @@ init python:
|
||||
|
||||
char.set_face(mouth="base", eyes="base", eyebrows="base", pupils="mid", cheeks="none", tears="none")
|
||||
|
||||
config.start_callbacks.append(wardrobe_init)
|
||||
def chibi_init():
|
||||
# TODO: Perhaps it could be automated?
|
||||
hooch_chibi.register("stand", 1, (600, 800))
|
||||
hooch_chibi.register("walk", 8, (600, 800))
|
||||
|
||||
config.start_callbacks.extend([wardrobe_init, chibi_init])
|
||||
|
Loading…
Reference in New Issue
Block a user