playMaker

Author Topic: Movement (SOLVED)  (Read 2120 times)

gozda

  • Junior Playmaker
  • **
  • Posts: 88
Movement (SOLVED)
« on: November 03, 2014, 04:24:51 PM »
I already create a simple Player movement. He follow the mouse click and he got connected working NavMesh. My problem is that, that i dont know how to play and stop animations when he change status. I tried connect animations depending of his speed, but also i cant get speed information from 3rd person(constructor).
Anyone know how to play animations depending of his status?
For simple:
when speed 0 - play stay animation
when speed >0<4 - play walk animation
when speed >0 - run..

Thanks for help.
« Last Edit: November 05, 2014, 02:42:30 AM by gozda »

Lane

  • Administrator
  • Hero Member
  • *****
  • Posts: 2511
  • Mender of the past
    • Cleverous
Re: Movement
« Reply #1 on: November 03, 2014, 04:31:12 PM »
Mecanim is great for this, have you looked into it?
Products by Cleverous
|| Vault Core : Database
|| Vault Inventory : Multiplayer Inventory
|| Vault Attributes : Character Stats
|| That Hurt! : Dmg Floaties
|| Quinn : 3D

gozda

  • Junior Playmaker
  • **
  • Posts: 88
Re: Movement
« Reply #2 on: November 03, 2014, 04:48:36 PM »
I didnt try mecanim, also i dont know how use it.
I use constructor from Standard Asset and he got already animations. Just dont know how to stop animations. I've created a new FSM for animations like this
and trying do the same, getting speed information and play animations depending of his speed, but i cant get speed information and tried many differend ways to play animation, when animation of walk play it was looped and dont know how to stop it or change animation.


gozda

  • Junior Playmaker
  • **
  • Posts: 88
Re: Movement
« Reply #3 on: November 05, 2014, 02:42:14 AM »
Finally i find answer for this. Its simple need to Get Property of NavMeshAgent and select velocity.magnitude next store this in global variables. Work fine