private void World_OnAdd(StatefulObject obj) { if (obj.ID == currentOwnedObject && !obj.GetComponent <IInputController>().Enabled) { obj.GetComponent <IInputController>().SetEnabled(true); } }
private void StatefulWorld_OnAdd(StatefulObject obj) { if (arbiter) { IdentifiableObject o = obj.GetComponent <IdentifiableObject>(); // Only the arbiter is permitted to relinquish an object's authority; // non-arbiter remotes will hang on to authority until they receive confirmation // from the arbiter that the object has relinquished. o.GetComponent <StatefulObject>().Ownable.CanRelinquishAuthority = true; objectsToSpawn.Add(obj.ID, o); } }