I'm the programmer of a Renpy visual novel. There's a scene in the visual novel that requires a game. It's something similar to the poetry game in DDLC. I can't figure out how add a game like it into the game, and it isn't in the Renpy documentation, as far as I know of. Also, the renpy language is different from python, so everything I tried to do in python seems to work.
I tried to include pygame, but that just causes errors, i.e. 'Pygame has not been defined.'. Also, pygame doesn't seem to be included in the first place, likely because .rpy isn't the same as .py.
I tried to use menus to reproduce the game, but it's limited as moving parts are required for the game. Also, it's boring.