Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

No worries! This is something I'm looking to update the files to make it a bit easier to understand - by default, the controller pack sets the game_menu screen to be opened when you hit the game_menu shortcut button (e.g. Start/ESC/right click). In the template, this is made possible by setting `title` as a keyword argument rather than a required argument, hence the error complaining about requiring the title argument.

You can remove or adjust this line `_game_menu_screen = "game_menu"` and/or adjust `screen game_menu` to have `title=""` instead of just `title` as an argument.

As for the error, you can put this into the my_controller_event function:

try:
    cda = CONTROLLERDEVICEADDED
except NameError:
    ## Probably reporting some other error
    return rv

put it just above the `if ev.type == CONTROLLERDEVICEADDED:`

To be fair this may not solve all problems with error reporting - the main issue is just that Ren'Py tries to make an error message and skips over various other steps like declarations, which means it then gets caught on otherwise normal parts of the code. So that check is an attempt to ignore that particular problem if it arises, but it's possible it'll try throwing an error somewhere else instead.

And for the viewports, `controller_viewport` does not handle `side_` properties or automatically adding scrollbars unfortunately, so you'll need to explicitly set that up/add it instead. Notably, the following are equivalent (aside from the controller_viewport bit being a controller-compatible viewport obviously):

viewport:
    scrollbars "vertical"
    side_yfill True
side 'c r':
    yfill True
    controller_viewport:
        id 'whatever'
    vbar value YScrollValue("whatever")
Hope that helps!