Decompile fn_19329 (Replay::CachePacket)
Batch #7224 by eAthena: 0 byte-identical, 1 confirmed by peer review. - fn_19329 Replay::CachePacket: logic confirmed by peer review Peer-reviewed-by: ragnarok-clanker, alisonrag, System4z Accepted without human review: peers confirmed the logic ("same" ahead by at least 3, with 70% of the votes).
This commit is contained in:
parent
e5fa1f321c
commit
158c77e1fe
5 changed files with 25 additions and 0 deletions
|
|
@ -1057,3 +1057,19 @@ std::vector<unsigned char> CSession::BuildSkillListReplayPacket(short id) {
|
|||
return {};
|
||||
}
|
||||
}
|
||||
|
||||
// OFFSET: 0x00B86440
|
||||
// FUNCTION: fn_19329
|
||||
void Replay::CachePacket(std::uint16_t id, std::uint16_t size, const unsigned char* data) {
|
||||
if (size == 0 || id > 3142 || data == nullptr) {
|
||||
return;
|
||||
}
|
||||
ReplayCachedPacket& packet = this->cachedPackets[static_cast<short>(id)];
|
||||
if (!packet.enabled) {
|
||||
return;
|
||||
}
|
||||
packet.bytes.resize(size, 0);
|
||||
packet.bytes.assign(data, data + size);
|
||||
}
|
||||
|
||||
// OFFSET: 0x00E42EB0
|
||||
|
|
|
|||
|
|
@ -138,6 +138,7 @@ public:
|
|||
void ResetFile();
|
||||
bool SetOptions(const void* data, int bytes);
|
||||
std::vector<unsigned char> ReadSection(int id);
|
||||
void CachePacket(std::uint16_t id, std::uint16_t size, const unsigned char* data);
|
||||
bool ReadRecord(unsigned char* buffer, std::uint16_t& id, bool force);
|
||||
bool AllowsEvent(int event) const;
|
||||
void Rewind();
|
||||
|
|
|
|||
|
|
@ -493,6 +493,7 @@ public:
|
|||
void LoadRobeAlpha();
|
||||
void LoadDamageSkinSettings();
|
||||
bool LoadMapNameTable();
|
||||
bool LoadFogParameters();
|
||||
void ClearHomunStatus();
|
||||
std::pair<int, int>* InsertPair(int key, int value);
|
||||
int SetPairValue(int value, int slot);
|
||||
|
|
@ -702,6 +703,7 @@ public:
|
|||
std::uint32_t ReadReplayReserved(const std::vector<unsigned char>& data);
|
||||
std::uint32_t ReadReplayEntryQueue(const std::vector<unsigned char>& data);
|
||||
std::vector<unsigned char> BuildShortcutReplayRecords();
|
||||
std::vector<unsigned char> BuildReservedReplayRecords();
|
||||
std::vector<unsigned char> BuildSkillListReplayPacket(short id);
|
||||
void SetHomunculusAutoFeed(bool enabled);
|
||||
void SetPetAutoFeed(bool enabled);
|
||||
|
|
|
|||
|
|
@ -3,12 +3,14 @@
|
|||
#include "Contents/Configuration/ServiceConfiguration.h"
|
||||
#include "Contents/MapInfoMgr.h"
|
||||
#include "Contents/NavigationManager.h"
|
||||
#include "File/File.h"
|
||||
#include "Script/LuaScript.h"
|
||||
#include "UI/Window/UIWindow.h"
|
||||
#include "UI/Window/UIWindowMgr.h"
|
||||
#include "Utility/Cipher/XorBytes.h"
|
||||
#include "Utility/Text/FormatString.h"
|
||||
|
||||
#include <algorithm>
|
||||
#include <cstddef>
|
||||
#include <cstdint>
|
||||
#include <cstdio>
|
||||
|
|
@ -775,6 +777,8 @@ void CSession::LoadDamageSkinSettings() {
|
|||
g_luaScript->Call("GetDamageMillionUnit", "d>d", this->m_damageSkinIndex, &this->m_damageMillionUnit);
|
||||
}
|
||||
|
||||
// OFFSET: 0x00DE5620
|
||||
|
||||
// OFFSET: 0x00DE5B40
|
||||
// FUNCTION: fn_23493
|
||||
void CSession::ClearHomunStatus() {
|
||||
|
|
|
|||
|
|
@ -988,3 +988,5 @@ void RequestPlayerAction31() {
|
|||
player->SendMsg(nullptr, 0x1F, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
|
||||
}
|
||||
}
|
||||
|
||||
// OFFSET: 0x006C5B40
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue