Having a problem…
Code:
using UnityEngine;
using System.Collections;
public class NetworkCharacter : MonoBehaviour {
void OnPhotonSerializeView(PhotonStream stream, PhotonMessageInfo info) {
if (stream.isWriting) {
// This is OUR player
stream.SendNext(tranform.position);
stream.SendNext(tranform.rotation);
} else {
// And this is someone else's player
transform.position = (Vector3)stream.ReceiveNext();
transform.rotation = (Quaternion)stream.ReceiveNext();
}
}
}
Errors:
Assets/_SCRIPTS/NetworkCharacter.cs(9,41): error CS0103: The name `tranform' does not exist in the current context
Assets/_SCRIPTS/NetworkCharacter.cs(10,41): error CS0103: The name `tranform' does not exist in the current context
Which is in “//This is OUR player”
Script is included in my Player prefab.