I need help with animation

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.
Message
Author
zeo1fan
Newbie
Posts: 18
Joined: Mon Aug 01, 2011 9:35 pm
Contact:

I need help with animation

#1 Post by zeo1fan »

I'm a total Renpy newbie and I need help with animation. I get the feeling I'm missing something really BASIC but I don't know what! Can you help me?

My problem:

file:///Users/michealthompson/Desktop/Screen%20shot%202011-08-01%20at%209.32.18%20PM.png

clannadman

Re: I need help with animation

#2 Post by clannadman »

What are you trying to communicate here?

bink
Regular
Posts: 49
Joined: Sat Jul 09, 2011 4:34 pm
Contact:

Re: I need help with animation

#3 Post by bink »

You posted a link to a local file on your machine. (See how the link begins with file://? That shows you it's a local file.) The file only exists on your computer and cannot be accessed through the internet. If you want us to see it, you will have to upload it.
When creating a new post, there is an option under the area where you enter your text called "Upload attachment". Select and upload the file through there, so we can all see it.
Otherwise we can't really help you, since we have no idea what you're talking about.

LVUER
King of Lolies
Posts: 4538
Joined: Mon Nov 26, 2007 9:57 pm
Completed: R.S.P
Location: Bandung, West Java, Indonesia
Contact:

Re: I need help with animation

#4 Post by LVUER »

He's either a spam or totally nob at computer and internet.
"Double the princesses, quadruple the fun!" - Haken Browning (SRW-OG Endless Frontier)

DeviantArt Account
MoeToMecha Blog (under construction)
Lolicondria Blog (under construction) <- NSFW

User avatar
PyTom
Ren'Py Creator
Posts: 16093
Joined: Mon Feb 02, 2004 10:58 am
Completed: Moonlight Walks
Projects: Ren'Py
IRC Nick: renpytom
Github: renpytom
itch: renpytom
Location: Kings Park, NY
Contact:

Re: I need help with animation

#5 Post by PyTom »

There's no reason to think he's a spammer. He simply made the mistake of posting a link to a local file - I do that on IRC from time to time.
Supporting creators since 2004
(When was the last time you backed up your game?)
"Do good work." - Virgil Ivan "Gus" Grissom
Software > Drama • https://www.patreon.com/renpytom

zeo1fan
Newbie
Posts: 18
Joined: Mon Aug 01, 2011 9:35 pm
Contact:

Re: I need help with animation

#6 Post by zeo1fan »

I-I'm sorry. I'm not a spammer. I just made a mistake.

here:

http://img835.imageshack.us/img835/802/ ... 1at932.png

User avatar
Gear
Miko-Class Veteran
Posts: 764
Joined: Tue Apr 05, 2011 10:15 pm
Projects: Tempestus Sum
Organization: Xenokos Interactive
IRC Nick: Gear
Skype: Skye.Gear
Location: Grand Prairie, TX
Contact:

Re: I need help with animation

#7 Post by Gear »

I'm a bit of a newbie myself, but you might want to start with your indentation. Anytime you see a line end with a colon (:), the blocks of code associated with it that follow (in this case, the next line) should be indented. Try going to line 14, and pressing the spacebar 4 times in front of it to indent it properly.

Of course, if there's a problem with the code itself, I wouldn't know, since I use ATL to animate, but the others should be able to help out with that if necessary.

Also, it's easier if you take the code that has the error and post it here. Copy it from your machine and paste it into the browser, then highlight the entire block of coding and hit the "Code" button above the posting window.
The best reason to get up in the morning is to outdo yourself: to do it better than you've ever done it before. But if you haven't done it better by nightfall... look at your globe and pick a spot: it's always morning somewhere.

User avatar
Alex
Lemma-Class Veteran
Posts: 3093
Joined: Fri Dec 11, 2009 5:25 pm
Contact:

Re: I need help with animation

#8 Post by Alex »

Well, what one can see here...
1) The changes in code was not saved, so Ren'py execute the previouse (unchanged) version of your script. It is neccessary to save changes in script before runing it (every script file).
2) <return:> in line 10 is not neccessary - just delete it.
3) When you declare a transform, the right sintax would be <trasform transform_name_that_is_a_single_word_without_spaces:> Also, as Gear mentioned, line 14 in your screenshot should have additional indentation, like
transform Negi_topright:
xalign 1.0 yalign 0.0

I think, this would be interesting for you to read http://www.renpy.org/wiki/renpy/FAQ#How ... _blocks.3F

zeo1fan
Newbie
Posts: 18
Joined: Mon Aug 01, 2011 9:35 pm
Contact:

Re: I need help with animation

#9 Post by zeo1fan »

I tried it and the program ran this time. :) But now the image isn't showing up.
Attachments
Screen shot 2011-08-02 at 1.56.59 PM.png

zeo1fan
Newbie
Posts: 18
Joined: Mon Aug 01, 2011 9:35 pm
Contact:

Re: I need help with animation

#10 Post by zeo1fan »

I tried it and the program ran this time. :) But now the image isn't showing up.
Attachments
Screen shot 2011-08-02 at 1.56.59 PM.png
Screen shot 2011-08-02 at 1.56.59 PM.png

zeo1fan
Newbie
Posts: 18
Joined: Mon Aug 01, 2011 9:35 pm
Contact:

Re: I need help with animation

#11 Post by zeo1fan »

Sorry for the double post. D:

User avatar
Alex
Lemma-Class Veteran
Posts: 3093
Joined: Fri Dec 11, 2009 5:25 pm
Contact:

Re: I need help with animation

#12 Post by Alex »

But now the image isn't showing up.
That's ok, 'cause you didn't tell Ren'py to "show" your image.
You see, <transform> is defining a set of manipulations that can be applied to your image. If you want to show an image, you should use "show" statement, like

Code: Select all

image Negi = "magic.png"

label start:
    show Negi:
        xalign 1.0 yalign 0.0

    L "Yo!"

zeo1fan
Newbie
Posts: 18
Joined: Mon Aug 01, 2011 9:35 pm
Contact:

Re: I need help with animation

#13 Post by zeo1fan »

So if I just put the yalign, xalign etc. then I don't need to tell it how to move? Is there a way I can precisely position it on the screen?

User avatar
Alex
Lemma-Class Veteran
Posts: 3093
Joined: Fri Dec 11, 2009 5:25 pm
Contact:

Re: I need help with animation

#14 Post by Alex »

If you need to just show the image, then yes. If you want it to move - tell Ren'py to move the image. The one of possible ways

Code: Select all

init:
    image Negi = "magic.png"

    transform some_move_trans: # defines the transform, that can be applied to any image
        xalign 0.7 yalign 0.0
        linear 3 xalign 0.3 yalign 0.5

label start:
    show Negi at some_move_trans # shows an image "Negi" with transform, named "some_move_trans"

    L "Yo!"
To set the precise position use xpos and ypos - http://www.renpy.org/doc/html/style.htm ... properties

zeo1fan
Newbie
Posts: 18
Joined: Mon Aug 01, 2011 9:35 pm
Contact:

Re: I need help with animation

#15 Post by zeo1fan »

I tried to slide 'Negi' on the screen with 'show', 'transform', and the coordinates. It didn't work. :/
Attachments
Screen shot 2011-08-02 at 3.26.55 PM.png

Post Reply

Who is online

Users browsing this forum: No registered users