How Do I Stop a Looping Gif Anim?

This forum is meant for requesting technical support or reporting bugs.

Moderators: time-killer-games, Vengeance66, Candle, reneuend, GM-Support

How Do I Stop a Looping Gif Anim?

Postby TigerBill » Wed Jul 08, 2009 4:57 pm

I'm having problems stopping the looping of a Gif Animation. After clicking on a hotspot, I want the Anim to play only once and then go to another frame. All I see in AM is the capability to continuously loop. Has anyone figured out a way to do this?
Thank you.
TigerBill
Junior Member
 
Posts: 12
Joined: Wed Jul 02, 2008 7:22 pm
Location: NJ - USA

Postby Lyberodoggy » Wed Jul 08, 2009 7:37 pm

I recommend using the Gif sequence or even better the animation maker plugin
http://www.adventuremaker.com/phpBB2/viewtopic.php?t=4868
User avatar
Lyberodoggy
Administrator
 
Posts: 2526
Joined: Sat Feb 17, 2007 3:31 pm
Location: Athens

Postby TigerBill » Thu Jul 09, 2009 12:26 am

It works. Thanks! But how can I make it go to the next frame after my anim has played?
Thanks.
TigerBill
Junior Member
 
Posts: 12
Joined: Wed Jul 02, 2008 7:22 pm
Location: NJ - USA

Postby juhuwoorps » Thu Jul 09, 2009 12:33 am

do you use Gif sequenceplayer or the animationmaker plugin?
juhuwoorps
Code Master
 
Posts: 622
Joined: Tue Jul 08, 2008 3:13 pm

Postby Lyberodoggy » Thu Jul 09, 2009 11:53 am

Code: Select all
sub gifplayer
If rep=9999 Then
Exit Sub
End If

If counter=numberofpics Then
Select Case rep
Case 0
counter=0
Case 1
RemoveTimedEvent timedindex
Case Else
rep=rep-1
counter=0
End Select
End If
If counter<numberofpics Then
counter=counter+1
End If
filename=gifname &  counter & "." & gifending
Action.LoadAPicture Hotspot(htspnr), filename
'If counter<numberofpics Then gifplayer
End Sub

this is the sub of the animation.

Code: Select all
Case 1
RemoveTimedEvent timedindex

this is executed during the last animation loop. You can modify this part by adding an integer variable and then in the last line of the sub use this syntax

if variable_name then action.gotoframe "framename"

or you can wait till I modify the plugin


EDIT: see the attachment
Attachments
AnimationMaker1_2.zip
(1.06 KiB) Downloaded 435 times
User avatar
Lyberodoggy
Administrator
 
Posts: 2526
Joined: Sat Feb 17, 2007 3:31 pm
Location: Athens

Postby juhuwoorps » Thu Jul 09, 2009 8:44 pm

I know Lybero was a bit faster as I, but here's another version of Animationmaker.
It allows you to go to another frame after playing the animation.
It also allows to play the animation backwards or only a few pictures of the animation.

Hope it helps!
Attachments
revers_animation2.zip
(616 Bytes) Downloaded 449 times
juhuwoorps
Code Master
 
Posts: 622
Joined: Tue Jul 08, 2008 3:13 pm

Postby TigerBill » Fri Jul 10, 2009 4:42 pm

Thanks Lyberodoggy and juhuwoorps! Greatly appreciated!

I tried your approach first, juhuwoorps, but here's what happens: My animation won't play at all. I assume that your plugin works on a hotspot, correct?

I also don't see an option in your plugin to set the amount of time for each frame to display? Am I missing something?

Thank you.
TigerBill
Junior Member
 
Posts: 12
Joined: Wed Jul 02, 2008 7:22 pm
Location: NJ - USA

Postby mercedes » Fri Jul 10, 2009 7:41 pm

Hi there..:D

In order to use any Animation Sequence player..be it the Animation Maker or Gif Sequence Player...You first have to separate all of the layers..in the animation..and name them accordingly..

For instance, Layer1,Layer2 ect..or...frame1,frame2--whatever you want, but make sure it follows a sequence~

Then once u put all layers in the EXTERNAL folder of your project--You set the INDEX--that being ''Layer'' and or ''Frame''--and the amount of layers that are actually in the animation---Where it says Number of Files~

Then put the first layer in the hotspot, and test the frame..--It should play automatically..

Is this how u did it..?
User avatar
mercedes
VIP
 
Posts: 2460
Joined: Sun Mar 09, 2008 10:43 pm
Location: Canada..~

Postby TigerBill » Fri Jul 10, 2009 8:33 pm

Yes, I did all of that but the animation doesn't play when I try to use the revers-animation2 plugin suggested by Juhuwoorps. Although it does play when I use the animation maker plugin - however that plugin does not do what I need to do.

The revers-animation2 plugin would solve all my problems if I could only get it to work.
TigerBill
Junior Member
 
Posts: 12
Joined: Wed Jul 02, 2008 7:22 pm
Location: NJ - USA

Postby mercedes » Sat Jul 11, 2009 1:28 pm

You only want it to go to another frame right.-- after animation has played-once..?
I thought there was an option in animation maker-1 for it to play only once..
Did u change your strategy..were u trying something different now..
Why the reverse plugin...

Also, have you tried Lyberodoggy's..? If so, what was wrong with it..?

Perhaps both need further tweeking..I'm sure one of them will be along to answer this for you..:)
User avatar
mercedes
VIP
 
Posts: 2460
Joined: Sun Mar 09, 2008 10:43 pm
Location: Canada..~

Postby Lyberodoggy » Sun Jul 12, 2009 3:53 pm

I tested mine for quite some time before posting, it should work
User avatar
Lyberodoggy
Administrator
 
Posts: 2526
Joined: Sat Feb 17, 2007 3:31 pm
Location: Athens

Postby TigerBill » Mon Jul 13, 2009 7:41 pm

I haven't tried yours' yet, Lyberodoggy, because I could really use the ability to play anims in reverse, which is supposed to be a feature of the revers-anim plugin.

I will try your version and let you know if I can get it to work.

Thanks.
TigerBill
Junior Member
 
Posts: 12
Joined: Wed Jul 02, 2008 7:22 pm
Location: NJ - USA

Postby Lyberodoggy » Mon Jul 13, 2009 9:26 pm

I added a reverse feature for you ;)
Attachments
AnimationMaker1_3.zip
(1.14 KiB) Downloaded 445 times
User avatar
Lyberodoggy
Administrator
 
Posts: 2526
Joined: Sat Feb 17, 2007 3:31 pm
Location: Athens

Postby TigerBill » Tue Jul 14, 2009 4:16 pm

Hey Lyberodoggy! Success! Your latest plugin works great!
Thank you so much for updating it for me, it's exactly what I need.

You're the best! 8)
TigerBill
Junior Member
 
Posts: 12
Joined: Wed Jul 02, 2008 7:22 pm
Location: NJ - USA

Postby Lyberodoggy » Wed Jul 15, 2009 11:35 am

No problem :D (Actually it's rewarding to see code I 've worked on being used by others)
User avatar
Lyberodoggy
Administrator
 
Posts: 2526
Joined: Sat Feb 17, 2007 3:31 pm
Location: Athens


Return to Adventure Maker Technical Support and Bug Reports

Who is online

Users browsing this forum: No registered users and 0 guests

cron