New to GameSalad, got a question for you regarding controls

jgdeschampsjgdeschamps Member Posts: 3
edited August 2012 in Working with GS (Mac)
Hi, I'm Julio and I'm new to GameSalad. I've been playing around with game engines, and so far GameSalad is awesome from a former 80s and 90s video games geek POV. I have no problem creating assets and animations for a game (let it be 2D or 3D) as well as music and SFX. My problem is scripting... I'm not much of a programmer or scripter, though I'm learning (mainly because of the Unity engine for 3D stuff.) GameSalad is awesome at this, since the drag and drop logic it uses fits really well what I want to achieve. Now, to the question...

I'm trying to emulate my old favorite Genesis and SNES games with GS, and my first project is to produce side scroller brawler templates that mimic most behaviors from Streets of Rage and Final Fight. I'm stuck at a small detail that dominates most action games, let them be platform games (like Altered Beast) and of course, brawlers. Let's say you are using a keyboard key to move your character on the "right" and "left" direction. No problem here, I have accomplished these controller movements quite well, animations and all. Then you press a key to make it punch. Here comes the problem... If you remember playing with the Genesis gamepad, you'd notice that when you are going towards the "right" direction to hit a bad guy, and then punch the thug, you never stop pushing the D-pad while you punch. On a more detailed level, while you punch, the character stops moving towards the "right" direction and performs the punching animation. Once the punch is done, since you were still pressing the D-pad towards "right," the character resumes the movement towards said direction.

I CANNOT REPLICATE THIS BEHAVIOR WITH GAMESALAD! :)

It's driving me insane, because I have tried triggering the actions directly on the Player actor, and also creating Attributes for the Game to use them as triggers for the movement like the controller templates included as demos with GS. I have failed because I always get the same result: I can stop the Movement of the player towards left or right and perform the punch animation. But, I cannot resume the movement after the punch sequence is done even though I'm still pressing the necessary key towards the right or left direction.

Do you guys have any idea how I can get this to work? Thanks for your time and help.

J

Comments

  • PBEmpirePBEmpire Member Posts: 676
    edited August 2012
    email tsb.
  • jgdeschampsjgdeschamps Member Posts: 3
    Well, I've been playing a bit with other behaviors... it seems that saving to a Game Attribute the Player's Actor X position when pressing the punch key, and then constraining movement to that saved position within a Time period (which would be the punch animation sequence duration) effectively stops the character, and allows to continue the movement after the punch sequence while keeping at the same time pressed down the right or left movement button. Now I need to ease in and out the walking and punching animations 'cause I'm getting weird results...
  • UtopianGamesUtopianGames Member Posts: 5,692
    So you want to make a side scroller brawler template?

    We made one that you can look at in the marketplace
    http://marketplace.gamesalad.com/#query=utopian+games (14th one down called Double Dragon)

    I attached a very simple file to give you an idea of how to stop moving when punching.

    Darren.
  • jgdeschampsjgdeschamps Member Posts: 3
    edited August 2012
    Thank you, Darren! I'll look at it right now. :)

    EDIT: That's what I needed, a simple solution to this. Thank you again, works like a charm.
Sign In or Register to comment.