User Tag List

Page 1 of 2 1 2 LastLast
Results 1 to 10 of 16

Thread: specific animation has played a specific frame?

  1. #1
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export ModuleUnicode Add-on
    mobichan's Avatar
    Join Date
    Oct 2007
    Location
    Buffalo, NY
    Posts
    3,310
    Mentioned
    28 Post(s)
    Tagged
    0 Thread(s)

    specific animation has played a specific frame?

    I am trying to determine if there is a condition to see if a specific animation has reached a specific frame? I am guessing I can use the expression calculator under "Compare current frame of XXX to a value" but I don't know the syntax for defining the animation by name. Anyone know if this is possible?

    I am trying to make an enemy perform an action on a specific frame of an animation.

  2. #2
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export ModuleUnicode Add-on
    mobichan's Avatar
    Join Date
    Oct 2007
    Location
    Buffalo, NY
    Posts
    3,310
    Mentioned
    28 Post(s)
    Tagged
    0 Thread(s)

    Re: specific animation has played a specific frame?

    I'm an idiot. I figured it out.

    But now I am stumped as to how I would make an animation repeat within a fastloop. I am trying something like this:

    (On loop)
    +set ID(Enemy) to Loop Index
    +Is AltVar for Bullet Firing offset <= 0?
    +Is animation "Shooting" playing?
    +Is the frame # = 4
    --->Create Bullet
    --->(Bullet)Set Bullet Movement
    --->(Bullet)Set Bullet Direction
    --->(Bullet)Set AltVar for Bullet Firing offset to 25
    --->(Enemy)Add 1 to Bullets Fired
    --->(Enemy)Change Animation Sequence to Shooting

    Basically, I want the Shooting animation to repeat every time the Bullet Firing offset reaches zero. I thought that setting the animation to Shooting as the last part of the sequence would do it, but it only plays the animation once and then holds the last frame while it shoots out the bullets every 25 loops.

    Any ideas how I might fix this?

    Mobichan

  3. #3
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export ModuleUnicode Add-on
    mobichan's Avatar
    Join Date
    Oct 2007
    Location
    Buffalo, NY
    Posts
    3,310
    Mentioned
    28 Post(s)
    Tagged
    0 Thread(s)

    Re: specific animation has played a specific frame?

    The above example seems to just play the Shooting animation once, then it automatically goes to the Stopped animation. Then it continues to spawn the bullets, but fails to repeat the shooting animation over and over. I was trying to use the "Change animation to Shooting" action to accomplish this, but the game seems to ignore it. Any ideas why?

  4. #4
    RayMarble
    Guest

    Re: specific animation has played a specific frame?

    Dumb question, but did you check you have the anims set correctly (the actual animation of shooting in the "shooting" and not in the "walking" or something)? Happened to me once. o^_^o;

  5. #5
    No Products Registered

    Join Date
    Oct 2006
    Posts
    34
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: specific animation has played a specific frame?

    Well, this looks kinda odd to me...

    +Is animation "Shooting" playing?
    --->(Enemy)Change Animation Sequence to Shooting

  6. #6
    No Products Registered

    Join Date
    Oct 2006
    Location
    Sweden
    Posts
    1,141
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: specific animation has played a specific frame?

    Try Resetting the animation before you start it again, sometimes if you start an animation the moment it has ended it gets stuck at the last frame...

  7. #7
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export ModuleUnicode Add-on
    mobichan's Avatar
    Join Date
    Oct 2007
    Location
    Buffalo, NY
    Posts
    3,310
    Mentioned
    28 Post(s)
    Tagged
    0 Thread(s)

    Re: specific animation has played a specific frame?

    Werbad: it is getting stuck on the last frame. But I don't know how to "reset" an animation within a fastloop. I thought every time it ran the loop, it would play the animation over and over when the condition is met. That is why I have the last action as "Change animation to Shooting."

    It just seems to play the animation once, then continue the fastloop actions for spawning my bullets. I have the bullets working off a countdown on an alt var, so when it reaches 0, the bullet fires. Then it resets the counter and repeats until the total bullet count reaches a number. I basically wanted to reset the shooting animation every time the countdown reaches 0, but I guess my code isn't correct.

    Ideally, I want the bullets to actually fire off when the countdown reaches zero AND when the animation is at a specific frame (frame 4, in this case). Then I want the shooting animation to repeat each time the fastloop countdown reaches 0 until the total number of bullets I have specified have reached a value.

    I'm starting to confuse myself with this one. ^_^' Which Animation action would be ideal for resetting an animation? Or is the problem that I am trying to reset the action on the same line as the call to play it?

  8. #8
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export ModuleUnicode Add-on
    mobichan's Avatar
    Join Date
    Oct 2007
    Location
    Buffalo, NY
    Posts
    3,310
    Mentioned
    28 Post(s)
    Tagged
    0 Thread(s)

    Re: specific animation has played a specific frame?

    Here is the file in case anyone has time to take a look.
    current project file

    You can generate the enemy that uses the behavior I am working on with the RIGHT mouse button.

  9. #9
    Clicker

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export ModuleUnicode Add-on
    mobichan's Avatar
    Join Date
    Oct 2007
    Location
    Buffalo, NY
    Posts
    3,310
    Mentioned
    28 Post(s)
    Tagged
    0 Thread(s)

    Re: specific animation has played a specific frame?

    bump...

  10. #10
    Clickteam Clickteam
    Olivier's Avatar
    Join Date
    Jun 2006
    Posts
    3,000
    Mentioned
    9 Post(s)
    Tagged
    1 Thread(s)

    Re: specific animation has played a specific frame?

    I took a look at your file but was not able to find a solution, maybe it's because there is too much code. But I know that there is a solution.
    What I suggest you is to provide us with a stripped down version of your eventing. Then it will be easier for us to find the problem.

    Also I noticed that at many places you are using loops where there's really no need to.

    BTW nice graphics!

Page 1 of 2 1 2 LastLast

Similar Threads

  1. How to run game from specific frame?
    By J3sseM in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 11th July 2013, 07:40 AM
  2. Scale a specific frame?
    By WhiteEyeDesign in forum Android Export Module Version 2.0
    Replies: 3
    Last Post: 17th April 2013, 11:48 AM
  3. How do you keep an animation once it has played?
    By RetroRain in forum Multimedia Fusion 2 - Technical Support
    Replies: 1
    Last Post: 18th January 2011, 04:58 AM
  4. Goto specific frame when player leaves area
    By Worf in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 4th December 2009, 01:07 PM
  5. Need some help (sorry cant be more specific)
    By SEELE in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 16th May 2008, 09:22 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •