blob: 9ffa63334877e365004786ab609027b5248b7b47 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
#include "global.h"
#include "dungeon_map_access.h"
#include "dungeon_global_data.h"
extern struct unkStruct_202F190 gUnknown_202F190;
extern struct unkStruct_202F190 *gUnknown_203B430;
struct MapTile* GetMapTile_1(s32 x, s32 y)
{
if (x >= 0 && y >= 0 && x < DUNGEON_MAX_SIZE_X && y < DUNGEON_MAX_SIZE_Y)
{
return gDungeonGlobalData->mapTilePointers[y][x];
}
return (struct MapTile*) gUnknown_203B430->unk0;
}
struct MapTile* GetMapTile_2(s32 x, s32 y)
{
if (x < 0 || y < 0 || x >= DUNGEON_MAX_SIZE_X || y >= DUNGEON_MAX_SIZE_Y)
{
struct MapTile* tile = (struct MapTile*) gUnknown_202F190.unk0;
gUnknown_202F190 = *gUnknown_203B430;
return tile;
}
return gDungeonGlobalData->mapTilePointers[y][x];
}
|