Skip to content

Commit

Permalink
Update HumanoidCharacterProfile.cs (#268)
Browse files Browse the repository at this point in the history
  • Loading branch information
Evgencheg authored Oct 13, 2024
1 parent 2a31fe7 commit cf89702
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions Content.Shared/Preferences/HumanoidCharacterProfile.cs
Original file line number Diff line number Diff line change
Expand Up @@ -643,10 +643,14 @@ IDependencyCollection collection
{
name = GetName(Species, gender);
}

var customspeciename = speciesPrototype.CustomName
? FormattedMessage.RemoveMarkup(Customspeciename ?? "")[..MaxNameLength]
: "";

var customspeciename =
!speciesPrototype.CustomName
|| string.IsNullOrEmpty(Customspeciename)
? ""
: Customspeciename.Length > MaxNameLength
? FormattedMessage.RemoveMarkup(Customspeciename)[..MaxNameLength]
: FormattedMessage.RemoveMarkup(Customspeciename);

string flavortext;
if (FlavorText.Length > MaxDescLength)
Expand Down

0 comments on commit cf89702

Please sign in to comment.