mirror of
https://github.com/pret/pmd-sky.git
synced 2026-06-01 18:24:10 -05:00
33 lines
712 B
C
33 lines
712 B
C
#include "dg_camera.h"
|
|
#include "dungeon.h"
|
|
#include "dungeon_items.h"
|
|
#include "dungeon_pokemon_attributes.h"
|
|
#include "dungeon_util_static.h"
|
|
|
|
// file starts at 0x022e26b68
|
|
|
|
bool8 EntityIsValid__022E32E8(struct entity *entity)
|
|
{
|
|
if (entity == NULL)
|
|
return FALSE;
|
|
|
|
return GetEntityType(entity) != ENTITY_NOTHING;
|
|
}
|
|
|
|
bool8 ItemIsActive__022E330C(struct entity *entity, enum item_id item_id)
|
|
{
|
|
if (AbilityIsActiveVeneer(entity, ABILITY_KLUTZ))
|
|
return FALSE;
|
|
|
|
return HasHeldItem(entity, item_id);
|
|
}
|
|
|
|
s16 GetVisibilityRange()
|
|
{
|
|
s16 visibility_range = DUNGEON_PTR[0]->display_data.visibility_range;
|
|
if (visibility_range == 0)
|
|
return 2;
|
|
|
|
return visibility_range;
|
|
}
|