Beispiel #1
0
 private void Update()
 {
     if (LocalPlayer.GameObject && this.WaterCollider)
     {
         CoopPlayerColliders componentInChildren = LocalPlayer.GameObject.GetComponentInChildren <CoopPlayerColliders>();
         if (componentInChildren)
         {
             foreach (Collider collider in componentInChildren.WorldCollisionColiders)
             {
                 Physics.IgnoreCollision(this.WaterCollider, collider, true);
             }
             base.enabled = false;
         }
     }
 }
Beispiel #2
0
 private void Update()
 {
     if (LocalPlayer.GameObject && this.WaterCollider)
     {
         CoopPlayerColliders componentInChildren = LocalPlayer.GameObject.GetComponentInChildren <CoopPlayerColliders>();
         if (componentInChildren)
         {
             Collider[] worldCollisionColiders = componentInChildren.WorldCollisionColiders;
             for (int i = 0; i < worldCollisionColiders.Length; i++)
             {
                 Collider collider = worldCollisionColiders[i];
                 Physics.IgnoreCollision(this.WaterCollider, collider, true);
             }
             base.enabled = false;
         }
     }
 }