Search found 1567 matches

by philat
Tue Apr 23, 2019 2:21 am
Forum: Ren'Py Questions and Announcements
Topic: how to parse a variable in image text
Replies: 3
Views: 42

Re: how to parse a variable in image text

The problem is the image is defined once taking the value of name at the time of definition and isn't updated. (Also possibly the order the variable being defined -- have you added a default name = None or something at the beginning?) I'd try ParameterizedText (https://www.renpy.org/doc/html/text.ht...
by philat
Tue Apr 23, 2019 1:55 am
Forum: Ren'Py Questions and Announcements
Topic: Checking number of options selected in a check menu [Solved]
Replies: 11
Views: 183

Re: Checking number of options selected in a check menu

You can just refer to each clue by its index in the all_clues or all_deductions list (refer to all_clues[0].create("The butler was having an affair with the housekeeper.") ). You could also manually assign more convenient names for them, but I didn't, because I'm lazy. It's not very different from u...
by philat
Mon Apr 22, 2019 10:41 pm
Forum: Ren'Py Questions and Announcements
Topic: Checking number of options selected in a check menu [Solved]
Replies: 11
Views: 183

Re: Checking number of options selected in a check menu

How you do this is honestly up to you, but this is one way that I would imagine going about it. It may be overkill if the game is simpler, but it would be easier to add/modify clues and deductions on the fly, since all you have to do is create a few new objects and link them together. It's also easy...
by philat
Mon Apr 22, 2019 9:54 pm
Forum: Ren'Py Questions and Announcements
Topic: Rollback Causing Issues with Random Events
Replies: 4
Views: 109

Re: Rollback Causing Issues with Random Events

pop returns and removes the item from the list. If that's not what you need, then of course you can use some other method.

Again, renpy.random should not affect rollback in your first example anyway; I don't know what you're doing to make it behave otherwise.
by philat
Mon Apr 22, 2019 6:04 am
Forum: Ren'Py Questions and Announcements
Topic: Checking number of options selected in a check menu [Solved]
Replies: 11
Views: 183

Re: Checking number of options selected in a check menu

Eh... there are a lot of ways to do this, but I wouldn't write it out all long hand -- using a list and some predefined objects should be cleaner in the long run (although writing it all out may be simpler if there aren't that many clues). Leaving a comment to remind myself to get back to you in the...
by philat
Sun Apr 21, 2019 10:40 pm
Forum: Ren'Py Questions and Announcements
Topic: Rollback Causing Issues with Random Events
Replies: 4
Views: 109

Re: Rollback Causing Issues with Random Events

Besides the fact that I don't believe the random event resets (it shouldn't, because renpy.random is designed to work through rollback), wouldn't using persistent in this manner only allow one playthrough anyway? If the only thing you're trying to is ensure that there are no duplicates, you could ju...
by philat
Sun Apr 21, 2019 10:35 pm
Forum: Ren'Py Questions and Announcements
Topic: Relative positioning
Replies: 5
Views: 173

Re: Relative positioning

Pass it a list.

Code: Select all

screen phonemain(lst):
    vbox:
        box_reverse True
        for msg in lst:
            text msg # or, you know, a textbutton is also fine.
by philat
Thu Apr 11, 2019 9:29 pm
Forum: Ren'Py Questions and Announcements
Topic: Relative positioning
Replies: 5
Views: 173

Re: Relative positioning

Why wouldn't you just use a vbox to do the positioning for you?
by philat
Wed Apr 10, 2019 8:53 pm
Forum: Ren'Py Questions and Announcements
Topic: "slow_done" callback not firing for lipflap
Replies: 6
Views: 215

Re: "slow_done" callback not firing for lipflap

Code: Select all

    def show_guy(event, interact=True, **kwargs):
        if event == "slow_done" or event=="end":
            renpy.show("man")
            renpy.restart_interaction() # this
        elif event == "begin":
            renpy.show("man talking")
by philat
Wed Apr 10, 2019 11:41 am
Forum: Ren'Py Questions and Announcements
Topic: How can I make image appear in the middle of the screen?
Replies: 4
Views: 122

Re: How can I make image appear in the middle of the screen?

If I understand you correctly, I think you're looking for at truecenter rather than at center.
by philat
Wed Apr 10, 2019 11:40 am
Forum: Ren'Py Questions and Announcements
Topic: [Solved] Creating displayable character element with ToggleVariable
Replies: 4
Views: 107

Re: Creating displayable character element with ToggleVariable

Don't define it in the screen (that makes it a screen variable, which is local to the screen, rather than a regular, global variable).
by philat
Wed Apr 10, 2019 11:38 am
Forum: Ren'Py Questions and Announcements
Topic: Slow Motion ATL
Replies: 9
Views: 146

Re: Slow Motion ATL

I don't know what "slow motion" is supposed to mean. Just making any transform take a very long time would be, literally, slow motion.
by philat
Wed Apr 10, 2019 11:37 am
Forum: Ren'Py Questions and Announcements
Topic: [Releasing game problem]_How to do it without sharing the original arts?
Replies: 4
Views: 110

Re: [Releasing game problem]_How to do it without sharing the original arts?

You can archive your assets, but it's relatively trivial to un-archive them.
by philat
Wed Apr 10, 2019 11:36 am
Forum: Ren'Py Questions and Announcements
Topic: expected statement and syntax errors with def[]
Replies: 6
Views: 165

Re: expected statement and syntax errors with def[]

Renpy statements are not python, and you cannot define menus in python (at least the way you've set it up). Listen to Alex's suggestion -- what you want are labels. You can call labels anyway.
by philat
Sun Apr 07, 2019 11:31 am
Forum: Ren'Py Questions and Announcements
Topic: Using several textboxes [Solved]
Replies: 6
Views: 207

Re: Using several textboxes

2. I haven't tried it specifically, but I was thinking more along the lines of a python callback (something along the lines of https://lemmasoft.renai.us/forums/viewtopic.php?f=8&t=29339#p347595 which would run each time you do something like $ wheregoestextbox = "dbli" or whatever) 3. For this one,...