OpenTTD Source 15.0-beta1
CommandPacket Struct Reference

Everything we need to know about a command to be able to execute it. More...

#include <network_internal.h>

Data Fields

CompanyID company
 company that is executing the command
 
uint32_t frame
 the frame in which this packet is executed
 
bool my_cmd
 did the command originate from "me"
 
Commands cmd
 command being executed.
 
StringID err_msg
 string ID of error message to use.
 
CommandCallback * callback
 any callback function executed upon successful completion of the command.
 
CommandDataBuffer data
 command parameters.
 

Detailed Description

Everything we need to know about a command to be able to execute it.

Definition at line 94 of file network_internal.h.

Constructor & Destructor Documentation

◆ CommandPacket()

CommandPacket::CommandPacket ( )
inline

Definition at line 95 of file network_internal.h.

Field Documentation

◆ callback

CommandCallback* CommandPacket::callback

any callback function executed upon successful completion of the command.

Definition at line 102 of file network_internal.h.

Referenced by DistributeCommandPacket(), NetworkSendCommand(), NetworkSyncCommandQueue(), NetworkGameSocketHandler::ReceiveCommand(), and NetworkGameSocketHandler::SendCommand().

◆ cmd

◆ company

◆ data

◆ err_msg

StringID CommandPacket::err_msg

◆ frame

◆ my_cmd


The documentation for this struct was generated from the following file: