private void DoEquipWeapons(int equipId, EquipBody dataEB, Action <bool> finished)
 {
     this.InstantiateEquipWeapon(equipId, dataEB, delegate(GameObject weapon1, GameObject weapon2)
     {
         if (this.ActorTarget == null)
         {
             this.ClearWeaponTemp(weapon1, weapon2);
             finished.Invoke(false);
             return;
         }
         if (!this.VerifyWeapon(equipId))
         {
             this.ClearWeaponTemp(weapon1, weapon2);
             finished.Invoke(false);
             return;
         }
         if (weapon1 == null)
         {
             this.ClearWeaponTemp(weapon1, weapon2);
             finished.Invoke(false);
             return;
         }
         this.ClearWeapons();
         if (weapon1 != null)
         {
             EquipCustomizationTool.SetLayer(weapon1, this.ActorTarget);
             ShadowController.SetShadowModelRender2Child(this.ActorTarget.get_transform(), weapon1.get_transform(), false);
             this.m_goWeapons.Add(weapon1);
             this.SetWeapon2Slot(this.GetWeaponSlotRealName(dataEB.slot), true);
         }
         if (weapon2 != null)
         {
             EquipCustomizationTool.SetLayer(weapon2, this.ActorTarget);
             ShadowController.SetShadowModelRender2Child(this.ActorTarget.get_transform(), weapon2.get_transform(), false);
             this.m_goWeapons.Add(weapon2);
             this.SetWeapon2Slot(this.GetWeaponSlotRealName(dataEB.slot), true);
         }
         if (finished != null)
         {
             finished.Invoke(weapon1 != null);
         }
     });
 }
 private void InstantiateEquipWing(int wingId, WingBody dataWing, Action <bool> finished)
 {
     this.GetInstantiateWing(wingId, dataWing, delegate(GameObject goInstantiate1)
     {
         if (this.ActorTarget == null)
         {
             finished.Invoke(false);
             return;
         }
         if (!this.VerifyWing(wingId))
         {
             if (goInstantiate1 != null)
             {
                 Object.Destroy(goInstantiate1);
             }
             finished.Invoke(false);
             return;
         }
         if (goInstantiate1 == null)
         {
             finished.Invoke(false);
             return;
         }
         this.ClearWing();
         if (goInstantiate1 != null)
         {
             EquipCustomizationTool.SetLayer(goInstantiate1, this.ActorTarget);
             ShadowController.SetShadowModelRender2Child(this.ActorTarget.get_transform(), goInstantiate1.get_transform(), false);
             this.m_goWing = goInstantiate1;
             this.SetWing2Slot();
         }
         if (finished != null)
         {
             finished.Invoke(goInstantiate1 != null);
         }
     });
 }