This is a nice UX, and I'm trying to build the same thing using renpy. I've been playing with Drag and Drop (https://www.renpy.org/doc/html/drag_drop.html), and the drag-drop mechanism works pretty well. However, the issue is I don't know how to 'highlight' the slots while the displayable is being dragged.
In this test snippet:
Code: Select all
init python:
def do_dragged(drags, drop):
if not drop:
return
return True
screen slot_idle():
add "images/slot_idle.png" xpos 100 ypos 100
screen slot_highlight():
add "images/slot_highlight.png" xpos 100 ypos 100
screen begin():
draggroup:
drag:
drag_name "sword"
child "images/sword.png"
droppable True
dragged do_dragged
xpos 500
ypos 500
label start:
show screen slot_idle()
call screen begin()
return