Skip to content

Commit

Permalink
Improve pluralization
Browse files Browse the repository at this point in the history
  • Loading branch information
MSWS committed Oct 25, 2024
1 parent b4e14f5 commit d208da4
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions mod/Jailbreak.RTD/Rewards/CreditReward.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,9 @@ public class CreditReward(int credits) : IRTDReward {
public static readonly string PREFIX =
$" {ChatColors.Purple}[{ChatColors.LightPurple}RTD{ChatColors.Purple}]";

public string Name => credits + " Credit";
public string Name => $"{credits} credit{(credits == 1 ? "" : "s")}";

public string Description
=> "You won " + credits + " credit" + (credits == 1 ? "" : "s")
+ (credits > 500 ? "!" : ".");
public string Description => $"You won {Name} {(credits > 500 ? "!" : ".")}";

public bool Enabled => API.Gangs != null;

Expand Down

0 comments on commit d208da4

Please sign in to comment.