I need help about animation

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
User avatar
asurakyo
Prole
Posts: 8
Joined: Tue Mar 01, 2011 6:30 am

I need help about animation

Post by asurakyo »

Who can tell me how to begin animating?Thinks
User avatar
Motig
Prole
Posts: 28
Joined: Fri Oct 15, 2010 3:43 am

Re: I need help about animation

Post by Motig »

Check out this library made by Bartbes: http://love2d.org/wiki/AnAL
User avatar
BlackBulletIV
Inner party member
Posts: 1261
Joined: Wed Dec 29, 2010 8:19 pm
Location: Queensland, Australia
Contact:

Re: I need help about animation

Post by BlackBulletIV »

If you're talking about the tweening kind, EmmanuelOga's made a tweening library: http://love2d.org/forums/viewtopic.php?f=5&t=2502
User avatar
asurakyo
Prole
Posts: 8
Joined: Tue Mar 01, 2011 6:30 am

Re: I need help about animation

Post by asurakyo »

I can't run the example

attempt to call global 'newAnimation' (a nil value)
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: I need help about animation

Post by Robin »

asurakyo wrote:I can't run the example

attempt to call global 'newAnimation' (a nil value)
You need to download the library and require it

I think it was

Code: Select all

require "animations"
It might be "animation" instead though.
Help us help you: attach a .love.
User avatar
asurakyo
Prole
Posts: 8
Joined: Tue Mar 01, 2011 6:30 am

Re: I need help about animation

Post by asurakyo »

I didn't find "love.graphics.newAnimation()" in v0.7.1.
Look at the following code,I can not find where is wrong... :(
Or I'm missing something?

Code: Select all

function love.load()
   local img  = love.graphics.newImage("explosion.png")
   anim = newAnimation(img, 96, 96, 0.1, 0)
end

function love.update(dt)
   -- Updates the animation. (Enables frame changes)
   anim:update(dt)   
end

function love.draw()
   -- Draw the animation at (100, 100).
   anim:draw(100, 100) 
end
http://love2d.org/wiki/AnAL
User avatar
asurakyo
Prole
Posts: 8
Joined: Tue Mar 01, 2011 6:30 am

Re: I need help about animation

Post by asurakyo »

Robin wrote:
asurakyo wrote:I can't run the example

attempt to call global 'newAnimation' (a nil value)
You need to download the library and require it

I think it was

Code: Select all

require "animations"
It might be "animation" instead though.
I think no need to download any libraries
:brows:
User avatar
bartbes
Sex machine
Posts: 4946
Joined: Fri Aug 29, 2008 10:35 am
Location: The Netherlands
Contact:

Re: I need help about animation

Post by bartbes »

Yes, you do need to download AnAL, because animations are no longer a part of love.

Btw, I'd prefer it if you didn't double post.
User avatar
asurakyo
Prole
Posts: 8
Joined: Tue Mar 01, 2011 6:30 am

Re: I need help about animation

Post by asurakyo »

wow……
Problem has been solved!!!
Thanks,everybody.
:)
Post Reply

Who is online

Users browsing this forum: No registered users and 180 guests