示例#1
0
    private void OnDisable()
    {
        base.CancelInvoke("updatePlayerTargets");
        FMODCommon.UnloadEvents(new string[]
        {
            this.dieEvent,
            this.sharkAttackEvent
        });
        if (this.MyTrigger)
        {
            this.MyTrigger.SetActive(false);
        }
        destroyAfter component = base.transform.GetComponent <destroyAfter>();

        if (component)
        {
            component.enabled = false;
        }
        if (this.rb)
        {
            this.rb.useGravity  = false;
            this.rb.isKinematic = true;
            this.spearedBool    = false;
        }
        if (this.col)
        {
            this.col.isTrigger = true;
            this.col.enabled   = true;
        }
        this.Dead     = false;
        this.exploded = false;
        base.CancelInvoke("enableGrabTrigger");
    }
 private void OnDisable()
 {
     if (this.hasPreloaded)
     {
         FMODCommon.UnloadEvents(new string[]
         {
             this.addItemEvent
         });
         this.hasPreloaded = false;
     }
 }
示例#3
0
 private void disablePlaneCrash()
 {
     WorkScheduler.ShouldDoFullCycle = true;
     Scene.WorkScheduler.gameObject.SetActive(true);
     Clock.planecrash = false;
     Scene.MutantControler.startSetupFamilies();
     Scene.HudGui.ShowHud(true);
     if (this.hasPreloadedEvents)
     {
         FMODCommon.UnloadEvents(this.preloadEvents);
     }
     base.transform.parent = null;
 }
示例#4
0
 private void OnDisable()
 {
     if (this.hasPreloaded)
     {
         FMODCommon.UnloadEvents(new string[]
         {
             this.weaponHitEvent,
             this.parryEvent,
             this.blockEvent,
             this.shellBlockEvent
         });
         this.hasPreloaded = false;
     }
 }
示例#5
0
 private void OnDisable()
 {
     if (this.hasPreloaded)
     {
         FMODCommon.UnloadEvents(new string[]
         {
             this.addItemEvent
         });
         this.hasPreloaded = false;
     }
     if (Scene.HudGui)
     {
         Scene.HudGui.HolderWidgets[(int)this._type].ShutDown();
     }
 }
示例#6
0
 private void OnDisable()
 {
     if (Scene.HudGui)
     {
         this.Widget.Shutdown();
     }
     if (this.hasPreloaded)
     {
         FMODCommon.UnloadEvents(new string[]
         {
             this.addFuelEvent
         });
         this.hasPreloaded = false;
     }
 }
示例#7
0
 private void OnDisable()
 {
     if (!this.initBool)
     {
         return;
     }
     base.CancelInvoke("groundHeightCheck");
     this.fleeing = false;
     base.StopAllCoroutines();
     this.StopEvents();
     FMODCommon.UnloadEvents(this.AllEventPaths());
     this.flyAwayCoolDown = false;
     this.flying          = false;
     this.landing         = false;
     this.onGround        = false;
     this.idle            = false;
 }
示例#8
0
 private void OnDisable()
 {
     if (this.slideEventInstance != null)
     {
         this.StopSlideEvent();
         base.CancelInvoke("StopSlideEvent");
     }
     if (this.hasPreloaded)
     {
         FMODCommon.UnloadEvents(new string[]
         {
             this.impactEvent,
             this.slideEvent
         });
         this.hasPreloaded = false;
     }
 }
示例#9
0
 private void OnDisable()
 {
     if (this.slideEventInstance != null)
     {
         this.StopSlideEvent();
         base.CancelInvoke("StopSlideEvent");
     }
     if (this.hasPreloaded && !CoopPeerStarter.DedicatedHost)
     {
         FMODCommon.UnloadEvents(new string[]
         {
             this.impactEvent,
             this.slideEvent
         });
         this.hasPreloaded = false;
     }
     this.slideObjects.Clear();
 }
示例#10
0
 private void OnDisable()
 {
     FMODCommon.UnloadEvents(this.AllEventPaths());
 }