User Tag List

Results 1 to 3 of 3

Thread: Guns firing and character walking at the same time

  1. #1
    No Products Registered

    Join Date
    Aug 2008
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Guns firing and character walking at the same time

    I want my character to be able to walk and fire his gun at the same time, which seems simple. But I want his gun to kick, and have the slide pull back whenever you fire, without him breaking stride.

    This presents a problem because there's no way to know what frame of the stride you're going to be on when the player fires the weapon.

    So my first solution was to have a second walk animation where the guys hands are in the air as if he's holding the gun, (I can live without his body reacting to the kick of the gun for now.) Then I had another object which would be the gun and it's animations. So whenever you press fire while you're walking, the gun will kick up, the slide comes back, bullet is created at a position relative to the gun object.

    The trick is, I have the gun repositioned based on the frame that the walk cycle is in.

    The problem is it's not working out so well. I think my numbers are solid, I went into the object editor, zoomed in as far as I could and drew graph lines from point to point and counted the distance through x and y. I played it in the game. The gun is indeed moving each frame, but all around the guy's hand. And I'm wondering if maybe the computer just can't keep up with the animation. Should this be done with a fast loop? Or is there a much smarter hassle free way to do this with even better results?

  2. #2
    Clicker

    Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    DaveC's Avatar
    Join Date
    Jun 2007
    Location
    Perth, Australia
    Posts
    2,132
    Mentioned
    16 Post(s)
    Tagged
    0 Thread(s)

    Re: Guns firing and character walking at the same time

    have the entire upper body separated from the legs? i think this is how it works in a game like Contra for example. when the player shoots you can play a shoot animation on the upper body while the legs are still moving independently.

    using built in movements i used to have trouble with 2 objects following each other perfectly, but making custom movements seems to get rid of that problem.

  3. #3
    No Products Registered

    Join Date
    Aug 2008
    Posts
    11
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Guns firing and character walking at the same time

    I'm using the custom movement from the fast loop tutorial on this site. I'm going to do some experiments with the upper body like you said with some simpler objects. Game is getting pretty complicated, could be other forces at work here, lol.

    If anyone else reads this, more advice is very welcome.

    EDIT:

    I feel silly. Now that I've given it a bit of thought, having the upper body as a second object instead of starting at the guns would allow me to not only animate the body reacting to the shot, but I wouldn't even have to mess with nudging it on every frame through coding. Pft, lawl.

Similar Threads

  1. firing issues
    By pyrothos in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 22nd January 2012, 05:33 AM
  2. Walking sound only when walking
    By delta9857 in forum The Games Factory 2 - Technical Support
    Replies: 7
    Last Post: 26th November 2010, 01:47 PM
  3. Help with getting character Walking Moving,
    By Worf in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 8th December 2009, 02:21 PM
  4. character animating walking but not going anywhere
    By Xilodragon1 in forum Multimedia Fusion 2 - Technical Support
    Replies: 10
    Last Post: 9th June 2009, 11:29 PM
  5. Adding text one character at a time
    By Mantis in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 14th February 2007, 02:28 PM

Posting Permissions

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