SEGS  0.4.2
Super Entity Game Server
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
LoginResponse.h
Go to the documentation of this file.
1 /*
2  * SEGS - Super Entity Game Server
3  * http://www.segs.io/
4  * Copyright (c) 2006 - 2018 SEGS Team (see Authors.txt)
5  * This software is licensed! (See License.txt for details)
6  */
7 
8 #pragma once
9 #include <cstring>
11 
13 {
14  uint8_t unkArray1[8];
15  uint8_t unkArray2[8];
16  uint32_t unk1, unk2, unk3;
17 public:
18  LoginResponse() : AuthLinkEvent(evLoginResponse),unk1(0), unk2(0), unk3(0)
19  {
20  memset(unkArray1,0,8);
21  memset(unkArray2,0,8);
22  }
23  void serializeto(GrowingBuffer &buf) const
24  {
25  buf.uPut((uint8_t)3); // packet code
26  buf.uPutBytes(unkArray1, sizeof(unkArray1));
27  buf.uPutBytes(unkArray2, sizeof(unkArray2));
28  buf.uPut(unk1);
29  buf.uPut(unk2);
30  buf.uPut(unk3);
31  }
33  {
34  uint8_t op;
35  buf.uGet(op);
36  buf.uGetBytes(unkArray1, sizeof(unkArray1));
37  buf.uGetBytes(unkArray2, sizeof(unkArray2));
38  buf.uGet(unk1);
39  buf.uGet(unk2);
40  buf.uGet(unk3);
41  }
42 };
void serializeto(GrowingBuffer &buf) const
Definition: LoginResponse.h:23
void uGet(T &val)
Definition: Buffer.h:76
Definition: LoginResponse.h:12
Definition: AuthEvents.h:35
LoginResponse()
Definition: LoginResponse.h:18
Definition: Buffer.h:17
void uPutBytes(const uint8_t *t, size_t len)
Definition: Buffer.cpp:96
void serializefrom(GrowingBuffer &buf)
Definition: LoginResponse.h:32
void uPut(const T &val)
Definition: Buffer.h:69
void uGetBytes(uint8_t *t, size_t len)
Definition: Buffer.cpp:133
Definition: AuthEvents.h:15