Skip to content

Commit

Permalink
remove parse float
Browse files Browse the repository at this point in the history
  • Loading branch information
eugene-doobu committed Dec 3, 2024
1 parent 531bd83 commit 7c19a07
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 13 deletions.
2 changes: 1 addition & 1 deletion Lib9c/TableData/Character/CharacterSheet.cs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public override void Set(IReadOnlyList<string> fields)
RunSpeed = TryParseFloat(fields[16], out var runSpeed) ? runSpeed : 1f;
}
}

public CharacterSheet() : base(nameof(CharacterSheet))
{
}
Expand Down
12 changes: 0 additions & 12 deletions Lib9c/TableData/TableExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -45,18 +45,6 @@ public static decimal ParseDecimal(string value)
public static decimal ParseDecimal(string value, decimal defaultValue) =>
TryParseDecimal(value, out var result) ? result : defaultValue;

public static float ParseFloat(string value)
{
if (TryParseFloat(value, out var result))
{
return result;
}
throw new ArgumentException(value);
}

public static float ParseFloat(string value, float defaultValue) =>
TryParseFloat(value, out var result) ? result : defaultValue;

public static long ParseLong(string value)
{
if (TryParseLong(value, out var result))
Expand Down

0 comments on commit 7c19a07

Please sign in to comment.