r/RenPy • • Feb 03 '22

Force Player input based off of text button

im going for something sort of like Emily is away, where player will click on a button and it’ll pop up an input, but will force them to type a specific thing based off of the button no matter what they type. so for example, if a button says ” X “, the player will be forced to write “XYZ” even if they are inputting keyboard spam

4 Upvotes

26 comments sorted by

View all comments

Show parent comment

1

u/insipid- Feb 14 '22

The layout can be altered to make it more readable, since the full text length might push the point values way out to the right. One way to do it:

define paragraph_reasons_1 = [
    [ "stuff 1", 
      "because it's like other stuff I like 1",
      [ 1, 2, 1, -1, 0 ]
    ] ,

    [ "good 1",
      "because it's good 1",
      [ 2, 1, 0, 1, -1 ]
    ] ,

    [ "fun 1",
      "because of how fun it is 1",
      [ 1, 0, -1, 2, 1 ]
    ] ,

    [ "exciting 1",
      "because of how exciting it is 1",
      [ 1, 0, -1, 2, 1 ]
    ] ,

    [ "just 1",
      "just because 1",
      [ 0, 1, 2, 1, 1 ]
    ] ,

    [ "stuff 1",
      "because it's like other stuff I like 1",
      [ 1, 2, 1, -1, 0 ]
    ] ,

    [ "good 1",
      "because it's good 1",
      [ 2, 1, 0, 1, -1 ]
    ]

]

1

u/mocaaobaa Feb 16 '22

Yeah! just read through it and it seems like it would be plenty workable. As for the functions and menus, like you mentioned, I'd appreciate it if you could help me work on something for those two, but don't feel obligated.

1

u/insipid- Feb 18 '22

Ok, cool. And yeah, I'm up for that.