Decompile 7 functions in Source/Archive/PakRegistry.cpp, Source/Client/Mode/GameMode.cpp, ...
Batch #18143 by KWDev: 7 byte-identical, 0 confirmed by peer review. - fn_18111 PakRegistry::Add: byte-identical - fn_21283 CGameMode::LocationText: byte-identical - fn_05320 CAchievementMgr::GetCompletedCount: byte-identical - fn_18965 CSquareRangeEffect::OnProcess: byte-identical - fn_07545 CWindEffect::Render: byte-identical - fn_18179 ResourceMgr::ResolveMapName: byte-identical - fn_02765 Split: byte-identical Merged automatically: every function is byte-identical to the original.
This commit is contained in:
parent
c005fb37b8
commit
bdc35c078b
7 changed files with 24 additions and 10 deletions
|
|
@ -22,7 +22,7 @@ bool PakRegistry::Add(const char* filename) {
|
|||
CGPak* archive = new CGPak;
|
||||
CMemMapPakFile* file = new CMemMapPakFile(filename);
|
||||
|
||||
this->m_archives.emplace_front(file, archive);
|
||||
this->m_archives.push_front(std::make_pair(file, archive));
|
||||
return this->m_archives.front().second->Open(this->m_archives.front().first);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -454,7 +454,8 @@ std::string CGameMode::LocationText() {
|
|||
}
|
||||
|
||||
std::sprintf(text, "Location: %s ( %d , %d )", name.c_str(), column, row);
|
||||
return text;
|
||||
std::string result(text);
|
||||
return result;
|
||||
}
|
||||
|
||||
// OFFSET: 0x00CD5800
|
||||
|
|
|
|||
|
|
@ -171,16 +171,20 @@ int CAchievementMgr::GetCompletedCount(int group, int index) {
|
|||
} else if (index == -1) {
|
||||
for (int i = 0; i < this->groupWidth; ++i) {
|
||||
int key = this->groupWidth * group + i;
|
||||
for (std::vector<int>::iterator it = this->groups[key].begin(); it != this->groups[key].end(); ++it) {
|
||||
if (IsAchievementCompleted(*it)) {
|
||||
for (std::vector<int>::iterator it = this->groups[key].begin(); it != this->groups[key].end();) {
|
||||
const int id = *it;
|
||||
++it;
|
||||
if (IsAchievementCompleted(id)) {
|
||||
++count;
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
int key = this->groupWidth * group + index;
|
||||
for (std::vector<int>::iterator it = this->groups[key].begin(); it != this->groups[key].end(); ++it) {
|
||||
if (IsAchievementCompleted(*it)) {
|
||||
for (std::vector<int>::iterator it = this->groups[key].begin(); it != this->groups[key].end();) {
|
||||
const int id = *it;
|
||||
++it;
|
||||
if (IsAchievementCompleted(id)) {
|
||||
++count;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ void CSquareRangeEffect::OnProcess() {
|
|||
|
||||
matrix rotation;
|
||||
std::memcpy(rotation.values, g_identityMatrix, sizeof(rotation.values));
|
||||
rotation.MakeXRotation(1.5707964f);
|
||||
rotation.MakeXRotation(1.570796f);
|
||||
matrix scale;
|
||||
std::memcpy(scale.values, g_identityMatrix, sizeof(scale.values));
|
||||
scale.SetScale(particle->scale, particle->scale, 1.0f);
|
||||
|
|
|
|||
|
|
@ -180,7 +180,14 @@ void CWindEffect::Render() {
|
|||
continue;
|
||||
}
|
||||
|
||||
const ParticleQuad quad = {true, 0.0f, 1.0f, static_cast<float>(texPart - 1) / 21.0f, static_cast<float>(texPart) / 21.0f, false, true};
|
||||
ParticleQuad quad;
|
||||
quad.unused = false;
|
||||
quad.depth = true;
|
||||
quad.top = 0.0f;
|
||||
quad.bottom = 1.0f;
|
||||
quad.billboard = true;
|
||||
quad.left = static_cast<float>(texPart - 1) / 21.0f;
|
||||
quad.right = static_cast<float>(texPart) / 21.0f;
|
||||
particle->Render(quad);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -50,7 +50,8 @@ std::string ResourceMgr::ResolveMapName(const char* name) const {
|
|||
filename += ".gat";
|
||||
const char* resolved = this->Resolve(filename.c_str());
|
||||
const char* extension = std::strstr(resolved, ".gat");
|
||||
return std::string(resolved, extension);
|
||||
std::string mapName(resolved, extension);
|
||||
return mapName;
|
||||
}
|
||||
|
||||
// OFFSET: 0x00AEFE50
|
||||
|
|
|
|||
|
|
@ -173,7 +173,8 @@ std::string FormatDecimal(double value, int precision, bool trimZeros) {
|
|||
std::vector<std::string> Split(std::string_view text, std::string_view delimiter) {
|
||||
auto parts = text | std::views::split(delimiter)
|
||||
| std::views::transform([](auto&& part) { return std::string_view(part.begin(), part.end()); });
|
||||
return std::vector<std::string>(parts.begin(), parts.end());
|
||||
std::vector<std::string> result(parts.begin(), parts.end());
|
||||
return result;
|
||||
}
|
||||
|
||||
// OFFSET: 0x0058B830
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue