Animations And LÖVE (AnAL) - The animations replacement lib
Re: Animations And LÖVE (AnAL) - The animations replacement lib
So ... Are we to assume that AnAL is compatible with LUBE?
(Sorry. Couldn't help it...)
(Sorry. Couldn't help it...)
(USER MIGHT BE BANNED FOR THIS POST.)
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: Animations And LÖVE (AnAL) - The animations replacement lib
You might want to ask your girlfriend if she's okay with anal before putting lube all over her...
Re: Animations And LÖVE (AnAL) - The animations replacement lib
Okay, I had a look over it a bit ago, and it looks pretty straightforward.
Will we need to pay attention to the power-of-two image dimensions on the anims for now as well? And, if so, will "buffer" space around a frame do the trick?
E.g., I've a character animation that's framed at 32x48. If I need to bring it in line with power-of-2, can I just reframe it to 32x64 and call it a day?
Will we need to pay attention to the power-of-two image dimensions on the anims for now as well? And, if so, will "buffer" space around a frame do the trick?
E.g., I've a character animation that's framed at 32x48. If I need to bring it in line with power-of-2, can I just reframe it to 32x64 and call it a day?
(USER MIGHT BE BANNED FOR THIS POST.)
- TechnoCat
- Inner party member
- Posts: 1611
- Joined: Thu Jul 30, 2009 12:31 am
- Location: Milwaukee, WI
- Contact:
Re: Animations And LÖVE (AnAL) - The animations replacement lib
Check the example at the bottom http://love2d.org/docs/ImageData.htmlscirath wrote:Okay, I had a look over it a bit ago, and it looks pretty straightforward.
Will we need to pay attention to the power-of-two image dimensions on the anims for now as well? And, if so, will "buffer" space around a frame do the trick?
E.g., I've a character animation that's framed at 32x48. If I need to bring it in line with power-of-2, can I just reframe it to 32x64 and call it a day?
Re: Animations And LÖVE (AnAL) - The animations replacement lib
Sweet. Thanks, TechnoCat.TechnoCat wrote:Check the example at the bottom http://love2d.org/docs/ImageData.htmlscirath wrote:Okay, I had a look over it a bit ago, and it looks pretty straightforward.
Will we need to pay attention to the power-of-two image dimensions on the anims for now as well? And, if so, will "buffer" space around a frame do the trick?
E.g., I've a character animation that's framed at 32x48. If I need to bring it in line with power-of-2, can I just reframe it to 32x64 and call it a day?
(USER MIGHT BE BANNED FOR THIS POST.)
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: Animations And LÖVE (AnAL) - The animations replacement lib
That is a good question, whether the base image or the quad needs to be power-of-two, really, the only way to find out is trying (though my guess would be the original image.)
- killerasus
- Prole
- Posts: 1
- Joined: Wed Jan 27, 2010 10:46 pm
- Location: Rio de Janeiro, Brazil
- Contact:
Re: Animations And LÖVE (AnAL) - The animations replacement lib
Hey bartbes,
I believe I found a bug in AnAL. As for checking for collisions with the border of the screen, I was using the following code
sprite is an animation created with AnAL. I was getting nil value for method getWidth and getHeight, so I decided to check what what both functions were doing
Printing the values for self.position and self.frames[self.position], I noticed that each frame is a Quad, which doesn't has a getWidth or getHeight method. I modified the methods so I could get the frame properties using Quad:getViewport()
It worked pretty neat =)
I believe I found a bug in AnAL. As for checking for collisions with the border of the screen, I was using the following code
Code: Select all
function Player:move (dt)
--Horizontal movement
if love.keyboard.isDown("right") then
if (self.position.x + (self.speed.x*dt) + self.sprite:getWidth() < love.graphics.getWidth()) then
self.position.x = self.position.x + (self.speed.x * dt)
else
self.position.x = love.graphics.getWidth() - self.sprite:getWidth()
end
...
Code: Select all
function animation:getWidth()
return self.frames[self.position]:getWidth()
end
Code: Select all
function animation:getWidth()
print(self.position)
print(self.frames[self.position])
local x, y, w, h = self.frames[self.position]:getViewport()
return w
end
- bartbes
- Sex machine
- Posts: 4946
- Joined: Fri Aug 29, 2008 10:35 am
- Location: The Netherlands
- Contact:
Re: Animations And LÖVE (AnAL) - The animations replacement lib
Yeah, I think I noticed that bug before.. but apparently I haven't done anything about it, will fix it, thanks for reporting.
-
- Prole
- Posts: 1
- Joined: Fri Jan 01, 2010 12:15 pm
Re: Animations And LÖVE (AnAL) - The animations replacement
where can I download the files? The attachment link is broken... please, I need this lib. to try these animation...
ty..
[EDITED] Sorry, i found the file
ty..
[EDITED] Sorry, i found the file
Last edited by quetzlcoatl on Thu Jun 03, 2010 4:01 pm, edited 1 time in total.
Who is online
Users browsing this forum: No registered users and 7 guests