diff --git a/Source/Client/Mode/CGameMode.h b/Source/Client/Mode/CGameMode.h index 205ac4e0..83fb7560 100644 --- a/Source/Client/Mode/CGameMode.h +++ b/Source/Client/Mode/CGameMode.h @@ -348,6 +348,29 @@ public: void AddUnknown0604(UIWindow* window); void RequestAdminStatus(); void sub_CEB8E0(); + unsigned sub_CEBF30(const std::vector& data); + unsigned sub_CEC100(const std::vector& data); + unsigned sub_CEC6A0(const std::vector& data); + void sub_D2DB80(const unsigned char* record); + void sub_D3D2F0(const unsigned char* record); + void sub_D3F130(const unsigned char* record); + void sub_D24430(const unsigned char* record); + void sub_D350A0(const unsigned char* record); + void sub_D37A10(const unsigned char* record); + void sub_D40730(const unsigned char* record); + void sub_D41250(const unsigned char* record); + void sub_D51A90(const unsigned char* record); + void sub_D61390(const unsigned char* record); + void sub_D616B0(const unsigned char* record); + void sub_D619E0(const unsigned char* record); + void sub_D63720(const unsigned char* record); + void sub_D63A40(const unsigned char* record); + void sub_D63D70(const unsigned char* record); + void sub_D65FC0(const unsigned char* record); + void sub_D7B170( + int first, std::string text, int second, int third, int fourth, int fifth, int sixth, int seventh, int eighth, + int ninth, int tenth, int eleventh, int twelfth, int thirteenth, int fourteenth, int fifteenth + ); void Slot7(int value) override; void PlaceWindowAtActor(UIWindow* window, CGameActor* actor); bool UpdateReplayPause(bool resume); diff --git a/Source/Client/Mode/GameMode.cpp b/Source/Client/Mode/GameMode.cpp index d1853d3c..6babc6b1 100644 --- a/Source/Client/Mode/GameMode.cpp +++ b/Source/Client/Mode/GameMode.cpp @@ -408,6 +408,49 @@ void CGameMode::sub_CEB8E0() { recorder.Record(static_cast(record.length), &record, 0x2A, 0); } +// OFFSET: 0x00CEBF30 + +// OFFSET: 0x00CEC100 + +// OFFSET: 0x00CEC6A0 +// FUNCTION: fn_21356 +unsigned CGameMode::sub_CEC6A0(const std::vector& data) { + if (data.empty()) { + return 0xFFFFFFFFu; + } + + unsigned offset = 6; + if (*reinterpret_cast(data.data()) == 17000) { + while (offset < data.size()) { + const short type = *reinterpret_cast(data.data() + offset); + const std::uint32_t size = *reinterpret_cast(data.data() + offset + 2); + offset += 6; + + if (type == 0xCD) { + unsigned char* record = new unsigned char[0x10](); + std::memcpy(record, data.data() + offset, size); + offset += size; + this->sub_D41250(record); + delete[] record; + } else if (type == 0xCE) { + unsigned char* record = new unsigned char[0x61](); + std::memcpy(record, data.data() + offset, size); + offset += size; + this->sub_D40730(record); + delete[] record; + } else if (type == 0x4269) { + break; + } else { + offset += size; + } + } + } else { + offset = 0xFFFFFFFFu; + } + + return offset; +} + // OFFSET: 0x00CEFE50 // FUNCTION: fn_21407 void CGameMode::ClearUnknown04DC() {