summaryrefslogtreecommitdiff
path: root/src/map/status.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/status.c')
-rw-r--r--src/map/status.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/map/status.c b/src/map/status.c
index 7047906e1..df30516ca 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -5805,7 +5805,7 @@ struct status_data *status_get_status_data(struct block_list *bl)
case BL_HOM: return &((TBL_HOM*)bl)->battle_status;
case BL_MER: return &((TBL_MER*)bl)->battle_status;
case BL_ELEM: return &((TBL_ELEM*)bl)->battle_status;
- case BL_NPC: return &((TBL_NPC*)bl)->status;
+ case BL_NPC: return ((mobdb_checkid(((TBL_NPC*)bl)->class_) == 0) ? &((TBL_NPC*)bl)->status : &dummy_status);
default:
return &dummy_status;
}
@@ -5821,7 +5821,7 @@ struct status_data *status_get_base_status(struct block_list *bl)
case BL_HOM: return &((TBL_HOM*)bl)->base_status;
case BL_MER: return &((TBL_MER*)bl)->base_status;
case BL_ELEM: return &((TBL_ELEM*)bl)->base_status;
- case BL_NPC: return &((TBL_NPC*)bl)->status;
+ case BL_NPC: return ((mobdb_checkid(((TBL_NPC*)bl)->class_) == 0) ? &((TBL_NPC*)bl)->status : NULL);
default:
return NULL;
}