Decompile 4 functions in Source/Contents/PetStrings.cpp, Source/Client/Session.h
Batch #1192 by eAthena: 0 byte-identical, 4 confirmed by peer review. - fn_23807 CSession::GetPetFood: logic confirmed by peer review - fn_23812 CSession::GetPetIllustName: logic confirmed by peer review - fn_23813 CSession::GetPetJobByEggItem: logic confirmed by peer review - fn_23816 CSession::GetPetString: logic confirmed by peer review Reviewed-by: ragnarok-clanker Adds to the build: Source/Contents/PetStrings.cpp
This commit is contained in:
parent
347b99c15d
commit
22ebefe099
3 changed files with 53 additions and 0 deletions
|
|
@ -68,6 +68,10 @@ public:
|
|||
/* 8140 */ std::int64_t m_loginTimeTicks;
|
||||
/* 8148 */ int unknown_8148;
|
||||
|
||||
int GetPetFood(int job);
|
||||
void GetPetIllustName(int job, int, char* buffer);
|
||||
int GetPetJobByEggItem(int eggItemId);
|
||||
const char* GetPetString(int id);
|
||||
bool UpdateHomunSkill(const CSkillInfo& value, unsigned char notify);
|
||||
bool UpdateMercSkill(const CSkillInfo& value, unsigned char notify);
|
||||
void AddUnknownId(int id);
|
||||
|
|
|
|||
48
Source/Contents/PetStrings.cpp
Normal file
48
Source/Contents/PetStrings.cpp
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
#include "Client/Session.h"
|
||||
#include "Script/LuaScript.h"
|
||||
|
||||
#include <cstdio>
|
||||
|
||||
// OFFSET: 0x00E0AE00
|
||||
// FUNCTION: fn_23807
|
||||
int CSession::GetPetFood(int job) {
|
||||
int food = 0;
|
||||
if (!this->m_hotkeyScript->Call("GetPetFood", "d>d", job, &food)) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
return food;
|
||||
}
|
||||
|
||||
// OFFSET: 0x00E0B170
|
||||
// FUNCTION: fn_23812
|
||||
void CSession::GetPetIllustName(int job, int, char* buffer) {
|
||||
const char* name = nullptr;
|
||||
if (this->m_hotkeyScript->Call("GetPetIllustName_V3", "db>s", job, 1, &name)) {
|
||||
std::sprintf(buffer, name);
|
||||
} else {
|
||||
std::sprintf(buffer, "UserInterface\\illust\\PET_NOIMAGE.bmp");
|
||||
}
|
||||
}
|
||||
|
||||
// OFFSET: 0x00E0B250
|
||||
// FUNCTION: fn_23813
|
||||
int CSession::GetPetJobByEggItem(int eggItemId) {
|
||||
int job = 0;
|
||||
if (!this->m_hotkeyScript->Call("GetPetJTID_by_PetEggITID", "d>d", eggItemId, &job)) {
|
||||
return -1;
|
||||
}
|
||||
|
||||
return job;
|
||||
}
|
||||
|
||||
// OFFSET: 0x00E12780
|
||||
// FUNCTION: fn_23816
|
||||
const char* CSession::GetPetString(int id) {
|
||||
const char* text = nullptr;
|
||||
if (!this->m_hotkeyScript->Call("GetPetString", "d>s", id, &text)) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return text;
|
||||
}
|
||||
|
|
@ -378,6 +378,7 @@
|
|||
"Source/Contents/Party/RegisterPartyAsyncWork.cpp": 4,
|
||||
"Source/Contents/Party/StopRecruitingAsyncWork.cpp": 4,
|
||||
"Source/Contents/Party/StopRecruitingCompletion.cpp": 2,
|
||||
"Source/Contents/PetStrings.cpp": 4,
|
||||
"Source/Contents/PlayerNameDictionary.cpp": 4,
|
||||
"Source/Contents/ShowRankingScheduler.cpp": 4,
|
||||
"Source/Contents/Skills/AutomaticSkills.cpp": 4,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue