Hi there. I'm very new to Ren'Py, and I'm trying to figure out how to position side images. I've gotten the image to actually show up by using this code:
The image overlaps the text, so I adjusted the padding. It fixes the overlap, but it does so by moving the text instead of the image. For all I know, that's what it's supposed to do, but I'd rather move the image itself further to the left.
Here's what it looks like with the number set to 170:
And here it is set to 400:
(I'm sorry about the ugly stick figures. I wanted to figure out how Ren'Py actually works before putting effort into actual sprites).
Any advice would be greatly appreciated.
Showing and Positioning Side Images
Forum rules
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
This is the right place for Ren'Py help. Please ask one question per thread, use a descriptive subject like 'NotFound error in option.rpy' , and include all the relevant information - especially any relevant code and traceback messages. Use the code tag to format scripts.
-
TwylaMarie
- Newbie
- Posts: 1
- Joined: Mon May 07, 2018 4:18 pm
- Contact:
- Qlara
- Regular
- Posts: 80
- Joined: Fri Nov 28, 2014 10:22 am
- Completed: Carmilla
- Skype: kantonija
- itch: visualgothic
- Location: Berlin
- Contact:
Re: Showing and Positioning Side Images
'padding' is free space within an element, in this case 'window', so if you increase 'window_left_padding', all elements inside the window move to the right.
To align your sprite with the left border you could delete your 'window_left_padding' and use
You can position your text with 'what_xpos = 100' (or whatever value) inside the brackets of your t definition and the character name position with 'who_ypos = ...'
To align your sprite with the left border you could delete your 'window_left_padding' and use
Code: Select all
image side Testsprite = "side_testspritething4"
xalign 0.0
#and more position— or zoom parameters here- xavimat
- Eileen-Class Veteran
- Posts: 1458
- Joined: Sat Feb 25, 2012 8:45 pm
- Completed: Yeshua, Jesus Life, Cops&Robbers
- Projects: Fear&Love, unknown
- Organization: Pilgrim Creations
- Github: xavi-mat
- itch: pilgrimcreations
- Location: Spain
- Contact:
Re: Showing and Positioning Side Images
I'm not sure Qlara's code will work. SideImage is already positioned at xalign 0.0, and the colon is missing.
Your image is not to the left, I guess, because it contains transparent space at the left of it. If so, crop it.
If not, you can move it to the left with xoffset:
Your image is not to the left, I guess, because it contains transparent space at the left of it. If so, crop it.
If not, you can move it to the left with xoffset:
Code: Select all
image side Testsprite:
"side_testspritething4"
xoffset -100Comunidad Ren'Py en español: ¡Únete a nuestro Discord!
Rhaier Kingdom A Ren'Py Multiplayer Adventure Visual Novel.
Cops&Robbers A two-player experiment | Fear&Love Why can't we say I love you?
Honest Critique (Avatar made with Chibi Maker by ~gen8)
Rhaier Kingdom A Ren'Py Multiplayer Adventure Visual Novel.
Cops&Robbers A two-player experiment | Fear&Love Why can't we say I love you?
Honest Critique (Avatar made with Chibi Maker by ~gen8)
Who is online
Users browsing this forum: _ticlock_