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); } } }
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); } } }
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); } } }
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(); }
public void DestroyMountPoint() { if (isDriver) { return; } if (entity.IsMounted()) { DismountPlayer(); } if (entity != null && !entity.IsDestroyed) { Destroy(entity.GetComponent <InvisibleMount>()); entity.Kill(BaseNetworkable.DestroyMode.None); } }