Animation drawing

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
incognito54
Prole
Posts: 2
Joined: Wed Feb 27, 2008 12:11 pm

Animation drawing

Post by incognito54 »

Hey!

I've been trying love for the past few days (one has got to do something in the work breaks) and I can't seem to find a way to draw an animation inverted in relation to the Yy axis. Do I have to have separate animations for left/right facing character?

Thank you!
User avatar
mike
Administrator
Posts: 364
Joined: Mon Feb 04, 2008 5:24 pm

Re: Animation drawing

Post by mike »

Ah yes, we have discussed this but the idea passed from our minds a long time ago.. not sure if we have any plans of implementing this anytime soon. Do we, rude?
Now posting IN STEREO (where available)
User avatar
rude
Administrator
Posts: 1052
Joined: Mon Feb 04, 2008 3:58 pm
Location: Oslo, Norway

Re: Animation drawing

Post by rude »

Hello, and welcome. 8-)

That is only a matter of scaling with negative values ... or a least I thought so until I tried it. The sprite has a horrible tendency to disappear when one value is negative and not the other. Great. ^^

Code: Select all

function draw()
  -- This was supposed to work.
  love.graphics:draw(anim, x, y, 0, -1, 1)
end
It will be fixed in 0.2.1, of course, but until then you'll have to use separate animations for left/right.
incognito54
Prole
Posts: 2
Joined: Wed Feb 27, 2008 12:11 pm

Re: Animation drawing

Post by incognito54 »

Yeah,I tried that -1 trick before posting. :P
Glad I pointed out a valid bug! LOVE is really fun to toy with
User avatar
rude
Administrator
Posts: 1052
Joined: Mon Feb 04, 2008 3:58 pm
Location: Oslo, Norway

Re: Animation drawing

Post by rude »

incognito54 wrote:Glad I pointed out a valid bug!
It's really helpful. ^^

I remember testing negative scaling just before the 0.2.0 release, but I obviously forgot to test it with only one negative value.
User avatar
Merkoth
Party member
Posts: 186
Joined: Mon Feb 04, 2008 11:43 pm
Location: Buenos Aires, Argentina

Re: Animation drawing

Post by Merkoth »

Oh, and here you will find tons of rpgmaker sprites, backgrounds and stuff you can happily use without rpgmaker.

And rude, Everything doesn't seem to have any moderators, maybe you just need to assign yourself as one.
User avatar
rude
Administrator
Posts: 1052
Joined: Mon Feb 04, 2008 3:58 pm
Location: Oslo, Norway

Re: Animation drawing

Post by rude »

Fleg figured it out. Needed to set rights on the Administrators group.
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 16 guests