Another problem that i ran into. So i have a callback defined right in the beginning on the "script.rpy" which makes a sound play while text is appearing in the dialogue window. It looks like that:
Code: Select all
init python:
def callback(event, **kwargs):
if event == "show":
renpy.music.play("music/text.mp3", channel="sound")
elif event == "slow_done" or event == "end":
renpy.music.stop(channel="sound")
return
Code: Select all
define e = Character("Meteorite", callback=callback)
I tried to solve this like that:
Code: Select all
init python:
def callback(event, **kwargs):
if event == "show":
renpy.music.play("music/text.mp3", channel="sound")
elif event == "slow_done" or event == "end":
renpy.music.stop(channel="sound")
if event == "ShowMenu()":
renpy.music.stop(channel="sound")
return
As always, thank you for attention <3