/// <summary> /// Initializes a new instance of the <see cref="PlayerTextLabel" /> class. /// </summary> /// <param name="owner">The owner.</param> /// <param name="text">The text.</param> /// <param name="color">The color.</param> /// <param name="position">The position.</param> /// <param name="drawDistance">The draw distance.</param> /// <param name="testLOS">if set to <c>true</c> [test los].</param> /// <param name="attachedVehicle">The attached vehicle.</param> /// <exception cref="System.ArgumentNullException"> /// owner /// or /// attachedVehicle /// </exception> public PlayerTextLabel(BasePlayer owner, string text, Color color, Vector3 position, float drawDistance, bool testLOS, BaseVehicle attachedVehicle) { if (owner == null) { throw new ArgumentNullException(nameof(owner)); } if (attachedVehicle == null) { throw new ArgumentNullException(nameof(attachedVehicle)); } Owner = owner; _color = color; _position = position; _drawDistance = drawDistance; _testLOS = testLOS; Id = Internal.CreatePlayer3DTextLabel(owner.Id, text, color, position.X, position.Y, position.Z, drawDistance, BasePlayer.InvalidId, attachedVehicle.Id, testLOS); }
/// <summary> /// Initializes a new instance of the <see cref="PlayerTextLabel" /> class. /// </summary> /// <param name="owner">The owner.</param> /// <param name="text">The text.</param> /// <param name="color">The color.</param> /// <param name="position">The position.</param> /// <param name="drawDistance">The draw distance.</param> /// <param name="attachedVehicle">The attached vehicle.</param> public PlayerTextLabel(BasePlayer owner, string text, Color color, Vector3 position, float drawDistance, BaseVehicle attachedVehicle) : this(owner, text, color, position, drawDistance, true, attachedVehicle) { }