- Dec 2, 2018
- 81
- 3,464
I know. You probably didn't see the whole patch, I only gave you some of the code to make it easier to find what I changed.t = t.replace("This is my husband's brother. He's renting a room from me.","He is my [son]."
Are you aware that you are applying this to every dialogue text?
No, it doesn't work.t = t.replace("This is my husband's brother. He's renting a room from me.","He is my [son]."
You can just do if str(who) in (str(gg), "Donald"):
that helped, thanks!If you want to filter translations as well you need a wrapper forrenpy.translation.StringTranslator.translate
I did that for my mod, because I don't know if there is any other way.
Probably something like this:
Python:init python hide: translate = renpy.translation.StringTranslator.translate def hijack(self, s): return translate(self, s).replace("Mary", "Mom") renpy.translation.StringTranslator.translate = hijack
in case you're interested, patch for a game called MILF's Plaza.