- Home /
Question by
jeff.fnd · Feb 07, 2014 at 05:11 PM ·
animationmultiplayernetworkphoton
Animation does not work for the remote player
Hello guys, please could someone help me, urgent.
I have problems to show the current animation for remote players, in photon.
Each player can see his own animation, but can not see the animations of the other players.
Below is a summary of the script I am using.
PhotonView > observe script SmoothMoviment.
SmoothMoviment it is ok.
--------------------------------------------------------
Script moviment:
public NetworkAnimations NetWorkAnims;
void Update ()
{
if (!photonView.isMine) return;
if (Input.GetMouseButton(0))
{
...
NetWorkAnims.RunningAnim();
}
}
--------------------------------------------------------
Script NetworkAnimations:
enum CharacterState {
Idle,
WalkingForward,
WalkingBackward,
Running,
Limping
};
public CharacterState _characterState;
public Animation target;
public void RunningAnim() {
_characterState = CharacterState.Running;
CurrentAnimation ();
}
public void CurrentAnimation() {
if (_characterState == CharacterState.Running) {
target.animation.CrossFade ("run");
}
}
--------------------------------------------------------
Please could someone help me to show animations of the other players?
I thank you very much.
Comment
Your answer
Follow this Question
Related Questions
If my game uses Photon Multiplayer, can my users host their own game? 1 Answer
Photon Cannot sync animations 2 Answers
Photon Network Muzzleflash 0 Answers
Photon IK sync 2 Answers
Send an Animation through photon network 0 Answers