playMaker

Author Topic: [solved] Get Axis & Get Axis Vetor not working?  (Read 7250 times)

LordyLordyLordy

  • Playmaker Newbie
  • *
  • Posts: 5
[solved] Get Axis & Get Axis Vetor not working?
« on: April 12, 2011, 01:49:24 PM »
I am working on building a third person camera.  If you help me out, I will post my solution to the forums when I'm done.  

I need to pull the speed that the mouse is moving to the left or right and adjust accordingly.  I have tried both Get Axis and Get Axis Vector.  Both return zero and the execution of the state totally freezes on that Action.  The debug values print out once and don't print again.



« Last Edit: April 15, 2011, 04:16:18 PM by alexchouls »

MaDDoX

  • 1.2 Beta
  • Full Member
  • *
  • Posts: 165
    • FluidPlay Studios
Re: Get Axis & Get Axis Vetor not working?
« Reply #1 on: April 12, 2011, 04:23:11 PM »
Did you toggle "every frame"? If you don't it only executes once.
--
Breno "MaDDoX" Azevedo
@brenoazevedo

LordyLordyLordy

  • Playmaker Newbie
  • *
  • Posts: 5
Re: Get Axis & Get Axis Vetor not working?
« Reply #2 on: April 12, 2011, 04:52:24 PM »
I'm feeling totally stupid here but where is that flag set for those actions?  Thanks for the help.

elvis75k

  • Beta Group
  • Junior Playmaker
  • *
  • Posts: 97
    • nRender
Re: Get Axis & Get Axis Vetor not working?
« Reply #3 on: April 13, 2011, 07:49:21 AM »
Quote
I'm feeling totally stupid here but where is that flag set for those actions?  Thanks for the help.
You can find every frame on almost every math action. I guess you can use > set fsm vector3 to modify vector3 every frame.

MaDDoX

  • 1.2 Beta
  • Full Member
  • *
  • Posts: 165
    • FluidPlay Studios
Re: Get Axis & Get Axis Vetor not working?
« Reply #4 on: April 13, 2011, 08:29:23 AM »
Quote
I'm feeling totally stupid here but where is that flag set for those actions?  Thanks for the help.
I got your point, I haven't double checked the action, my bad. Get Axis really doesn't have any "every frame" toggle, so to make it execute every frame simply add a default "finished" transition to the state and point it back to the same state. This will make it loop indefinitely. To break out of the loop, you can either have a logic conditional action (eg.: boolcompare pause=1) which branches to another state, or you can disable/pause the whole controller FSM from another master/gameflow FSM (https://hutonggames.fogbugz.com/default.asp?W55).

The second is a more robust approach imo.
--
Breno "MaDDoX" Azevedo
@brenoazevedo

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3987
  • Official Playmaker Support
    • LinkedIn
Re: Get Axis & Get Axis Vetor not working?
« Reply #5 on: April 13, 2011, 04:45:41 PM »
Actually most Input actions don't have an EveryFrame option because it's implicit in their function - they either wait for or get continuous input, so they run every frame automatically (you don't need to loop it). Hint: When running the game, if an action is active its name is highlighted green, if/when it finishes, it dims out. I'll also add some clarification about Input and EveryFrame to the docs...

LordyLordyLordy

  • Playmaker Newbie
  • *
  • Posts: 5
Re: Get Axis & Get Axis Vetor not working?
« Reply #6 on: April 14, 2011, 03:11:19 PM »
Thanks for all the help.  I was able to figure it out.  PlayMaker still requires a solid understanding of what is happening underneath the hood in Unity.  This keep the barrier high when learning the technology but smooths out workflow later on.  My team and I are still new to the tech.  Deprogramming our Unreal wiring is taking some time.  You help on the forums is super helpful.

Alex Chouls

  • Administrator
  • Hero Member
  • *****
  • Posts: 3987
  • Official Playmaker Support
    • LinkedIn
Re: Get Axis & Get Axis Vetor not working?
« Reply #7 on: April 15, 2011, 04:10:15 PM »
Yeah, it definitely helps to understand how Unity does things. I try to respect how Unity works, so if you're already familiar with it things "just work" the way you'd expect. I want to make more training videos that show how to use Playmaker while also introducing Unity concepts. I think that will help.