Example #1
0
 // Token: 0x06000E5F RID: 3679 RVA: 0x0003FF64 File Offset: 0x0003E164
 private void AttemptToResolveOwner()
 {
     if (this.resolved)
     {
         return;
     }
     this.resolvedOwnerGameObject = Util.FindNetworkObject(this.ownerId);
     if (!this.resolvedOwnerGameObject)
     {
         return;
     }
     this.resolved            = true;
     this.resolvedOwnerMaster = this.resolvedOwnerGameObject.GetComponent <CharacterMaster>();
     this.resolvedOwnerGameObject.AddComponent <MinionOwnership.MinionGroup.MinionGroupDestroyer>().group = this;
     this.refCount++;
     for (int i = 0; i < this._memberCount; i++)
     {
         this.members[i].HandleOwnerDiscovery(this.resolvedOwnerMaster);
     }
 }
            // Token: 0x06000EE5 RID: 3813 RVA: 0x000421E4 File Offset: 0x000403E4
            public Transform Resolve()
            {
                GameObject      gameObject      = Util.FindNetworkObject(this.parentNetworkInstanceId);
                NetworkIdentity networkIdentity = gameObject ? gameObject.GetComponent <NetworkIdentity>() : null;

                if (!networkIdentity)
                {
                    return(null);
                }
                if (this.indexInParentChildLocatorPlusOne == 0)
                {
                    return(networkIdentity.transform);
                }
                ChildLocator childLocator = NetworkParent.ParentIdentifier.LookUpChildLocator(networkIdentity.transform);

                if (childLocator)
                {
                    return(childLocator.FindChild(this.indexInParentChildLocator));
                }
                return(null);
            }