Ejemplo n.º 1
0
    protected override void OnAddonAwake()
    {
        singleton = this;
        CharacterContextProbeTrait trait = base.GetTrait <CharacterContextProbeTrait>();

        this.raycastLength = trait.rayLength;
    }
Ejemplo n.º 2
0
 protected override void OnControlEngauge()
 {
     base.OnControlEngauge();
     if (base.localControlled)
     {
         CameraMount componentInChildren = base.GetComponentInChildren <CameraMount>();
         if (componentInChildren != null)
         {
             componentInChildren.open = true;
         }
         this.contextProbe   = (this.contextProbe == null) ? base.AddAddon <ContextProbe>() : this.contextProbe;
         this.localRadiation = (this.localRadiation == null) ? base.AddAddon <LocalRadiationEffect>() : this.localRadiation;
         if (this.onceEngaged)
         {
             if (this.proxyTest != null)
             {
                 this.proxyTest.treatAsProxy = false;
             }
         }
         else
         {
             this.proxyTest   = base.GetComponent <PlayerProxyTest>();
             this.onceEngaged = true;
         }
         base.enabled = true;
     }
 }
Ejemplo n.º 3
0
 protected override void OnWillRemoveAddon()
 {
     if (singleton == this)
     {
         singleton = null;
     }
     this.hasHighlight     = false;
     this.lastUseHighlight = null;
 }
Ejemplo n.º 4
0
 protected override void OnWillRemoveAddon()
 {
     if (ContextProbe.singleton == this)
     {
         ContextProbe.singleton = null;
     }
     this.hasHighlight = false;
     this.lastUseHighlight = null;
 }
Ejemplo n.º 5
0
 protected override void OnAddonAwake()
 {
     ContextProbe.singleton = this;
     this.raycastLength = base.GetTrait<CharacterContextProbeTrait>().rayLength;
 }
Ejemplo n.º 6
0
 protected override void OnControlEngauge()
 {
     base.OnControlEngauge();
     if (base.localControlled)
     {
         CameraMount componentInChildren = base.GetComponentInChildren<CameraMount>();
         if (componentInChildren)
         {
             componentInChildren.open = true;
         }
         this.contextProbe = (!this.contextProbe ? base.AddAddon<ContextProbe>() : this.contextProbe);
         this.localRadiation = (!this.localRadiation ? base.AddAddon<LocalRadiationEffect>() : this.localRadiation);
         if (!this.onceEngaged)
         {
             this.proxyTest = base.GetComponent<PlayerProxyTest>();
             this.onceEngaged = true;
         }
         else if (this.proxyTest)
         {
             this.proxyTest.treatAsProxy = false;
         }
         base.enabled = true;
     }
 }