Discuss how to use the Ren'Py engine to create visual novels and story-based games. New releases are announced in this section.
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.
-
zatel
- Newbie
- Posts: 7
- Joined: Sat May 07, 2016 7:18 pm
-
Contact:
#1
Post
by zatel » Sun May 08, 2016 5:18 am
Currently there are no errors. But my character seems a bit gigantic for take up nearly the entire screen. I know I can just resize the image but I'm not trying to do that.
Here is the code.
Code: Select all
define center = Position(yalign=2)
then I use that to position it.
The image doesn't even budge. I tired the one Ren'Py's wiki page but that doesn't work either (well, I think it does, but the ypos doesn't work).
Code: Select all
show denm at Position(xpos = 0.5, xanchor=0.5, ypos=32, yanchor=32)
-
xela
- Lemma-Class Veteran
- Posts: 2481
- Joined: Sun Sep 18, 2011 10:13 am
-
Contact:
#2
Post
by xela » Sun May 08, 2016 6:34 am
Position is really old, try transforms and read the docs on positional properties a little bit.
Like what we're doing? Support us at:

-
zatel
- Newbie
- Posts: 7
- Joined: Sat May 07, 2016 7:18 pm
-
Contact:
#3
Post
by zatel » Sun May 08, 2016 8:44 pm
xela wrote:Position is really old, try transforms and read the docs on positional properties a little bit.
Thanks, but I've been using the basic transform functions. I looked at the ATL page but that looks like it's for moving pictures. I just want a normal picture to stay in a specific spot.
-
philat
- Eileen-Class Veteran
- Posts: 1853
- Joined: Wed Dec 04, 2013 12:33 pm
-
Contact:
#4
Post
by philat » Mon May 09, 2016 12:02 am
It's not for moving pictures. It's for manipulating how elements are presented on-screen -- position is one of the things that you can manipulate.
-
zatel
- Newbie
- Posts: 7
- Joined: Sat May 07, 2016 7:18 pm
-
Contact:
#5
Post
by zatel » Sat May 14, 2016 2:27 am
philat wrote:It's not for moving pictures. It's for manipulating how elements are presented on-screen -- position is one of the things that you can manipulate.
Thanks, however, it seems like I can only get the yalign to work. The x will just make it stay in one place, move all the way to the other side, or it'll just make the entire picture disappear. Any tips?
Also, when I use the yalign, some of my pictures will move to the side instead of going up and down, regardless of what I put, even though it was originally in the center.
-
Onishion
- Veteran
- Posts: 295
- Joined: Mon Apr 20, 2015 10:36 am
-
Contact:
#6
Post
by Onishion » Sun May 15, 2016 8:52 am
I always find align a pain in the ass. What align does is it sets the "anchor" of the image, which is sort of like where the thumb tack would go if you attached it to something, AND it sets the "position" of the image, which is where that thumb tack goes on the stage, and it's always a hassle to get it to the right place. I prefer to leave the anchor alone, and just use "pos" to move images around. also, I think "center" is a built in Renpy command, and changing it might mess things up. Try using something unique for your own label, like "mycenter" or something. And just a reminder if you don't know, using a value for position with a decimal, like 2.0, places it relative to the size of the stage. I think the position "2.0" might put it one full screen distance off the stage. Using numbers without decimal points, like "2" moves it by pixels, so only 2 pixels. It's important to know where the anchor point of the image is though, "anchor (0.5,0.5)" would put it dead center of the image, 0,0 puts it in the top left corner. That is the point where the object will move from.
-
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:
#7
Post
by xavimat » Sun May 15, 2016 3:55 pm
I use align all the time for "general" positioning and pos only when I need to position to the exact pixel (for example to match with a background). With align, xalign, yalign use only decimals from 0.0 to 1.0. Usign 2.0 will put your image off the screen (or most part of it, it depends on the image size).