예제 #1
0
 public virtual void CheckSeatsForClipping(int mask)
 {
     foreach (MountPointInfo mountPoint in mountPoints)
     {
         BaseMountable mountable = mountPoint.mountable;
         if (!(mountable == null) && mountable.IsMounted() && IsSeatClipping(mountable, mask))
         {
             SeatClippedWorld(mountable);
         }
     }
 }
예제 #2
0
 public virtual void CheckSeatsForClipping()
 {
     foreach (BaseVehicle.MountPointInfo mountPoint in this.mountPoints)
     {
         BaseMountable mountable = mountPoint.mountable;
         if (!Object.op_Equality((Object)mountable, (Object)null) && mountable.IsMounted() && this.IsSeatClipping(mountable, 1210122497))
         {
             this.SeatClippedWorld(mountable);
         }
     }
 }
예제 #3
0
 public virtual void CheckSeatsForClipping()
 {
     BaseVehicle.MountPointInfo[] mountPointInfoArray = this.mountPoints;
     for (int i = 0; i < (int)mountPointInfoArray.Length; i++)
     {
         BaseMountable baseMountable = mountPointInfoArray[i].mountable;
         if (!(baseMountable == null) && baseMountable.IsMounted() && this.IsSeatClipping(baseMountable, 1210122497))
         {
             this.SeatClippedWorld(baseMountable);
         }
     }
 }
예제 #4
0
 private void Update()
 {
     if (!mountable.IsMounted())
     {
         return;
     }
     transform.rotation = Quaternion.Lerp(transform.rotation, Quaternion.LookRotation(player.eyes.HeadForward()), UnityEngine.Time.deltaTime);
     if (player.serverInput.IsDown(BUTTON.FORWARD))
     {
         transform.position = Vector3.MoveTowards(transform.position, player.eyes.HeadForward(), UnityEngine.Time.deltaTime * 0.1f);
     }
     chair.SendNetworkUpdateImmediate();
     ent.SendNetworkUpdateImmediate();
 }
예제 #5
0
                public void DestroyMountPoint()
                {
                    if (isDriver)
                    {
                        return;
                    }

                    if (entity.IsMounted())
                    {
                        DismountPlayer();
                    }

                    if (entity != null && !entity.IsDestroyed)
                    {
                        Destroy(entity.GetComponent <InvisibleMount>());
                        entity.Kill(BaseNetworkable.DestroyMode.None);
                    }
                }