Skip to content

Commit 4059dde

Browse files
chore(minigames): add candle minigame prototype
1 parent d02953d commit 4059dde

File tree

7 files changed

+70
-0
lines changed

7 files changed

+70
-0
lines changed

game/images/candle/candle1.png

17 KB
Loading

game/images/candle/candle2.png

21.5 KB
Loading

game/images/candle/candle3.png

25.5 KB
Loading

game/images/candle/candle4.png

33.1 KB
Loading

game/images/candle/candle5.png

40.5 KB
Loading

game/story/minigames/candle.rpy

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
label candle_minigame:
2+
call screen candle_minigame
3+
4+
5+
init python:
6+
def ondrag(drags, drop) -> None:
7+
drag = drags[0]
8+
drag_index = int(drag.drag_name)
9+
10+
if not drop:
11+
drag.snap(drag_index/10, 0.5, 0.2)
12+
return
13+
14+
drop_index = int(drop.drag_name)
15+
drag.snap(drop_index/10, 0.5, 0.2)
16+
drop.snap(drag_index/10, 0.5, 0.2)
17+
drag.drag_name = drop_index
18+
drop.drag_name = drag_index
19+
20+
21+
screen candle_minigame():
22+
draggroup:
23+
drag:
24+
child "candle/candle1.png"
25+
drag_name "1"
26+
draggable True
27+
dragged ondrag
28+
droppable True
29+
xpos .1
30+
ypos .5
31+
32+
drag:
33+
child "candle/candle2.png"
34+
drag_name "2"
35+
draggable True
36+
dragged ondrag
37+
droppable True
38+
xpos .2
39+
ypos .5
40+
41+
drag:
42+
child "candle/candle3.png"
43+
drag_name "3"
44+
draggable True
45+
dragged ondrag
46+
droppable True
47+
xpos .3
48+
ypos .5
49+
50+
drag:
51+
child "candle/candle4.png"
52+
drag_name "4"
53+
draggable True
54+
dragged ondrag
55+
droppable True
56+
xpos .4
57+
ypos .5
58+
59+
drag:
60+
child "candle/candle5.png"
61+
drag_name "5"
62+
draggable True
63+
dragged ondrag
64+
droppable True
65+
xpos .5
66+
ypos .5

game/story/start.rpy

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@ default trust = 0
22
default karmic = 0
33
default karmic_awareness = 0
44

5+
56
label splashscreen:
7+
68
# TODO: logo
79
scene bg logo with Dissolve(1)
810
pause 1.0
@@ -19,7 +21,9 @@ label splashscreen:
1921

2022
return
2123

24+
2225
label start:
26+
2327
stop music fadeout 1.0
2428

2529
pause(1)

0 commit comments

Comments
 (0)