/// <summary> /// Creates a new <see cref="BlockNetworkCommand62EventServerPayload"/> with the provided <see cref="command"/> 0x60 /// command. /// </summary> /// <param name="command">The command to initialize the payload with.</param> /// <returns>A new <see cref="BlockNetworkCommand62EventServerPayload"/> with the <see cref="command"/></returns> public static BlockNetworkCommand62EventServerPayload ToServerPayload([NotNull] this BaseSubCommand62 command) { if (command == null) { throw new ArgumentNullException(nameof(command)); } //Just create a new command container (the 0x60 payload) around the command. return(new BlockNetworkCommand62EventServerPayload(command)); }
public BlockNetworkCommand62EventServerPayload([NotNull] BaseSubCommand62 command) : this() { Command = command ?? throw new ArgumentNullException(nameof(command)); }
//TODO: We can probably cache this string for performance in the future /// <summary> /// Computes the hex string opcode for the provided <see cref="BaseSubCommand62"/>. /// </summary> /// <param name="command"></param> /// <returns></returns> public static string OpCodeHexString(this BaseSubCommand62 command) { return($"0x62 {command.CommandOperationCode:X}"); }
public override void Write(BaseSubCommand62 value, Span <byte> buffer, ref int offset) { Sub62PhotonChairCommand_Serializer.Instance.InternalWrite(this, buffer, ref offset); }
public override void Write(BaseSubCommand62 value, Span <byte> buffer, ref int offset) { Sub62ClientBurstBeginEventCommand_Serializer.Instance.InternalWrite(this, buffer, ref offset); }