mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2024-11-22 13:37:22 +00:00
working guild data
This commit is contained in:
parent
4722c1fdea
commit
7c0fc72294
@ -673,7 +673,7 @@ void ChatPacketHandler::HandleTeamStatusRequest(Packet* packet) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ChatPacketHandler::HandleGuildLeave(Packet* packet){
|
void ChatPacketHandler::HandleGuildLeave(Packet* packet) {
|
||||||
CINSTREAM_SKIP_HEADER;
|
CINSTREAM_SKIP_HEADER;
|
||||||
LWOOBJID playerID = LWOOBJID_EMPTY;
|
LWOOBJID playerID = LWOOBJID_EMPTY;
|
||||||
inStream.Read(playerID);
|
inStream.Read(playerID);
|
||||||
@ -698,7 +698,7 @@ void ChatPacketHandler::HandleGuildLeave(Packet* packet){
|
|||||||
SEND_PACKET;
|
SEND_PACKET;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ChatPacketHandler::HandleGuildGetAll(Packet* packet){
|
void ChatPacketHandler::HandleGuildGetAll(Packet* packet) {
|
||||||
CINSTREAM_SKIP_HEADER;
|
CINSTREAM_SKIP_HEADER;
|
||||||
LWOOBJID playerID = LWOOBJID_EMPTY;
|
LWOOBJID playerID = LWOOBJID_EMPTY;
|
||||||
inStream.Read(playerID);
|
inStream.Read(playerID);
|
||||||
@ -717,39 +717,35 @@ void ChatPacketHandler::HandleGuildGetAll(Packet* packet){
|
|||||||
|
|
||||||
//portion that will get routed:
|
//portion that will get routed:
|
||||||
BitStreamUtils::WriteHeader(bitStream, eConnectionType::CLIENT, eClientMessageType::GUILD_DATA);
|
BitStreamUtils::WriteHeader(bitStream, eConnectionType::CLIENT, eClientMessageType::GUILD_DATA);
|
||||||
bitStream.Write0();
|
bitStream.Write<uint8_t>(0);
|
||||||
bitStream.Write(LUWString(guild->name, 31));
|
bitStream.Write(LUWString(guild->name, 31));
|
||||||
bitStream.Write(LUWString("test1", 11));
|
bitStream.Write(LUWString("test1", 11));
|
||||||
bitStream.Write(LUWString("test2", 11));
|
bitStream.Write(LUWString("test2", 11));
|
||||||
bitStream.Write<uint32_t>(69);
|
bitStream.Write<uint32_t>(69);
|
||||||
bitStream.Write<uint32_t>(0);
|
bitStream.Write<uint32_t>(0);
|
||||||
bitStream.Write<uint32_t>(1);
|
bitStream.Write<uint32_t>(1);
|
||||||
bitStream.Write<unsigned short>(0);
|
bitStream.Write<uint16_t>(0);
|
||||||
bitStream.Write<unsigned short>(2); // Size
|
constexpr int32_t sizeThing = 100;
|
||||||
|
bitStream.Write<uint16_t>(sizeThing); // Size
|
||||||
//Member data
|
//Member data
|
||||||
bitStream.Write1();
|
for (int i = 0; i < sizeThing; i++) {
|
||||||
bitStream.Write1();
|
bitStream.Write<uint8_t>(1); // 0
|
||||||
bitStream.Write<uint16_t>(1200);
|
bitStream.Write<uint8_t>(1); // 1
|
||||||
bitStream.Write<uint16_t>(1);
|
bitStream.Write<uint16_t>(1200); // 2
|
||||||
bitStream.Write<uint32_t>(1);
|
bitStream.Write<uint16_t>(1200); // 4
|
||||||
bitStream.Write<uint32_t>(1);
|
bitStream.Write<uint16_t>(1200); // 6
|
||||||
bitStream.Write<unsigned short>(1);
|
bitStream.Write<uint16_t>(1200); // 4
|
||||||
bitStream.Write(LUWString(player->playerName, 25));
|
bitStream.Write<LWOOBJID>(player->playerID + i); // 8
|
||||||
bitStream.Write<wchar_t>(0); //???
|
bitStream.Write(LUWString((i % 2 == 0 ? "abcdefghijklmnopqrstuvw" : "ABCDEFGHIJKLMNOPQRSTUVW"), 24)); // 16
|
||||||
|
bitStream.Write<uint16_t>(0);
|
||||||
bitStream.Write0();
|
bitStream.Write<LWOOBJID>(0);
|
||||||
bitStream.Write0();
|
bitStream.Write<LWOOBJID>(0);
|
||||||
bitStream.Write<uint16_t>(1200);
|
}
|
||||||
bitStream.Write<uint16_t>(1);
|
|
||||||
bitStream.Write<uint32_t>(1);
|
|
||||||
bitStream.Write<uint32_t>(1);
|
|
||||||
bitStream.Write<unsigned short>(1);
|
|
||||||
bitStream.Write(LUWString(player->playerName, 25));
|
|
||||||
bitStream.Write<wchar_t>(0); //???
|
|
||||||
|
|
||||||
SystemAddress sysAddr = packet->systemAddress;
|
SystemAddress sysAddr = packet->systemAddress;
|
||||||
SEND_PACKET;
|
SEND_PACKET;
|
||||||
LOG("Send GUILD DATA");
|
LOG("Send GUILD DATA");
|
||||||
|
PacketUtils::SavePacket("GuildData.bin", (char*)bitStream.GetData(), bitStream.GetNumberOfBytesUsed());
|
||||||
}
|
}
|
||||||
|
|
||||||
void ChatPacketHandler::SendTeamInvite(PlayerData* receiver, PlayerData* sender) {
|
void ChatPacketHandler::SendTeamInvite(PlayerData* receiver, PlayerData* sender) {
|
||||||
|
@ -17,6 +17,7 @@
|
|||||||
* Component that handles rigid bodies that can be interacted with, mostly client-side rendered. An example is the
|
* Component that handles rigid bodies that can be interacted with, mostly client-side rendered. An example is the
|
||||||
* bananas that fall from trees in GF.
|
* bananas that fall from trees in GF.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
class RigidbodyPhantomPhysicsComponent : public PhysicsComponent {
|
class RigidbodyPhantomPhysicsComponent : public PhysicsComponent {
|
||||||
public:
|
public:
|
||||||
inline static const eReplicaComponentType ComponentType = eReplicaComponentType::RIGID_BODY_PHANTOM_PHYSICS;
|
inline static const eReplicaComponentType ComponentType = eReplicaComponentType::RIGID_BODY_PHANTOM_PHYSICS;
|
||||||
|
Loading…
Reference in New Issue
Block a user