Skip to main content

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

Back with a new bug report! This time around it's related to self-voicing (normally activated with "v"). The game throws the following error when I hover over a choice menu making use of truncate_text.

(The same also happens in NVL mode and in the history screen, where i shorten the character names with truncate_text.)

I'm sorry, but an uncaught exception occurred.
While running game code:
  File "game/script/routes/loye_3.rpy", line 1359, in script
    menu:
TypeError: TruncateText._tts() got an unexpected keyword argument 'raw'
-- Full Traceback ------------------------------------------------------------
Traceback (most recent call last):
  File "game/script/routes/loye_3.rpy", line 1359, in script
    menu:
  File "renpy/ast.py", line 1816, in execute
    choice = renpy.exports.menu(choices, self.set, args, kwargs, item_arguments)
             ~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "renpy/exports/menuexports.py", line 135, in menu
    rv = renpy.store.menu(new_items)
         ~~~~~~~~~~~~~~~~^^^^^^^^^^^
  File "renpy/exports/menuexports.py", line 418, in display_menu
    rv = renpy.ui.interact(mouse="menu", type=type, roll_forward=roll_forward)
         ~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "renpy/ui.py", line 306, in interact
    rv = renpy.game.interface.interact(roll_forward=roll_forward, **kwargs)
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "renpy/display/core.py", line 2164, in interact
    repeat, rv = self.interact_core(
                 ~~~~~~~~~~~~~~~~~~^
        preloads=preloads,
        ^^^^^^^^^^^^^^^^^^
    ...<4 lines>...
        **kwargs,
        ^^^^^^^^^
    )
    ^
  File "renpy/display/core.py", line 3259, in interact_core
    rv = renpy.display.focus.mouse_handler(ev, x, y)
         ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^
  File "renpy/display/focus.py", line 641, in mouse_handler
    return change_focus(new_focus, default=default)
           ~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "renpy/display/focus.py", line 568, in change_focus
    set_focused(current, newfocus.arg, newfocus.screen)
    ~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "renpy/display/focus.py", line 217, in set_focused
    renpy.display.tts.displayable(widget)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^
  File "renpy/display/tts.py", line 428, in displayable
    s = d._tts_all(raw=False)
        ~~~~~~~~~~^^^^^^^^^^^
  File "renpy/display/behavior.py", line 1204, in _tts_all
    rv = self._tts_common(alt(self.action), raw=raw)
         ~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "renpy/display/displayable.py", line 625, in _tts_common
    speech = i._tts(raw=raw)
             ~~~~~~^^^^^^^^^
  File "renpy/display/displayable.py", line 663, in _tts
    return self._tts_common(raw=raw)
           ~~~~~~~~~~~~~~~~^^^^^^^^^
  File "renpy/display/displayable.py", line 625, in _tts_common
    speech = i._tts(raw=raw)
             ~~~~~~^^^^^^^^^
  File "renpy/display/layout.py", line 1300, in _tts
    return self._tts_common(raw=raw)
           ~~~~~~~~~~~~~~~~^^^^^^^^^
  File "renpy/display/displayable.py", line 625, in _tts_common
    speech = i._tts(raw=raw)
             ~~~~~~^^^^^^^^^
  File "renpy/display/layout.py", line 1300, in _tts
    return self._tts_common(raw=raw)
           ~~~~~~~~~~~~~~~~^^^^^^^^^
  File "renpy/display/displayable.py", line 625, in _tts_common
    speech = i._tts(raw=raw)
             ~~~~~~^^^^^^^^^
TypeError: TruncateText._tts() got an unexpected keyword argument 'raw'
Windows-11-10.0.22631-SP0 AMD64
Ren'Py 8.5.3.26042304+nightly

Interesting! Looks like something that changed between engine versions. You can update these functions in the backend file:

def _tts(self, *args, **kwargs):
    return self.parent_class._tts(self, *args, **kwargs)
def _tts_all(self, *args, **kwargs):
    return self.parent_class._tts_all(self, *args, **kwargs)

And that should fix it.

Oh yeah, I'm on the latest nightlies, so that's probably why. Thank you, I can confirm this fixed it!