fix(core): Updates slice with range selectors (#583)
- [X] Replaces Span slicing with range selection - [X] Replaces string slicing with range selection
This commit is contained in:
parent
9f9d990f85
commit
a0893b68c0
62 changed files with 363 additions and 382 deletions
|
|
@ -678,10 +678,10 @@ namespace Server.Gumps
|
|||
{
|
||||
if (t == typeof(ulong) || t == typeof(uint) || t == typeof(ushort) || t == typeof(byte))
|
||||
{
|
||||
return Convert.ChangeType(Convert.ToUInt64(s.Substring(2), 16), t);
|
||||
return Convert.ChangeType(Convert.ToUInt64(s[2..], 16), t);
|
||||
}
|
||||
|
||||
return Convert.ChangeType(Convert.ToInt64(s.Substring(2), 16), t);
|
||||
return Convert.ChangeType(Convert.ToInt64(s[2..], 16), t);
|
||||
}
|
||||
|
||||
return Convert.ChangeType(s, t);
|
||||
|
|
|
|||
|
|
@ -354,7 +354,7 @@ namespace Server.Gumps
|
|||
{
|
||||
if (DisplayName.StartsWithOrdinal(m_GroupNames[i]))
|
||||
{
|
||||
DisplayName = DisplayName.Substring(m_GroupNames[i].Length);
|
||||
DisplayName = DisplayName[m_GroupNames[i].Length..];
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue