mirror of
https://github.com/luanti-org/luanti.git
synced 2025-07-27 17:28:41 +00:00
C++11 cleanup on constructors dir network (#6021)
* C++11 cleanup on constructors dir network
This commit is contained in:
parent
af3badf7a9
commit
8daf5b5338
4 changed files with 98 additions and 177 deletions
|
@ -30,8 +30,7 @@ class NetworkPacket
|
|||
public:
|
||||
NetworkPacket(u16 command, u32 datasize, u16 peer_id);
|
||||
NetworkPacket(u16 command, u32 datasize);
|
||||
NetworkPacket(): m_datasize(0), m_read_offset(0), m_command(0),
|
||||
m_peer_id(0) {}
|
||||
NetworkPacket() {}
|
||||
~NetworkPacket();
|
||||
|
||||
void putRawPacket(u8 *data, u32 datasize, u16 peer_id);
|
||||
|
@ -126,10 +125,10 @@ private:
|
|||
}
|
||||
|
||||
std::vector<u8> m_data;
|
||||
u32 m_datasize;
|
||||
u32 m_read_offset;
|
||||
u16 m_command;
|
||||
u16 m_peer_id;
|
||||
u32 m_datasize = 0;
|
||||
u32 m_read_offset = 0;
|
||||
u16 m_command = 0;
|
||||
u16 m_peer_id = 0;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue