Search found 69 matches

by Tsapas
Tue Nov 19, 2013 10:52 am
Forum: Ren'Py Questions and Announcements
Topic: How to let player's choose their own names? [SOLVED]
Replies: 1
Views: 543

Re: How to let player's choose their own names?

The code needed is this $ my_name = renpy.input("What is your name?", "Default Name", length=15) This creates a textbox that says "What is your name?" and when the user clicks on in he can type his name. "Default Name" is optional and is what will be the character name if the user decides not to use...
by Tsapas
Mon Nov 11, 2013 6:11 pm
Forum: Ren'Py Questions and Announcements
Topic: [SOLVED]Inventory isntance has no attribute __len__
Replies: 4
Views: 1053

Re: Inventory isntance has no attribute __len__

First of all, try changing

Code: Select all

screen inventory:
to something like

Code: Select all

screen inventory_screen:
As it stands you have declared both a screen and a class as "Inventory". Then check for capitalization ("Inventory" instead of "inventory").
See if it resolves anything.
by Tsapas
Mon Nov 11, 2013 11:10 am
Forum: Ren'Py Questions and Announcements
Topic: Letting players choose name!!
Replies: 6
Views: 620

Re: Letting players choose name!!

Ah yeah, my bad, got mixed up. I've updated the previous code. Try that one.
by Tsapas
Mon Nov 11, 2013 10:18 am
Forum: Ren'Py Questions and Announcements
Topic: Letting players choose name!!
Replies: 6
Views: 620

Re: Letting players choose name!!

Just copy and paste it. The variables already match. The only thing you need to take care of is how you refer to your character in text. Example: text "Hi there [player_name]" # this will show his full name. pov "You can also call me by my first name, [player_first_name] or by my last name, [player_...
by Tsapas
Mon Nov 11, 2013 9:54 am
Forum: Ren'Py Questions and Announcements
Topic: Letting players choose name!!
Replies: 6
Views: 620

Re: Letting players choose name!!

You need to use DynamicCharacter instead of plain character definition. define player_first_name = "" define player_last_name = "" define player_name = "" # This way when you use [pov] or [povFirstName] or [povLastName] in the text it will show the current character name. # Need to declare all three...
by Tsapas
Mon Nov 11, 2013 9:16 am
Forum: Ren'Py Questions and Announcements
Topic: [Solved] Value won't change until the game restarts
Replies: 8
Views: 912

Re: Value won't change until the game restarts

Alright, I think I found a decent way. Inside <..>/renpy/common/00gamemenu.rpy it states: label _confirm_quit: if renpy.has_label("confirm_quit"): jump expression "confirm_quit" elif renpy.has_label("_compat_confirm_quit"): jump expression "_compat_confirm_quit" else: jump expression "_quit_prompt" ...
by Tsapas
Sun Nov 10, 2013 10:16 pm
Forum: Ren'Py Questions and Announcements
Topic: [Solved] Value won't change until the game restarts
Replies: 8
Views: 912

Re: Value won't change until the game restarts

How about that way init python: quit_trigger = True config.quit_action = Quit(confirm=quit_trigger) # maybe (confirm=eval(quit_trigger)) is needed, not tested it. label start: $ quit_trigger = False ###INTRODUCTION OF THE GAME### $ quit_trigger = True ###MAIN GAME### You still declare config_quit.ac...
by Tsapas
Sun Nov 10, 2013 9:05 pm
Forum: Ren'Py Questions and Announcements
Topic: Color string must be 3, 4, 6, or 8 hex digits long??
Replies: 2
Views: 1869

Re: Color string must be 3, 4, 6, or 8 hex digits long??

Exception: Color string must be 3, 4, 6, or 8 hex digits long. the color property takes RGB(A) values. That is Red, Green, Blue and Alpha Channel (optional) values. I.e: color=# F F F <--- white, that's 3 digits. (if the 4th digit is ommited, is defaulting to F (max value)). color=# F F F f <--- wh...
by Tsapas
Sun Nov 10, 2013 9:24 am
Forum: Ren'Py Questions and Announcements
Topic: Scrolling when you drag the cursor to the edge of the window
Replies: 2
Views: 484

Re: Scrolling when you drag the cursor to the edge of the wi

You could use edgescroll for that. Declare a screen as: screen my_screen: viewport: edgescroll (100, 500) # 100 being the pixels from each edge that scroll is activated, and 500 is the speed the image is scrolled add my_image And call it when you want with show screen my_screen If you're aiming for ...
by Tsapas
Fri Nov 08, 2013 6:01 pm
Forum: Ren'Py Questions and Announcements
Topic: Help: How To Disable Auto-Resume on Android
Replies: 2
Views: 571

Re: Help: How To Disable Auto-Resume on Android

See if config.auto_load is set to None to prevent automatic loading. Also, you can try and put this somewhere in your code (provided I've understood your problem) label after_load: # bits of code # everything here will be ran before control is passed to the user # and runs automatically by Ren'Py ev...
by Tsapas
Fri Nov 08, 2013 11:37 am
Forum: Ren'Py Questions and Announcements
Topic: Choosing players name questions.
Replies: 6
Views: 2276

Re: Choosing players name questions.

Omg, perfect. This is what I wanted. But I'm a little confused of where everything should be, sorry :/ Here is what I wrote in the script: You can do this "What's your name?" # The phrase in the brackets is the text that the game will display to prompt # the player to enter the name they've chosen....
by Tsapas
Fri Nov 08, 2013 11:22 am
Forum: Ren'Py Questions and Announcements
Topic: Choosing players name questions.
Replies: 6
Views: 2276

Re: Choosing players name questions.

Are you typing the name via renpy.input? It shouldn't trigger the save screen at all. Also for name separation you can try this: $ povName = renpy.input("What is your name?", length=50) or "Default full name if none entered" python: if " " in povName: #checks there is space char in name, indicating ...
by Tsapas
Fri Nov 08, 2013 8:34 am
Forum: Ren'Py Questions and Announcements
Topic: Changing auto-forward time's default setting
Replies: 2
Views: 1659

Re: Changing auto-forward time's default setting

Well, you could tamper with <..>/renpy/common/00preferences.rpy elif name == "auto-forward time": if value is None: if config.default_afm_enable is None: return FieldValue(_preferences, "afm_time", range=30.0, max_is_zero=True, style="slider") else: return FieldValue(_preferences, "afm_time", range=...
by Tsapas
Mon Nov 04, 2013 7:36 pm
Forum: Ren'Py Questions and Announcements
Topic: [SOLVED] Centering textbox text.
Replies: 6
Views: 891

Re: Centering textbox text.

Ah, for this you need (after a bit of trial and error) init: $ style.say_vbox.xfill = True # this spans the dialogue vbox over the entire available area $ style.say_dialogue.xcenter = 0.5 # this centers any line of text $ style.say_dialogue.text_align = 0.5 # this centers wrapped text for sentences ...