fix(core): Adds Gump component functionality (#377)
- [X] Adds gump close packet - [X] Fixes gump tooltip - [X] Adds new compile/append functions for the new gump packets
This commit is contained in:
parent
cc91fe2b10
commit
3b413371dc
40 changed files with 1696 additions and 137 deletions
|
|
@ -1,27 +0,0 @@
|
|||
using System;
|
||||
using System.Buffers.Binary;
|
||||
using System.Runtime.CompilerServices;
|
||||
using Server;
|
||||
|
||||
namespace Benchmarks
|
||||
{
|
||||
public static class PacketTestUtilities
|
||||
{
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
public static void Write(this Span<byte> data, ref int pos, Serial serial)
|
||||
{
|
||||
BinaryPrimitives.WriteUInt32BigEndian(data.Slice(pos, 4), serial);
|
||||
pos += 4;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
public static void Write(this Span<byte> data, ref int pos, ushort value)
|
||||
{
|
||||
BinaryPrimitives.WriteUInt16BigEndian(data.Slice(pos, 2), value);
|
||||
pos += 2;
|
||||
}
|
||||
|
||||
[MethodImpl(MethodImplOptions.AggressiveInlining)]
|
||||
public static void Write(this Span<byte> data, ref int pos, byte value) => data[pos++] = value;
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue