void Start() { inputBuffer = new List<predictionStruct>(); cam = GameObject.FindGameObjectWithTag("MainCamera").GetComponent<OmniCamera>(); inventoryManager = GameObject.FindGameObjectWithTag("Inv").GetComponent<OmniInventory>(); lastPos = Vector3.zero; instance = this; }
void OnEnable() { Network.natFacilitatorIP = "jessewatson.org"; MasterServer.ipAddress = "jessewatson.org"; Application.runInBackground = true; instance = this; SpawnPoints = new List<Vector2>(); SpawnedObjectsNew = new List<OmniObject>(); openSlots = new List<int>(); eventManager = GameObject.FindGameObjectWithTag("GameController").GetComponent<OmniEvents>(); networkManager = GetComponent<OmniNetwork>(); localManager = GetComponent<OmniLocal>(); physTest = GetComponent<Rigidbody2D>(); netView = networkManager.networkView; }