Decompile fn_04357 (CWorldViewWorld::MapAt)
Batch #14262 by Yommy: 1 byte-identical, 0 confirmed by peer review. - fn_04357 CWorldViewWorld::MapAt: byte-identical Merged automatically: every function is byte-identical to the original.
This commit is contained in:
parent
59651749b5
commit
7311ddf00c
1 changed files with 6 additions and 7 deletions
|
|
@ -210,18 +210,17 @@ __declspec(noinline) CWorldViewMap* CWorldViewWorld::FindMap(int id) {
|
|||
// FUNCTION: fn_04357
|
||||
CWorldViewMap* CWorldViewWorld::MapAt(unsigned int& mapIndex, int x, int y) {
|
||||
for (unsigned int index = 0; index < this->maps.size(); ++index) {
|
||||
CWorldViewMap* map = this->maps[index];
|
||||
if (map->id < 100) {
|
||||
if (map->fields.empty()) {
|
||||
if (AreaContains(map->left, map->top, map->right, map->bottom, x, y)) {
|
||||
if (this->maps[index]->id < 100) {
|
||||
if (this->maps[index]->fields.empty()) {
|
||||
if (AreaContains(this->maps[index]->left, this->maps[index]->top, this->maps[index]->right, this->maps[index]->bottom, x, y)) {
|
||||
mapIndex = index;
|
||||
return map;
|
||||
return this->maps[index];
|
||||
}
|
||||
} else {
|
||||
const CWorldViewField* first = map->fields.front();
|
||||
const CWorldViewField* first = this->maps[index]->fields.front();
|
||||
if (AreaContains(first->left, first->top, first->right, first->bottom, x, y)) {
|
||||
mapIndex = index;
|
||||
return map;
|
||||
return this->maps[index];
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue